A modern and elegant dashboard for network traffic visualization and analysis.
init:create clash master project,powered by kimi k2.5
luoleif7ef1e0561c2
diff --git a/.dockerignore b/.dockerignorenew file mode 100644index 0000000..537f098--- /dev/null+++ b/.dockerignore@@ -0,0 +1,48 @@+# Dependencies+node_modules+.pnpm-store++# Build outputs+.next+dist+*.tsbuildinfo++# Development+.git+.gitignore+.env.local+.env.*.local+*.log++# IDE+.vscode+.idea+*.swp+*.swo++# OS+.DS_Store+Thumbs.db++# Testing+coverage+.nyc_output++# Docker+docker-compose.override.yml+Dockerfile+.dockerignore++# Documentation (keep minimal)+README.md+*.md++# Data (will be mounted as volume)+data+*.db+*.db-journal++# Temporary files+tmp+temp+*.tmpdiff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.ymlnew file mode 100644index 0000000..bcfe962--- /dev/null+++ b/.github/workflows/docker-build.yml@@ -0,0 +1,56 @@+name: Build and Push Docker Image++on:+ push:+ branches: [ main ]+ tags: [ 'v*' ]+ pull_request:+ branches: [ main ]++env:+ REGISTRY: ghcr.io+ IMAGE_NAME: ${{ github.repository }}++jobs:+ build:+ runs-on: ubuntu-latest+ permissions:+ contents: read+ packages: write++ steps:+ - name: Checkout repository+ uses: actions/checkout@v4++ - name: Set up Docker Buildx+ uses: docker/setup-buildx-action@v3++ - name: Log in to Container Registry+ uses: docker/login-action@v3+ with:+ registry: ${{ env.REGISTRY }}+ username: ${{ github.actor }}+ password: ${{ secrets.GITHUB_TOKEN }}++ - name: Extract metadata+ id: meta+ uses: docker/metadata-action@v5+ with:+ images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}+ tags: |+ type=ref,event=branch+ type=ref,event=pr+ type=semver,pattern={{version}}+ type=semver,pattern={{major}}.{{minor}}+ type=sha++ - name: Build and push Docker image+ uses: docker/build-push-action@v5+ with:+ context: .+ push: ${{ github.event_name != 'pull_request' }}+ tags: ${{ steps.meta.outputs.tags }}+ labels: ${{ steps.meta.outputs.labels }}+ cache-from: type=gha+ cache-to: type=gha,mode=max+ platforms: linux/amd64,linux/arm64diff --git a/.gitignore b/.gitignorenew file mode 100644index 0000000..dc72c2f--- /dev/null+++ b/.gitignore@@ -0,0 +1,57 @@+# Dependencies+node_modules/+.pnp+.pnp.js++# Production builds+dist/+build/+.next/+out/++# Environment variables+.env+.env.local+.env.development.local+.env.test.local+.env.production.local++# Database+*.db+*.db-journal+*.sqlite+*.sqlite3++# Logs+logs/+*.log+npm-debug.log*+yarn-debug.log*+yarn-error.log*+pnpm-debug.log*+lerna-debug.log*++# OS+.DS_Store+Thumbs.db++# IDE+.idea/+.vscode/+*.swp+*.swo+*~++# Turbo+.turbo/++# Vercel+.vercel++# TypeScript+*.tsbuildinfo+next-env.d.ts++# Cache+.cache/+*.cachediff --git a/.specstory/.gitignore b/.specstory/.gitignorenew file mode 100644index 0000000..d05a40e--- /dev/null+++ b/.specstory/.gitignore@@ -0,0 +1,4 @@+# SpecStory explanation file+/.what-is-this.md+# SpecStory project identity file+/.project.jsondiff --git a/Dockerfile b/Dockerfilenew file mode 100644index 0000000..13ec756--- /dev/null+++ b/Dockerfile@@ -0,0 +1,67 @@+# Clash Master - Multi-stage Docker Build+FROM node:22-alpine AS base++# Install pnpm and build tools for native modules+RUN apk add --no-cache python3 make g++ gcc && \+ npm install -g [email protected]++# Set working directory+WORKDIR /app++# Copy package files+COPY package.json pnpm-lock.yaml pnpm-workspace.yaml turbo.json ./+COPY apps/collector/package.json ./apps/collector/+COPY apps/web/package.json ./apps/web/+COPY packages/shared/package.json ./packages/shared/++# Install dependencies+RUN pnpm install --frozen-lockfile++# Copy source code+COPY . .++# Build shared package first+RUN pnpm --filter @clashstats/shared build++# Build collector+RUN pnpm --filter @clashstats/collector build++# Build web+RUN pnpm --filter @clashstats/web build++# Production stage+FROM node:22-alpine AS production++WORKDIR /app++# Ensure data directory exists+RUN mkdir -p /app/data++# Copy collector (with its node_modules for runtime dependencies)+COPY --from=base /app/apps/collector/dist ./apps/collector/dist+COPY --from=base /app/apps/collector/package.json ./apps/collector/+COPY --from=base /app/apps/collector/node_modules ./apps/collector/node_modules++# Copy web (Next.js standalone output)+COPY --from=base /app/apps/web/.next/standalone ./apps/web/.next/standalone+COPY --from=base /app/apps/web/.next/static ./apps/web/.next/standalone/apps/web/.next/static+COPY --from=base /app/apps/web/public ./apps/web/.next/standalone/apps/web/public++# Copy packages/shared (for collector dependencies)+COPY --from=base /app/packages/shared ./packages/shared++# Copy root node_modules for workspace dependencies+COPY --from=base /app/node_modules ./node_modules+COPY --from=base /app/package.json ./++# Expose ports+EXPOSE 3000 3001 3002++# Data volume+VOLUME ["/app/data"]++# Start script+COPY docker-start.sh ./+RUN chmod +x docker-start.sh++CMD ["./docker-start.sh"]diff --git a/LICENSE b/LICENSEnew file mode 100644index 0000000..b08ddce--- /dev/null+++ b/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2025 foru17++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/MULTI_BACKEND_ARCH.md b/MULTI_BACKEND_ARCH.mdnew file mode 100644index 0000000..d1b9019--- /dev/null+++ b/MULTI_BACKEND_ARCH.md@@ -0,0 +1,159 @@+# 多后端架构设计++本文档描述 Clash Master 的多后端架构设计,支持同时监控多个 OpenClash 实例。++## 核心概念++### 1. 数据隔离 (Data Isolation)++每个后端的数据存储在独立的分区中,通过 `backend_id` 字段区分。++**受影响的表:**++- `domain_stats` - 域名统计+- `ip_stats` - IP 统计+- `proxy_stats` - 代理统计+- `rule_stats` - 规则统计+- `rule_proxy_map` - 规则-代理映射+- `country_stats` - 国家统计+- `hourly_stats` - 小时统计+- `connection_logs` - 连接日志++**主键设计:** 所有统计表使用复合主键 `(backend_id, entity_id)`,例如 `(backend_id, domain)`。++### 2. 后端状态 (Backend States)++每个后端有两个独立的状态标志:++| 字段 | 含义 | 说明 |+| ----------- | -------- | --------------------------------------------- |+| `is_active` | 显示状态 | 当前在 UI 中显示哪个后端的数据(唯一) |+| `listening` | 收集状态 | 是否正在从该后端收集数据(多个可同时为 true) |+| `enabled` | 启用状态 | 后端是否可用(被禁用的后端不参与任何操作) |++**使用场景:**++- 用户可以在 UI 中查看后端 A 的数据+- 同时后端 B 和 C 在后台继续收集数据+- 随时切换到后端 B 或 C 查看它们的数据++### 3. 持续收集 (Continuous Collection)++收集器维护一个连接池:++```typescript+(Map < backendId, OpenClashCollector > collectors);+```++- 每个 `listening=true` 且 `enabled=true` 的后端都有一个独立的 WebSocket 连接+- 连接状态独立管理,一个后端断开不影响其他后端+- 每 5 秒检查一次后端配置变化,动态启动/停止收集器++## API 设计++### 获取统计数据++所有统计 API 支持可选的 `backendId` 参数:++```+GET /api/stats/summary?backendId=1+GET /api/stats/domains?backendId=1&limit=50+GET /api/stats/trend?backendId=1&minutes=30+```++如果不提供 `backendId`,则使用当前 `is_active` 的后端。++### 后端管理 API++```+# 获取所有后端+GET /api/backends++# 获取当前活跃后端(用于显示)+GET /api/backends/active++# 获取正在收集数据的后端列表+GET /api/backends/listening++# 设置显示的后端(切换 UI 显示)+POST /api/backends/:id/activate++# 设置收集状态(开始/停止收集)+POST /api/backends/:id/listening+Body: { "listening": true/false }++# 清空指定后端的所有数据+POST /api/backends/:id/clear-data+```++## 前端设计++### 后端选择器++顶部导航栏显示当前显示的后端名称,点击可切换:++```+[概览] [后端A ▼] [收集指示器] [语言] [主题] [刷新]+```++下拉菜单显示:++- 所有后端列表,标注当前显示的后端+- 正在收集数据的后端显示绿色指示器+- "管理后端" 选项打开配置对话框++### 收集状态指示器++显示当前正在收集数据的后端:++```+[● 后端A] [● 后端B] [● 后端C] [+2]+```++### 设置对话框++每个后端卡片显示:++- 名称和连接信息+- **显示按钮** - 切换 `is_active` 状态+- **收集开关** - 切换 `listening` 状态+- 编辑和删除按钮++## 数据库迁移++从单后端迁移到多后端架构时:++1. 创建默认后端配置+2. 将所有现有数据关联到默认后端(`backend_id=1`)+3. 添加 `listening` 列到 `backend_configs` 表+4. 更新所有表的主键为复合主键++迁移代码在 `db.ts` 的 `migrateIfNeeded()` 方法中自动执行。++## 使用场景示例++### 场景 1:主备切换++- 后端 A(主):listening=true, is_active=true+- 后端 B(备):listening=true, is_active=false+- 当 A 故障时,点击 B 的显示按钮切换到备用后端++### 场景 2:多节点监控++- 家中路由器:listening=true, is_active=true+- VPS 服务器:listening=true, is_active=false+- 办公室路由器:listening=true, is_active=false+- 同时监控所有节点,在 UI 中切换查看++### 场景 3:数据对比++- 在节点 A 收集一段时间数据+- 切换到节点 B 查看差异+- 所有数据都保留,可以随时回顾++## 性能考虑++1. **索引优化**:所有查询都包含 `backend_id` 过滤,已创建相应索引+2. **连接管理**:每个后端独立 WebSocket 连接,避免相互影响+3. **数据清理**:支持按后端清理数据,不影响其他后端+4. **内存使用**:连接池按需创建,无数据后端不占用连接资源diff --git a/README.md b/README.mdnew file mode 100644index 0000000..65a1196--- /dev/null+++ b/README.md@@ -0,0 +1,200 @@+# Clash Master++<p align="center">+ <img src="./assets/icon-clash-master.png" width="120" alt="Clash Master Logo">+</p>++<p align="center">+ <b>现代化的 OpenClash 流量统计分析系统</b>+</p>++<p align="center">+ <a href="https://github.com/foru17/clash-master/stargazers"><img src="https://img.shields.io/github/stars/foru17/clash-master?style=flat-square" alt="Stars"></a>+ <a href="https://github.com/foru17/clash-master/blob/main/LICENSE"><img src="https://img.shields.io/github/license/foru17/clash-master?style=flat-square" alt="License"></a>+ <img src="https://img.shields.io/badge/Docker-Ready-blue?style=flat-square&logo=docker" alt="Docker">+</p>++++## ✨ 功能特性++- 📊 **实时流量监控** - WebSocket 实时采集,延迟低至毫秒级+- 📈 **趋势分析** - 支持 30分钟/1小时/24小时 多维度流量趋势+- 🌐 **域名分析** - 查看各域名的流量、关联 IP、连接数+- 🗺️ **IP 追踪** - ASN、地理位置、所属域名关联展示+- 🚀 **代理统计** - 各代理节点流量分配、连接数统计+- 🌙 **深色模式** - 支持浅色/深色/跟随系统三种主题+- 🌍 **双语支持** - 中文/英文无缝切换+- 🔄 **多后端** - 同时监控多个 OpenClash 后端++## 🚀 快速开始(Docker)++### 方式一:Docker Compose(推荐)++```bash+# 1. 克隆项目+git clone https://github.com/foru17/clash-master.git+cd clash-master++# 2. 构建并启动服务+docker compose up -d --build++# 3. 访问 http://localhost:3000 完成配置+```++### 方式二:Docker 直接运行++```bash+# 1. 克隆项目+git clone https://github.com/foru17/clash-master.git+cd clash-master++# 2. 构建镜像+docker build -t clash-master:latest .++# 3. 创建数据目录并运行容器+mkdir -p clash-master-data+docker run -d \+ --name clash-master \+ -p 3000:3000 \+ -p 3001:3001 \+ -p 3002:3002 \+ -v $(pwd)/clash-master-data:/app/data \+ --restart unless-stopped \+ clash-master:latest++# 4. 访问 http://localhost:3000 完成配置+```++> 💡 **Note**: 镜像将很快发布到 GHCR,届时可直接使用 `ghcr.io/foru17/clash-master:latest`++### 方式三:源码运行++```bash+# 1. 克隆项目+git clone https://github.com/foru17/clash-master.git+cd clash-master++# 2. 安装依赖+pnpm install++# 3. 启动服务+./start.sh++# 4. 访问 http://localhost:3000 完成配置+```++## 📖 首次使用++1. 打开 <http://localhost:3000>+2. 首次访问会弹出后端配置对话框+3. 填写 OpenClash 连接信息:+ - **名称**: 自定义名称(如 "Home")+ - **地址**: OpenClash 后端地址(如 `192.168.101.1`)+ - **端口**: OpenClash 后端端口(如 `9090`)+ - **Token**: 如果配置了 Secret 则填写,否则留空+4. 点击「添加后端」+5. 保存后开始自动采集数据++> 💡 **获取 OpenClash 地址**: 进入 OpenClash 插件 → 打开「外部控制」→ 复制地址++## 🐳 Docker 配置++### 端口说明++| 端口 | 用途 | 必需 |+| ---- | --------- | ---- |+| 3000 | Web 界面 | ✅ |+| 3001 | API 接口 | ✅ |+| 3002 | WebSocket | ✅ |++### 数据持久化++数据默认存储在容器内的 `/app/data` 目录,建议映射到宿主机:++```yaml+volumes:+ - ./data:/app/data+```++### 自定义端口++如需修改默认端口,创建 `docker-compose.override.yml`:++```yaml+services:+ clash-master:+ ports:+ - "8080:3000" # 将 3000 映射到宿主机的 8080+```++### 更新到最新版本++```bash+# Docker Compose+docker compose pull+docker compose up -d++# Docker (本地构建)+docker compose up -d --build+```++## 📁 项目结构++```+clash-master/+├── docker-compose.yml # Docker Compose 配置+├── Dockerfile # Docker 镜像构建+├── start.sh # 源码启动脚本+├── assets/ # 预览图和图标+├── apps/+│ ├── collector/ # 数据收集服务+│ └── web/ # Next.js 前端+└── packages/+ └── shared/ # 共享类型定义+```++## 🔧 常见问题++### Q: 连接 OpenClash 失败?++A: 检查以下几点:++1. OpenClash 的「外部控制」是否已开启+2. OpenClash 地址是否正确(格式:`IP:端口`)+3. 如果配置了 Secret,Token 是否填写正确+4. 容器是否能访问到 OpenClash 所在网络++### Q: 如何备份数据?++A: 数据存储在映射的目录中(默认 `./data/stats.db`),直接备份该目录即可。++### Q: 如何清理历史数据?++A: 在 Web 界面 → 设置 → 数据库管理中,可选择清理 1天前/7天前/30天前/全部数据。++### Q: 支持远程访问吗?++A: 支持,将 Docker 端口映射到公网 IP 即可。建议配合 Nginx 反向代理并启用 HTTPS。++## 🛠️ 技术栈++- **前端**: Next.js 15 + React 19 + TypeScript + Tailwind CSS+- **UI 组件**: shadcn/ui+- **图表**: Recharts+- **后端**: Node.js + Fastify + WebSocket+- **数据库**: SQLite (better-sqlite3)++## 🤝 贡献++欢迎提交 Issue 和 Pull Request!++## 📄 许可证++[MIT](LICENSE) © [foru17](https://github.com/foru17)++---++<p align="center">+ Made with ❤️ by <a href="https://github.com/foru17">foru17</a>+</p>diff --git a/apps/collector/.env.example b/apps/collector/.env.examplenew file mode 100644index 0000000..9dfe932--- /dev/null+++ b/apps/collector/.env.example@@ -0,0 +1,14 @@+# Clash Master Collector 配置(可选)+# 默认端口即可满足大部分需求++# API 服务端口(默认 3001)+# API_PORT=3001++# WebSocket 推送端口(默认 3002)+# WS_PORT=3002++# SQLite 数据库路径(默认当前目录)+# DB_PATH=./stats.db++# ⚠️ 注意:OpenClash 后端配置通过 Web 界面动态添加+# 无需在此文件配置 CLASH_URL 或 CLASH_TOKENdiff --git a/apps/collector/.gitignore b/apps/collector/.gitignorenew file mode 100644index 0000000..d880164--- /dev/null+++ b/apps/collector/.gitignore@@ -0,0 +1,16 @@+# Dependencies+node_modules/++# Build+dist/++# Environment+.env+.env.local++# Database+*.db+*.db-journal++# Logs+*.logdiff --git a/apps/collector/package.json b/apps/collector/package.jsonnew file mode 100644index 0000000..1cd1312--- /dev/null+++ b/apps/collector/package.json@@ -0,0 +1,25 @@+{+ "name": "@clashstats/collector",+ "version": "1.0.0",+ "type": "module",+ "scripts": {+ "dev": "tsx watch src/index.ts",+ "build": "tsc",+ "start": "node dist/index.js"+ },+ "dependencies": {+ "@clashstats/shared": "workspace:*",+ "@fastify/cors": "^9.0.0",+ "better-sqlite3": "^9.4.0",+ "dotenv": "^16.4.0",+ "fastify": "^4.26.0",+ "ws": "^8.19.0"+ },+ "devDependencies": {+ "@types/better-sqlite3": "^7.6.9",+ "@types/node": "^20.11.0",+ "@types/ws": "^8.18.1",+ "tsx": "^4.7.0",+ "typescript": "^5.4.0"+ }+}diff --git a/apps/collector/src/api.ts b/apps/collector/src/api.tsnew file mode 100644index 0000000..eb6947f--- /dev/null+++ b/apps/collector/src/api.ts@@ -0,0 +1,444 @@+import Fastify from 'fastify';+import cors from '@fastify/cors';+import type { StatsDatabase } from './db.js';++export class APIServer {+ private app: ReturnType<typeof Fastify> | null = null;+ private db: StatsDatabase;+ private port: number;++ constructor(port: number, db: StatsDatabase) {+ this.port = port;+ this.db = db;+ }++ async start() {+ const app = Fastify({ logger: false });+ this.app = app;++ await app.register(cors, {+ origin: true,+ credentials: true+ });++ // Helper to get backend ID from query or use active backend+ const getBackendId = (request: any): number | null => {+ const { backendId } = request.query as { backendId?: string };+ if (backendId) {+ const id = parseInt(backendId);+ return isNaN(id) ? null : id;+ }+ // If no backendId specified, use the active backend+ const activeBackend = this.db.getActiveBackend();+ return activeBackend?.id ?? null;+ };++ // Health check+ app.get('/health', async () => ({ status: 'ok' }));++ // Get summary statistics for a specific backend+ app.get('/api/stats/summary', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const backend = this.db.getBackend(backendId);+ if (!backend) {+ return reply.status(404).send({ error: 'Backend not found' });+ }++ const summary = this.db.getSummary(backendId);+ const topDomains = this.db.getTopDomains(backendId, 1000);+ const topIPs = this.db.getTopIPs(backendId, 1000);+ const proxyStats = this.db.getProxyStats(backendId);+ const ruleStats = this.db.getRuleStats(backendId);+ const hourlyStats = this.db.getHourlyStats(backendId, 24);+ const todayTraffic = this.db.getTodayTraffic(backendId);++ return {+ backend: {+ id: backend.id,+ name: backend.name,+ isActive: backend.is_active,+ listening: backend.listening,+ },+ totalConnections: summary.totalConnections,+ totalUpload: summary.totalUpload,+ totalDownload: summary.totalDownload,+ totalDomains: summary.uniqueDomains,+ totalIPs: summary.uniqueIPs,+ totalRules: ruleStats.length,+ totalProxies: proxyStats.length,+ todayUpload: todayTraffic.upload,+ todayDownload: todayTraffic.download,+ topDomains,+ topIPs,+ proxyStats,+ ruleStats,+ hourlyStats+ };+ });++ // Get global summary across all backends+ app.get('/api/stats/global', async () => {+ return this.db.getGlobalSummary();+ });++ // Get domain statistics for a specific backend+ app.get('/api/stats/domains', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const { limit = 50 } = request.query as { limit?: string };+ return this.db.getDomainStats(backendId, parseInt(limit as string) || 50);+ });++ // Get IP statistics for a specific backend+ app.get('/api/stats/ips', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const { limit = 50 } = request.query as { limit?: string };+ return this.db.getIPStats(backendId, parseInt(limit as string) || 50);+ });++ // Get proxy/chain statistics for a specific backend+ app.get('/api/stats/proxies', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ return this.db.getProxyStats(backendId);+ });++ // Get rule statistics for a specific backend+ app.get('/api/stats/rules', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ return this.db.getRuleStats(backendId);+ });++ // Get rule to proxy mapping for a specific backend+ app.get('/api/stats/rule-proxy-map', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ return this.db.getRuleProxyMap(backendId);+ });++ // Get country traffic statistics for a specific backend+ app.get('/api/stats/countries', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ return this.db.getCountryStats(backendId);+ });++ // Get hourly statistics for a specific backend+ app.get('/api/stats/hourly', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const { hours = 24 } = request.query as { hours?: string };+ return this.db.getHourlyStats(backendId, parseInt(hours as string) || 24);+ });++ // Get traffic trend for a specific backend (for time range selection)+ app.get('/api/stats/trend', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const { minutes = 30 } = request.query as { minutes?: string };+ return this.db.getTrafficTrend(backendId, parseInt(minutes as string) || 30);+ });++ // Get traffic trend aggregated by time buckets for chart display+ app.get('/api/stats/trend/aggregated', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const { minutes = 30, bucketMinutes = 1 } = request.query as { minutes?: string; bucketMinutes?: string };+ return this.db.getTrafficTrendAggregated(+ backendId,+ parseInt(minutes as string) || 30,+ parseInt(bucketMinutes as string) || 1+ );+ });++ // Get recent connections for a specific backend+ app.get('/api/stats/connections', async (request, reply) => {+ const backendId = getBackendId(request);++ if (backendId === null) {+ return reply.status(404).send({ error: 'No backend specified or active' });+ }++ const { limit = 100 } = request.query as { limit?: string };+ return this.db.getRecentConnections(backendId, parseInt(limit as string) || 100);+ });++ // Backend management APIs+ // Get all backends+ app.get('/api/backends', async () => {+ const backends = this.db.getAllBackends();+ // Don't return tokens for security+ return backends.map(({ token, ...rest }) => ({ ...rest, hasToken: !!token }));+ });++ // Get active backend+ app.get('/api/backends/active', async () => {+ const backend = this.db.getActiveBackend();+ if (!backend) {+ return { error: 'No active backend configured' };+ }+ // Don't return token for security+ const { token, ...rest } = backend;+ return { ...rest, hasToken: !!token };+ });++ // Get listening backends (all backends currently collecting data)+ app.get('/api/backends/listening', async () => {+ const backends = this.db.getListeningBackends();+ return backends.map(({ token, ...rest }) => ({ ...rest, hasToken: !!token }));+ });++ // Create new backend+ app.post('/api/backends', async (request, reply) => {+ const { name, url, token } = request.body as { name: string; url: string; token?: string };++ if (!name || !url) {+ return reply.status(400).send({ error: 'Name and URL are required' });+ }++ try {+ // Check if this is the first backend+ const existingBackends = this.db.getAllBackends();+ const isFirstBackend = existingBackends.length === 0;++ const id = this.db.createBackend({ name, url, token });++ // If this is the first backend, automatically set it as active+ if (isFirstBackend) {+ this.db.setActiveBackend(id);+ console.log(`[API] First backend created, automatically set as active: ${name} (ID: ${id})`);+ }++ return { id, isActive: isFirstBackend, message: 'Backend created successfully' };+ } catch (error: any) {+ if (error.message?.includes('UNIQUE constraint failed')) {+ return reply.status(409).send({ error: 'Backend name already exists' });+ }+ throw error;+ }+ });++ // Update backend+ app.put('/api/backends/:id', async (request, reply) => {+ const { id } = request.params as { id: string };+ const { name, url, token, enabled, listening } = request.body as {+ name?: string;+ url?: string;+ token?: string;+ enabled?: boolean;+ listening?: boolean;+ };++ const backendId = parseInt(id);+ const backend = this.db.getBackend(backendId);++ if (!backend) {+ return reply.status(404).send({ error: 'Backend not found' });+ }++ this.db.updateBackend(backendId, { name, url, token, enabled, listening });+ return { message: 'Backend updated successfully' };+ });++ // Delete backend+ app.delete('/api/backends/:id', async (request, reply) => {+ const { id } = request.params as { id: string };+ const backendId = parseInt(id);++ const backend = this.db.getBackend(backendId);+ if (!backend) {+ return reply.status(404).send({ error: 'Backend not found' });+ }++ this.db.deleteBackend(backendId);+ return { message: 'Backend deleted successfully' };+ });++ // Set active backend (for display in UI)+ app.post('/api/backends/:id/activate', async (request, reply) => {+ const { id } = request.params as { id: string };+ const backendId = parseInt(id);++ const backend = this.db.getBackend(backendId);+ if (!backend) {+ return reply.status(404).send({ error: 'Backend not found' });+ }++ this.db.setActiveBackend(backendId);+ return { message: 'Backend activated successfully' };+ });++ // Set listening state for a backend (controls data collection)+ app.post('/api/backends/:id/listening', async (request, reply) => {+ const { id } = request.params as { id: string };+ const { listening } = request.body as { listening: boolean };++ const backendId = parseInt(id);+ const backend = this.db.getBackend(backendId);++ if (!backend) {+ return reply.status(404).send({ error: 'Backend not found' });+ }++ this.db.setBackendListening(backendId, listening);+ return { message: `Backend ${listening ? 'started' : 'stopped'} listening` };+ });++ // Test backend connection+ app.post('/api/backends/test', async (request) => {+ const { url, token } = request.body as { url: string; token?: string };++ try {+ const wsUrl = url.replace('http://', 'ws://').replace('https://', 'wss://');+ const fullUrl = wsUrl.includes('/connections') ? wsUrl : `${wsUrl}/connections`;++ const headers: Record<string, string> = {};+ if (token) {+ headers['Authorization'] = `Bearer ${token}`;+ }++ // Try to establish WebSocket connection+ const WebSocket = (await import('ws')).default;++ return new Promise((resolve) => {+ const ws = new WebSocket(fullUrl, { headers, timeout: 5000 });++ ws.on('open', () => {+ ws.close();+ resolve({ success: true, message: 'Connection successful' });+ });++ ws.on('error', (error: any) => {+ resolve({ success: false, message: error.message || 'Connection failed' });+ });++ ws.on('close', (code: number) => {+ if (code !== 1000 && code !== 1005) {+ resolve({ success: false, message: `Connection closed with code ${code}` });+ }+ });++ // Timeout after 5 seconds+ setTimeout(() => {+ ws.terminate();+ resolve({ success: false, message: 'Connection timeout' });+ }, 5000);+ });+ } catch (error: any) {+ return { success: false, message: error.message || 'Connection failed' };+ }+ });++ // Clear all data for a specific backend+ app.post('/api/backends/:id/clear-data', async (request, reply) => {+ const { id } = request.params as { id: string };+ const backendId = parseInt(id);++ const backend = this.db.getBackend(backendId);+ if (!backend) {+ return reply.status(404).send({ error: 'Backend not found' });+ }++ this.db.deleteBackendData(backendId);+ return { message: 'Backend data cleared successfully' };+ });++ // Database management APIs+ // Get database stats+ app.get('/api/db/stats', async () => {+ return {+ size: this.db.getDatabaseSize(),+ totalConnectionsCount: this.db.getTotalConnectionLogsCount(),+ };+ });++ // Clear old logs (for all backends or specific backend)+ // days=0 means clear all logs+ app.post('/api/db/cleanup', async (request) => {+ const { days, backendId } = request.body as { days: number; backendId?: number };++ if (typeof days !== 'number' || days < 0) {+ return { error: 'Valid days parameter required' };+ }++ const result = this.db.cleanupOldData(backendId || null, days);++ if (days === 0) {+ return {+ message: `Cleaned all data: ${result.deletedConnections} connections, ${result.deletedDomains} domains, ${result.deletedProxies} proxies`,+ deleted: result.deletedConnections,+ domains: result.deletedDomains,+ ips: result.deletedIPs,+ proxies: result.deletedProxies,+ rules: result.deletedRules+ };+ }++ return {+ message: `Cleaned ${result.deletedConnections} old connection logs`,+ deleted: result.deletedConnections+ };+ });++ // Vacuum database+ app.post('/api/db/vacuum', async () => {+ this.db.vacuum();+ return { message: 'Database vacuumed successfully' };+ });++ await app.listen({ port: this.port, host: '0.0.0.0' });+ console.log(`[API] Server running at http://localhost:${this.port}`);++ return app;+ }++ stop() {+ if (this.app) {+ this.app.close();+ console.log('[API] Server stopped');+ }+ }+}diff --git a/apps/collector/src/collector.ts b/apps/collector/src/collector.tsnew file mode 100644index 0000000..65afa30--- /dev/null+++ b/apps/collector/src/collector.ts@@ -0,0 +1,295 @@+import WebSocket from 'ws';+import type { ConnectionsData } from '@clashstats/shared';+import { StatsDatabase } from './db.js';+import { GeoIPService } from './geo-service.js';++interface CollectorOptions {+ url: string;+ token?: string;+ reconnectInterval?: number;+ onData?: (data: ConnectionsData) => void;+ onError?: (error: Error) => void;+}++export class OpenClashCollector {+ private ws: WebSocket | null = null;+ private url: string;+ private token?: string;+ private reconnectInterval: number;+ private onData?: (data: ConnectionsData) => void;+ private onError?: (error: Error) => void;+ private reconnectTimer: NodeJS.Timeout | null = null;+ private isClosing = false;+ private backendId: number;++ constructor(backendId: number, options: CollectorOptions) {+ this.backendId = backendId;+ this.url = options.url;+ this.token = options.token;+ this.reconnectInterval = options.reconnectInterval || 5000;+ this.onData = options.onData;+ this.onError = options.onError;+ }++ connect() {+ if (this.isClosing) return;++ console.log(`[Collector:${this.backendId}] Connecting to ${this.url}...`);++ const headers: Record<string, string> = {+ 'Origin': this.url.replace('ws://', 'http://').replace('wss://', 'https://'),+ };++ if (this.token) {+ headers['Authorization'] = `Bearer ${this.token}`;+ }++ this.ws = new WebSocket(this.url, {+ headers,+ followRedirects: true,+ });++ this.ws.on('open', () => {+ console.log(`[Collector:${this.backendId}] WebSocket connected`);+ });++ this.ws.on('message', (data: WebSocket.Data) => {+ try {+ const json = JSON.parse(data.toString()) as ConnectionsData;+ this.onData?.(json);+ } catch (err) {+ console.error(`[Collector:${this.backendId}] Failed to parse message:`, err);+ }+ });++ this.ws.on('error', (err) => {+ console.error(`[Collector:${this.backendId}] WebSocket error:`, err.message);+ this.onError?.(err);+ });++ this.ws.on('close', (code, reason) => {+ console.log(`[Collector:${this.backendId}] WebSocket closed: ${code} ${reason}`);+ if (!this.isClosing) {+ this.scheduleReconnect();+ }+ });+ }++ private scheduleReconnect() {+ if (this.reconnectTimer) return;+ console.log(`[Collector:${this.backendId}] Reconnecting in ${this.reconnectInterval}ms...`);+ this.reconnectTimer = setTimeout(() => {+ this.reconnectTimer = null;+ this.connect();+ }, this.reconnectInterval);+ }++ disconnect() {+ this.isClosing = true;+ if (this.reconnectTimer) {+ clearTimeout(this.reconnectTimer);+ this.reconnectTimer = null;+ }+ if (this.ws) {+ this.ws.close();+ this.ws = null;+ }+ console.log(`[Collector:${this.backendId}] Disconnected`);+ }+}++// Track connection state with their accumulated traffic+interface TrackedConnection {+ id: string;+ domain: string;+ ip: string;+ chains: string[];+ lastUpload: number;+ lastDownload: number;+ totalUpload: number;+ totalDownload: number;+}++export function createCollector(+ db: StatsDatabase,+ url: string,+ token?: string,+ geoService?: GeoIPService,+ onTrafficUpdate?: () => void,+ backendId?: number // Backend ID for data isolation+) {+ const id = backendId || 0;+ const activeConnections = new Map<string, TrackedConnection>();+ let lastLogTime = 0;+ let lastBroadcastTime = 0;+ const broadcastThrottleMs = 500;++ return new OpenClashCollector(id, {+ url,+ token,+ onData: (data) => {+ // Validate data format - be more lenient+ if (!data) {+ console.warn(`[Collector:${id}] Received null/undefined data`);+ return;+ }++ // Some backends send empty messages or keepalive packets+ if (!data.connections) {+ // Silently ignore - this is normal for some backends+ return;+ }++ if (!Array.isArray(data.connections)) {+ console.warn(`[Collector:${id}] Invalid connections format: ${typeof data.connections}`);+ return;+ }++ const now = Date.now();+ const currentIds = new Set(data.connections.map(c => c?.id).filter(Boolean));+ let hasNewTraffic = false;++ // Process all current connections+ for (const conn of data.connections) {+ // Skip invalid connection entries - be more lenient+ if (!conn || typeof conn !== 'object') {+ continue;+ }++ // Some backends may not have all fields+ if (!conn.id) {+ continue;+ }++ // Ensure metadata exists with defaults+ const metadata = conn.metadata || {};+ const domain = metadata.host || metadata.sniffHost || '';+ const ip = metadata.destinationIP || '';+ const chains = Array.isArray(conn.chains) ? conn.chains : ['DIRECT'];++ const existing = activeConnections.get(conn.id);++ if (!existing) {+ // New connection - track it and record initial traffic+ activeConnections.set(conn.id, {+ id: conn.id,+ domain,+ ip,+ chains,+ lastUpload: 0,+ lastDownload: 0,+ totalUpload: conn.upload,+ totalDownload: conn.download,+ });++ // Record initial traffic for new connection+ if (conn.upload > 0 || conn.download > 0) {+ db.updateTrafficStats(id, {+ domain,+ ip,+ chain: chains[0] || 'DIRECT',+ chains,+ upload: conn.upload,+ download: conn.download,+ });++ // Query and update country stats if GeoIP service is available+ if (geoService && ip) {+ geoService.getGeoLocation(ip).then((geo: { country: string; country_name: string; continent: string } | null) => {+ if (geo) {+ db.updateCountryStats(+ id,+ geo.country,+ geo.country_name,+ geo.continent,+ conn.upload,+ conn.download+ );+ }+ }).catch((err: Error) => {+ // Silently fail for GeoIP errors+ });+ }++ hasNewTraffic = true;+ }+ } else {+ // Existing connection - calculate delta and update stats+ const uploadDelta = Math.max(0, conn.upload - existing.lastUpload);+ const downloadDelta = Math.max(0, conn.download - existing.lastDownload);++ if (uploadDelta > 0 || downloadDelta > 0) {+ // Update accumulated traffic for this connection+ existing.totalUpload += uploadDelta;+ existing.totalDownload += downloadDelta;++ // Update stats in database with delta+ db.updateTrafficStats(id, {+ domain: existing.domain,+ ip: existing.ip,+ chain: existing.chains[0] || 'DIRECT',+ chains: existing.chains,+ upload: uploadDelta,+ download: downloadDelta,+ });++ // Query and update country stats if GeoIP service is available+ if (geoService && existing.ip) {+ geoService.getGeoLocation(existing.ip).then((geo: { country: string; country_name: string; continent: string } | null) => {+ if (geo) {+ db.updateCountryStats(+ id,+ geo.country,+ geo.country_name,+ geo.continent,+ uploadDelta,+ downloadDelta+ );+ }+ }).catch((err: Error) => {+ // Silently fail for GeoIP errors+ });+ }++ existing.lastUpload = conn.upload;+ existing.lastDownload = conn.download;+ hasNewTraffic = true;+ }+ }+ }++ // Find closed connections and flush their remaining traffic+ for (const [connId, tracked] of activeConnections) {+ if (!currentIds.has(connId)) {+ // Connection closed - any remaining traffic was already counted+ activeConnections.delete(connId);+ }+ }++ // Broadcast to WebSocket clients if there's new traffic (with throttling)+ if (hasNewTraffic && onTrafficUpdate && now - lastBroadcastTime > broadcastThrottleMs) {+ lastBroadcastTime = now;+ onTrafficUpdate();+ }++ // Log stats periodically (every 10 seconds)+ if (now - lastLogTime > 10000) {+ const domains = new Set<string>();+ const rules = new Set<string>();++ for (const conn of activeConnections.values()) {+ if (conn.domain) domains.add(conn.domain);+ // The initial rule is the last element in chains array+ const initialRule = conn.chains.length > 0 ? conn.chains[conn.chains.length - 1] : 'DIRECT';+ rules.add(initialRule);+ }++ console.log(`[Collector:${id}] Active: ${activeConnections.size}, Domains: ${domains.size}, Rules: ${rules.size}`);+ lastLogTime = now;+ }+ },+ onError: (err) => {+ console.error(`[Collector:${id}] Error:`, err);+ }+ });+}diff --git a/apps/collector/src/db.ts b/apps/collector/src/db.tsnew file mode 100644index 0000000..c9fcdac--- /dev/null+++ b/apps/collector/src/db.ts@@ -0,0 +1,1265 @@+import Database from 'better-sqlite3';+import path from 'path';+import fs from 'fs';+import type { Connection, DomainStats, IPStats, HourlyStats, DailyStats, ProxyStats, RuleStats } from '@clashstats/shared';++export interface TrafficUpdate {+ domain: string;+ ip: string;+ chain: string;+ chains: string[];+ upload: number;+ download: number;+}++export interface BackendConfig {+ id: number;+ name: string;+ url: string;+ token: string;+ enabled: boolean;+ is_active: boolean;+ listening: boolean;+ created_at: string;+ updated_at: string;+}++export class StatsDatabase {+ private db: Database.Database;+ private dbPath: string;++ constructor(dbPath = 'stats.db') {+ this.dbPath = path.resolve(dbPath);+ this.db = new Database(this.dbPath);+ this.init();+ }++ private init() {+ // Domain statistics - aggregated by domain per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS domain_stats (+ backend_id INTEGER NOT NULL,+ domain TEXT NOT NULL,+ ips TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ rules TEXT,+ chains TEXT,+ PRIMARY KEY (backend_id, domain),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // IP statistics per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS ip_stats (+ backend_id INTEGER NOT NULL,+ ip TEXT NOT NULL,+ domains TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ asn TEXT,+ geoip TEXT,+ PRIMARY KEY (backend_id, ip),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // Proxy/Chain statistics per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS proxy_stats (+ backend_id INTEGER NOT NULL,+ chain TEXT NOT NULL,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ PRIMARY KEY (backend_id, chain),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // Rule statistics per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS rule_stats (+ backend_id INTEGER NOT NULL,+ rule TEXT NOT NULL,+ final_proxy TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ PRIMARY KEY (backend_id, rule),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // Rule to proxy mapping per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS rule_proxy_map (+ backend_id INTEGER NOT NULL,+ rule TEXT,+ proxy TEXT,+ PRIMARY KEY (backend_id, rule, proxy),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // ASN cache+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS asn_cache (+ ip TEXT PRIMARY KEY,+ asn TEXT,+ org TEXT,+ queried_at DATETIME DEFAULT CURRENT_TIMESTAMP+ );+ `);++ // GeoIP cache+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS geoip_cache (+ ip TEXT PRIMARY KEY,+ country TEXT,+ country_name TEXT,+ city TEXT,+ asn TEXT,+ as_name TEXT,+ as_domain TEXT,+ continent TEXT,+ continent_name TEXT,+ queried_at DATETIME DEFAULT CURRENT_TIMESTAMP+ );+ `);++ // Country traffic statistics per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS country_stats (+ backend_id INTEGER NOT NULL,+ country TEXT NOT NULL,+ country_name TEXT,+ continent TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ PRIMARY KEY (backend_id, country),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // Hourly aggregation per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS hourly_stats (+ backend_id INTEGER NOT NULL,+ hour TEXT NOT NULL,+ upload INTEGER DEFAULT 0,+ download INTEGER DEFAULT 0,+ connections INTEGER DEFAULT 0,+ PRIMARY KEY (backend_id, hour),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // Connection log per backend+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS connection_logs (+ id INTEGER PRIMARY KEY AUTOINCREMENT,+ backend_id INTEGER NOT NULL,+ domain TEXT,+ ip TEXT,+ chain TEXT,+ upload INTEGER DEFAULT 0,+ download INTEGER DEFAULT 0,+ timestamp DATETIME DEFAULT CURRENT_TIMESTAMP,+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);++ // Create indexes+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_domain_stats_backend ON domain_stats(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_domain_stats_traffic ON domain_stats(total_download + total_upload);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_ip_stats_backend ON ip_stats(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_ip_stats_traffic ON ip_stats(total_download + total_upload);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_proxy_stats_backend ON proxy_stats(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_proxy_stats_traffic ON proxy_stats(total_download + total_upload);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_rule_stats_backend ON rule_stats(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_rule_stats_traffic ON rule_stats(total_download + total_upload);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_rule_proxy_map ON rule_proxy_map(backend_id, rule, proxy);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_country_stats_backend ON country_stats(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_hourly_stats_backend ON hourly_stats(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_connection_logs_backend ON connection_logs(backend_id);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_connection_logs_timestamp ON connection_logs(timestamp);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_connection_logs_domain ON connection_logs(domain);`);+ this.db.exec(`CREATE INDEX IF NOT EXISTS idx_connection_logs_chain ON connection_logs(chain);`);++ // Backend configurations - stores OpenClash backend connections+ this.db.exec(`+ CREATE TABLE IF NOT EXISTS backend_configs (+ id INTEGER PRIMARY KEY AUTOINCREMENT,+ name TEXT NOT NULL,+ url TEXT NOT NULL,+ token TEXT DEFAULT '',+ enabled BOOLEAN DEFAULT 1,+ is_active BOOLEAN DEFAULT 0,+ listening BOOLEAN DEFAULT 1,+ created_at DATETIME DEFAULT CURRENT_TIMESTAMP,+ updated_at DATETIME DEFAULT CURRENT_TIMESTAMP+ );+ `);++ // Create unique index on name+ this.db.exec(`CREATE UNIQUE INDEX IF NOT EXISTS idx_backend_configs_name ON backend_configs(name);`);++ // Migrate existing data if needed (from single-backend schema)+ this.migrateIfNeeded();+ }++ // Migrate from old single-backend schema to multi-backend schema+ private migrateIfNeeded() {+ // Check if we need to migrate by checking if there's data without backend_id+ const needsMigration = this.db.prepare(`+ SELECT 1 FROM sqlite_master+ WHERE type='table' AND name='domain_stats'+ `).get() as { '1': number } | undefined;++ if (!needsMigration) return;++ // Check if domain_stats table has backend_id column+ const tableInfo = this.db.prepare(`PRAGMA table_info(domain_stats)`).all() as { name: string }[];+ const hasBackendId = tableInfo.some(col => col.name === 'backend_id');++ if (!hasBackendId) {+ console.log('[DB] Migrating from single-backend to multi-backend schema...');+ this.performMigration();+ }++ // Check if backend_configs has listening column+ const backendInfo = this.db.prepare(`PRAGMA table_info(backend_configs)`).all() as { name: string }[];+ const hasListening = backendInfo.some(col => col.name === 'listening');++ if (!hasListening) {+ console.log('[DB] Adding listening column to backend_configs...');+ this.db.exec(`ALTER TABLE backend_configs ADD COLUMN listening BOOLEAN DEFAULT 1;`);+ }+ }++ private performMigration() {+ // Create temporary tables with new schema and migrate data+ // This is a complex migration - we'll create a default backend and associate all data with it++ this.db.exec(`BEGIN TRANSACTION;`);++ try {+ // Create a default backend if none exists+ const existingBackend = this.db.prepare(`SELECT id FROM backend_configs LIMIT 1`).get() as { id: number } | undefined;+ let defaultBackendId: number;++ if (!existingBackend) {+ const result = this.db.prepare(`+ INSERT INTO backend_configs (name, url, token, enabled, is_active, listening)+ VALUES ('Default', 'http://192.168.1.1:9090', '', 1, 1, 1)+ `).run();+ defaultBackendId = Number(result.lastInsertRowid);+ } else {+ defaultBackendId = existingBackend.id;+ }++ // Migrate domain_stats - recreate table with new schema+ this.db.exec(`+ CREATE TABLE domain_stats_new (+ backend_id INTEGER NOT NULL,+ domain TEXT NOT NULL,+ ips TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ rules TEXT,+ chains TEXT,+ PRIMARY KEY (backend_id, domain),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO domain_stats_new+ SELECT ${defaultBackendId} as backend_id, domain, ips, total_upload, total_download,+ total_connections, last_seen, rules, chains+ FROM domain_stats;+ `);+ this.db.exec(`DROP TABLE domain_stats;`);+ this.db.exec(`ALTER TABLE domain_stats_new RENAME TO domain_stats;`);++ // Migrate ip_stats+ this.db.exec(`+ CREATE TABLE ip_stats_new (+ backend_id INTEGER NOT NULL,+ ip TEXT NOT NULL,+ domains TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ asn TEXT,+ geoip TEXT,+ PRIMARY KEY (backend_id, ip),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO ip_stats_new+ SELECT ${defaultBackendId} as backend_id, ip, domains, total_upload, total_download,+ total_connections, last_seen, asn, geoip+ FROM ip_stats;+ `);+ this.db.exec(`DROP TABLE ip_stats;`);+ this.db.exec(`ALTER TABLE ip_stats_new RENAME TO ip_stats;`);++ // Migrate proxy_stats+ this.db.exec(`+ CREATE TABLE proxy_stats_new (+ backend_id INTEGER NOT NULL,+ chain TEXT NOT NULL,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ PRIMARY KEY (backend_id, chain),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO proxy_stats_new+ SELECT ${defaultBackendId} as backend_id, chain, total_upload, total_download,+ total_connections, last_seen+ FROM proxy_stats;+ `);+ this.db.exec(`DROP TABLE proxy_stats;`);+ this.db.exec(`ALTER TABLE proxy_stats_new RENAME TO proxy_stats;`);++ // Migrate rule_stats+ this.db.exec(`+ CREATE TABLE rule_stats_new (+ backend_id INTEGER NOT NULL,+ rule TEXT NOT NULL,+ final_proxy TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ PRIMARY KEY (backend_id, rule),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO rule_stats_new+ SELECT ${defaultBackendId} as backend_id, rule, final_proxy, total_upload, total_download,+ total_connections, last_seen+ FROM rule_stats;+ `);+ this.db.exec(`DROP TABLE rule_stats;`);+ this.db.exec(`ALTER TABLE rule_stats_new RENAME TO rule_stats;`);++ // Migrate rule_proxy_map+ this.db.exec(`+ CREATE TABLE rule_proxy_map_new (+ backend_id INTEGER NOT NULL,+ rule TEXT,+ proxy TEXT,+ PRIMARY KEY (backend_id, rule, proxy),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO rule_proxy_map_new+ SELECT ${defaultBackendId} as backend_id, rule, proxy+ FROM rule_proxy_map;+ `);+ this.db.exec(`DROP TABLE rule_proxy_map;`);+ this.db.exec(`ALTER TABLE rule_proxy_map_new RENAME TO rule_proxy_map;`);++ // Migrate country_stats+ this.db.exec(`+ CREATE TABLE country_stats_new (+ backend_id INTEGER NOT NULL,+ country TEXT NOT NULL,+ country_name TEXT,+ continent TEXT,+ total_upload INTEGER DEFAULT 0,+ total_download INTEGER DEFAULT 0,+ total_connections INTEGER DEFAULT 0,+ last_seen DATETIME,+ PRIMARY KEY (backend_id, country),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO country_stats_new+ SELECT ${defaultBackendId} as backend_id, country, country_name, continent, total_upload,+ total_download, total_connections, last_seen+ FROM country_stats;+ `);+ this.db.exec(`DROP TABLE country_stats;`);+ this.db.exec(`ALTER TABLE country_stats_new RENAME TO country_stats;`);++ // Migrate hourly_stats+ this.db.exec(`+ CREATE TABLE hourly_stats_new (+ backend_id INTEGER NOT NULL,+ hour TEXT NOT NULL,+ upload INTEGER DEFAULT 0,+ download INTEGER DEFAULT 0,+ connections INTEGER DEFAULT 0,+ PRIMARY KEY (backend_id, hour),+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO hourly_stats_new+ SELECT ${defaultBackendId} as backend_id, hour, upload, download, connections+ FROM hourly_stats;+ `);+ this.db.exec(`DROP TABLE hourly_stats;`);+ this.db.exec(`ALTER TABLE hourly_stats_new RENAME TO hourly_stats;`);++ // Migrate connection_logs+ this.db.exec(`+ CREATE TABLE connection_logs_new (+ id INTEGER PRIMARY KEY AUTOINCREMENT,+ backend_id INTEGER NOT NULL,+ domain TEXT,+ ip TEXT,+ chain TEXT,+ upload INTEGER DEFAULT 0,+ download INTEGER DEFAULT 0,+ timestamp DATETIME DEFAULT CURRENT_TIMESTAMP,+ FOREIGN KEY (backend_id) REFERENCES backend_configs(id) ON DELETE CASCADE+ );+ `);+ this.db.exec(`+ INSERT INTO connection_logs_new (id, backend_id, domain, ip, chain, upload, download, timestamp)+ SELECT id, ${defaultBackendId} as backend_id, domain, ip, chain, upload, download, timestamp+ FROM connection_logs;+ `);+ this.db.exec(`DROP TABLE connection_logs;`);+ this.db.exec(`ALTER TABLE connection_logs_new RENAME TO connection_logs;`);++ this.db.exec(`COMMIT;`);+ console.log('[DB] Migration completed successfully');+ } catch (error) {+ this.db.exec(`ROLLBACK;`);+ console.error('[DB] Migration failed:', error);+ throw error;+ }+ }++ // Update traffic stats with delta values for a specific backend+ updateTrafficStats(backendId: number, update: TrafficUpdate) {+ const now = new Date();+ const timestamp = now.toISOString();+ const hour = timestamp.slice(0, 13) + ':00:00';++ // Only process if there's actual traffic+ if (update.upload === 0 && update.download === 0) return;++ // Get the initial rule (last element in chains array) and final proxy (first element)+ const initialRule = update.chains.length > 0 ? update.chains[update.chains.length - 1] : 'DIRECT';+ const finalProxy = update.chains.length > 0 ? update.chains[0] : 'DIRECT';++ const transaction = this.db.transaction(() => {+ // Update domain stats with backend_id (skip if domain is unknown)+ const domainName = update.domain || 'unknown';+ if (domainName !== 'unknown') {+ const domainStmt = this.db.prepare(`+ INSERT INTO domain_stats (backend_id, domain, ips, total_upload, total_download, total_connections, last_seen, rules, chains)+ VALUES (@backendId, @domain, @ip, @upload, @download, 1, @timestamp, @rule, @chain)+ ON CONFLICT(backend_id, domain) DO UPDATE SET+ ips = CASE+ WHEN domain_stats.ips IS NULL THEN @ip+ WHEN INSTR(domain_stats.ips, @ip) > 0 THEN domain_stats.ips+ ELSE domain_stats.ips || ',' || @ip+ END,+ total_upload = total_upload + @upload,+ total_download = total_download + @download,+ total_connections = total_connections + 1,+ last_seen = @timestamp,+ rules = CASE+ WHEN domain_stats.rules IS NULL THEN @rule+ WHEN INSTR(domain_stats.rules, @rule) > 0 THEN domain_stats.rules+ ELSE domain_stats.rules || ',' || @rule+ END,+ chains = CASE+ WHEN domain_stats.chains IS NULL THEN @chain+ WHEN INSTR(domain_stats.chains, @chain) > 0 THEN domain_stats.chains+ ELSE domain_stats.chains || ',' || @chain+ END+ `);+ domainStmt.run({+ backendId,+ domain: domainName,+ ip: update.ip,+ upload: update.upload,+ download: update.download,+ timestamp,+ rule: initialRule,+ chain: update.chain+ });+ }++ // Update IP stats with backend_id+ const ipStmt = this.db.prepare(`+ INSERT INTO ip_stats (backend_id, ip, domains, total_upload, total_download, total_connections, last_seen)+ VALUES (@backendId, @ip, @domain, @upload, @download, 1, @timestamp)+ ON CONFLICT(backend_id, ip) DO UPDATE SET+ domains = CASE+ WHEN ip_stats.domains IS NULL THEN @domain+ WHEN INSTR(ip_stats.domains, @domain) > 0 THEN ip_stats.domains+ ELSE ip_stats.domains || ',' || @domain+ END,+ total_upload = total_upload + @upload,+ total_download = total_download + @download,+ total_connections = total_connections + 1,+ last_seen = @timestamp+ `);+ ipStmt.run({+ backendId,+ ip: update.ip,+ domain: update.domain || 'unknown',+ upload: update.upload,+ download: update.download,+ timestamp+ });++ // Update proxy stats with backend_id+ const proxyStmt = this.db.prepare(`+ INSERT INTO proxy_stats (backend_id, chain, total_upload, total_download, total_connections, last_seen)+ VALUES (@backendId, @chain, @upload, @download, 1, @timestamp)+ ON CONFLICT(backend_id, chain) DO UPDATE SET+ total_upload = total_upload + @upload,+ total_download = total_download + @download,+ total_connections = total_connections + 1,+ last_seen = @timestamp+ `);+ proxyStmt.run({+ backendId,+ chain: update.chain,+ upload: update.upload,+ download: update.download,+ timestamp+ });++ // Update rule stats with backend_id+ const ruleStmt = this.db.prepare(`+ INSERT INTO rule_stats (backend_id, rule, final_proxy, total_upload, total_download, total_connections, last_seen)+ VALUES (@backendId, @rule, @finalProxy, @upload, @download, 1, @timestamp)+ ON CONFLICT(backend_id, rule) DO UPDATE SET+ final_proxy = @finalProxy,+ total_upload = total_upload + @upload,+ total_download = total_download + @download,+ total_connections = total_connections + 1,+ last_seen = @timestamp+ `);+ ruleStmt.run({+ backendId,+ rule: initialRule,+ finalProxy,+ upload: update.upload,+ download: update.download,+ timestamp+ });++ // Update rule-proxy mapping with backend_id+ if (update.chains.length > 1) {+ const rule = update.chains[update.chains.length - 1];+ const proxy = update.chains[0];+ const ruleProxyStmt = this.db.prepare(`+ INSERT OR IGNORE INTO rule_proxy_map (backend_id, rule, proxy)+ VALUES (@backendId, @rule, @proxy)+ `);+ ruleProxyStmt.run({ backendId, rule, proxy });+ }++ // Update hourly stats with backend_id+ const hourlyStmt = this.db.prepare(`+ INSERT INTO hourly_stats (backend_id, hour, upload, download, connections)+ VALUES (@backendId, @hour, @upload, @download, 1)+ ON CONFLICT(backend_id, hour) DO UPDATE SET+ upload = upload + @upload,+ download = download + @download,+ connections = connections + 1+ `);+ hourlyStmt.run({ backendId, hour, upload: update.upload, download: update.download });++ // Insert connection log with backend_id+ const logStmt = this.db.prepare(`+ INSERT INTO connection_logs (backend_id, domain, ip, chain, upload, download)+ VALUES (@backendId, @domain, @ip, @chain, @upload, @download)+ `);+ logStmt.run({+ backendId,+ domain: update.domain || 'unknown',+ ip: update.ip,+ chain: update.chain,+ upload: update.upload,+ download: update.download+ });+ });++ transaction();+ }++ // Get all domain stats for a specific backend+ getDomainStats(backendId: number, limit = 100): DomainStats[] {+ const stmt = this.db.prepare(`+ SELECT domain, total_upload as totalUpload, total_download as totalDownload,+ total_connections as totalConnections, last_seen as lastSeen, ips, rules, chains+ FROM domain_stats+ WHERE backend_id = ?+ ORDER BY (total_upload + total_download) DESC+ LIMIT ?+ `);+ const rows = stmt.all(backendId, limit) as Array<{+ domain: string;+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen: string;+ ips: string | null;+ rules: string | null;+ chains: string | null;+ }>;++ return rows.map(row => ({+ ...row,+ ips: row.ips ? row.ips.split(',') : [],+ rules: row.rules ? row.rules.split(',') : [],+ chains: row.chains ? row.chains.split(',') : [],+ })) as DomainStats[];+ }++ // Get all IP stats for a specific backend+ getIPStats(backendId: number, limit = 100): IPStats[] {+ const stmt = this.db.prepare(`+ SELECT+ i.ip,+ i.domains,+ i.total_upload as totalUpload,+ i.total_download as totalDownload,+ i.total_connections as totalConnections,+ i.last_seen as lastSeen,+ COALESCE(i.asn, g.asn) as asn,+ CASE+ WHEN g.country IS NOT NULL THEN+ json_array(+ COALESCE(g.country_name, g.country),+ COALESCE(g.city, ''),+ COALESCE(g.as_name, '')+ )+ WHEN i.geoip IS NOT NULL THEN+ json(i.geoip)+ ELSE+ NULL+ END as geoIP+ FROM ip_stats i+ LEFT JOIN geoip_cache g ON i.ip = g.ip+ WHERE i.backend_id = ?+ ORDER BY (i.total_upload + i.total_download) DESC+ LIMIT ?+ `);+ const rows = stmt.all(backendId, limit) as Array<{+ ip: string;+ domains: string;+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen: string;+ asn: string | null;+ geoIP: string | null;+ }>;++ return rows.map(row => ({+ ...row,+ domains: row.domains ? row.domains.split(',') : [],+ geoIP: row.geoIP ? JSON.parse(row.geoIP).filter(Boolean) : undefined,+ asn: row.asn || undefined,+ })) as IPStats[];+ }++ // Get hourly stats for a specific backend+ getHourlyStats(backendId: number, hours = 24): HourlyStats[] {+ const stmt = this.db.prepare(`+ SELECT hour, upload, download, connections+ FROM hourly_stats+ WHERE backend_id = ?+ ORDER BY hour DESC+ LIMIT ?+ `);+ return stmt.all(backendId, hours) as HourlyStats[];+ }++ // Get today's traffic for a specific backend+ getTodayTraffic(backendId: number): { upload: number; download: number } {+ const today = new Date().toISOString().split('T')[0]; // YYYY-MM-DD+ const stmt = this.db.prepare(`+ SELECT COALESCE(SUM(upload), 0) as upload, COALESCE(SUM(download), 0) as download+ FROM hourly_stats+ WHERE backend_id = ? AND hour >= ?+ `);+ return stmt.get(backendId, today) as { upload: number; download: number };+ }++ // Get traffic trend for a specific backend (for time range selection)+ getTrafficTrend(backendId: number, minutes = 30): Array<{ time: string; upload: number; download: number }> {+ const cutoff = new Date(Date.now() - minutes * 60 * 1000).toISOString();+ const stmt = this.db.prepare(`+ SELECT strftime('%Y-%m-%dT%H:%M:%S', timestamp) as time, upload, download+ FROM connection_logs+ WHERE backend_id = ? AND datetime(timestamp) > datetime(?)+ ORDER BY timestamp ASC+ `);+ return stmt.all(backendId, cutoff) as Array<{ time: string; upload: number; download: number }>;+ }++ // Get traffic trend aggregated by time buckets for chart display+ getTrafficTrendAggregated(backendId: number, minutes = 30, bucketMinutes = 1): Array<{ time: string; upload: number; download: number }> {+ const cutoff = new Date(Date.now() - minutes * 60 * 1000).toISOString();++ // SQLite datetime formatting for bucketing+ // Use strftime to bucket by minute intervals+ const bucketExpr = bucketMinutes === 1+ ? `strftime('%Y-%m-%dT%H:%M:00', datetime(timestamp))`+ : `strftime('%Y-%m-%dT%H:%M:00', datetime((strftime('%s', datetime(timestamp)) / ${bucketMinutes * 60}) * ${bucketMinutes * 60}, 'unixepoch'))`;++ const stmt = this.db.prepare(`+ SELECT+ ${bucketExpr} as time,+ SUM(upload) as upload,+ SUM(download) as download+ FROM connection_logs+ WHERE backend_id = ? AND datetime(timestamp) > datetime(?)+ GROUP BY ${bucketExpr}+ ORDER BY time ASC+ `);+ return stmt.all(backendId, cutoff) as Array<{ time: string; upload: number; download: number }>;+ }++ // Get country stats for a specific backend+ getCountryStats(backendId: number): Array<{ country: string; countryName: string; continent: string; totalUpload: number; totalDownload: number; totalConnections: number }> {+ const stmt = this.db.prepare(`+ SELECT country, country_name as countryName, continent,+ total_upload as totalUpload, total_download as totalDownload,+ total_connections as totalConnections+ FROM country_stats+ WHERE backend_id = ?+ ORDER BY (total_upload + total_download) DESC+ `);+ return stmt.all(backendId) as Array<{ country: string; countryName: string; continent: string; totalUpload: number; totalDownload: number; totalConnections: number }>;+ }++ // Update country stats for a specific backend+ updateCountryStats(backendId: number, country: string, countryName: string, continent: string, upload: number, download: number) {+ const stmt = this.db.prepare(`+ INSERT INTO country_stats (backend_id, country, country_name, continent, total_upload, total_download, total_connections, last_seen)+ VALUES (?, ?, ?, ?, ?, ?, 1, CURRENT_TIMESTAMP)+ ON CONFLICT(backend_id, country) DO UPDATE SET+ total_upload = total_upload + ?,+ total_download = total_download + ?,+ total_connections = total_connections + 1,+ last_seen = CURRENT_TIMESTAMP+ `);+ stmt.run(backendId, country, countryName, continent, upload, download, upload, download);+ }++ // Get top domains for a specific backend+ getTopDomains(backendId: number, limit = 10): DomainStats[] {+ return this.getDomainStats(backendId, limit);+ }++ // Get top IPs for a specific backend+ getTopIPs(backendId: number, limit = 10): IPStats[] {+ return this.getIPStats(backendId, limit);+ }++ // Get proxy stats for a specific backend+ getProxyStats(backendId: number): ProxyStats[] {+ const stmt = this.db.prepare(`+ SELECT chain, total_upload as totalUpload, total_download as totalDownload,+ total_connections as totalConnections, last_seen as lastSeen+ FROM proxy_stats+ WHERE backend_id = ?+ ORDER BY (total_upload + total_download) DESC+ `);+ return stmt.all(backendId) as ProxyStats[];+ }++ // Get rule stats for a specific backend+ getRuleStats(backendId: number): RuleStats[] {+ const stmt = this.db.prepare(`+ SELECT rule, final_proxy as finalProxy, total_upload as totalUpload, total_download as totalDownload,+ total_connections as totalConnections, last_seen as lastSeen+ FROM rule_stats+ WHERE backend_id = ?+ ORDER BY (total_upload + total_download) DESC+ `);+ return stmt.all(backendId) as RuleStats[];+ }++ // Get rule-proxy mapping for a specific backend+ getRuleProxyMap(backendId: number): Array<{ rule: string; proxies: string[] }> {+ const stmt = this.db.prepare(`+ SELECT rule, proxy FROM rule_proxy_map WHERE backend_id = ? ORDER BY rule, proxy+ `);+ const rows = stmt.all(backendId) as Array<{ rule: string; proxy: string }>;++ const map = new Map<string, string[]>();+ for (const row of rows) {+ if (!map.has(row.rule)) {+ map.set(row.rule, []);+ }+ map.get(row.rule)!.push(row.proxy);+ }++ return Array.from(map.entries()).map(([rule, proxies]) => ({ rule, proxies }));+ }++ // Update ASN info for an IP+ updateASNInfo(ip: string, asn: string, org: string) {+ const stmt = this.db.prepare(`+ INSERT INTO asn_cache (ip, asn, org, queried_at)+ VALUES (?, ?, ?, CURRENT_TIMESTAMP)+ ON CONFLICT(ip) DO UPDATE SET+ asn = ?,+ org = ?,+ queried_at = CURRENT_TIMESTAMP+ `);+ stmt.run(ip, asn, org, asn, org);+ }++ // Get ASN info for IPs+ getASNInfo(ips: string[]): Array<{ ip: string; asn: string; org: string }> {+ const stmt = this.db.prepare(`+ SELECT ip, asn, org FROM asn_cache WHERE ip IN (${ips.map(() => '?').join(',')})+ `);+ return stmt.all(...ips) as Array<{ ip: string; asn: string; org: string }>;+ }++ // Get ASN info for a single IP+ getASNInfoForIP(ip: string): { ip: string; asn: string; org: string } | undefined {+ const stmt = this.db.prepare(`SELECT ip, asn, org FROM asn_cache WHERE ip = ?`);+ return stmt.get(ip) as { ip: string; asn: string; org: string } | undefined;+ }++ // Get GeoIP info for an IP (from cache)+ getIPGeolocation(ip: string): {+ country: string;+ country_name: string;+ city: string;+ asn: string;+ as_name: string;+ as_domain: string;+ continent: string;+ continent_name: string;+ } | undefined {+ const stmt = this.db.prepare(`+ SELECT country, country_name, city, asn, as_name, as_domain, continent, continent_name+ FROM geoip_cache+ WHERE ip = ?+ `);+ return stmt.get(ip) as {+ country: string;+ country_name: string;+ city: string;+ asn: string;+ as_name: string;+ as_domain: string;+ continent: string;+ continent_name: string;+ } | undefined;+ }++ // Save GeoIP info to cache+ saveIPGeolocation(ip: string, geo: {+ country: string;+ country_name: string;+ city: string;+ asn: string;+ as_name: string;+ as_domain: string;+ continent: string;+ continent_name: string;+ }): void {+ const stmt = this.db.prepare(`+ INSERT INTO geoip_cache (ip, country, country_name, city, asn, as_name, as_domain, continent, continent_name, queried_at)+ VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, CURRENT_TIMESTAMP)+ ON CONFLICT(ip) DO UPDATE SET+ country = ?,+ country_name = ?,+ city = ?,+ asn = ?,+ as_name = ?,+ as_domain = ?,+ continent = ?,+ continent_name = ?,+ queried_at = CURRENT_TIMESTAMP+ `);+ stmt.run(+ ip, geo.country, geo.country_name, geo.city, geo.asn, geo.as_name, geo.as_domain, geo.continent, geo.continent_name,+ geo.country, geo.country_name, geo.city, geo.asn, geo.as_name, geo.as_domain, geo.continent, geo.continent_name+ );+ }++ // Get summary stats for a specific backend+ getSummary(backendId: number): { totalConnections: number; totalUpload: number; totalDownload: number; uniqueDomains: number; uniqueIPs: number } {+ const connectionsStmt = this.db.prepare(`+ SELECT COUNT(*) as count FROM connection_logs WHERE backend_id = ?+ `);+ const totalConnections = (connectionsStmt.get(backendId) as { count: number }).count;++ const trafficStmt = this.db.prepare(`+ SELECT COALESCE(SUM(upload), 0) as upload, COALESCE(SUM(download), 0) as download+ FROM connection_logs WHERE backend_id = ?+ `);+ const { upload, download } = trafficStmt.get(backendId) as { upload: number; download: number };++ const domainsStmt = this.db.prepare(`+ SELECT COUNT(DISTINCT domain) as count FROM domain_stats WHERE backend_id = ?+ `);+ const uniqueDomains = (domainsStmt.get(backendId) as { count: number }).count;++ const ipsStmt = this.db.prepare(`+ SELECT COUNT(DISTINCT ip) as count FROM ip_stats WHERE backend_id = ?+ `);+ const uniqueIPs = (ipsStmt.get(backendId) as { count: number }).count;++ return {+ totalConnections,+ totalUpload: upload,+ totalDownload: download,+ uniqueDomains,+ uniqueIPs+ };+ }++ // Get recent connections for a specific backend+ getRecentConnections(backendId: number, limit = 100): Connection[] {+ const stmt = this.db.prepare(`+ SELECT id, domain, ip, chain, upload, download, timestamp+ FROM connection_logs+ WHERE backend_id = ?+ ORDER BY timestamp DESC+ LIMIT ?+ `);+ return stmt.all(backendId, limit) as Connection[];+ }++ // Clean old data for a specific backend (or all backends if backendId is null)+ // days=0 means clear all data (no time limit)+ cleanupOldData(backendId: number | null, days: number): { deletedConnections: number; deletedLogs: number; deletedDomains: number; deletedIPs: number; deletedProxies: number; deletedRules: number } {+ let deletedConnections = 0;+ let deletedLogs = 0;+ let deletedDomains = 0;+ let deletedIPs = 0;+ let deletedProxies = 0;+ let deletedRules = 0;++ if (backendId !== null) {+ // Clean specific backend+ if (days === 0) {+ // Clear all data for this backend+ const connectionsStmt = this.db.prepare(`DELETE FROM connection_logs WHERE backend_id = ?`);+ const result = connectionsStmt.run(backendId);+ deletedConnections = result.changes;+ deletedLogs = result.changes;++ // Clear stats tables+ const domainsStmt = this.db.prepare(`DELETE FROM domain_stats WHERE backend_id = ?`);+ deletedDomains = domainsStmt.run(backendId).changes;++ const ipsStmt = this.db.prepare(`DELETE FROM ip_stats WHERE backend_id = ?`);+ deletedIPs = ipsStmt.run(backendId).changes;++ const proxiesStmt = this.db.prepare(`DELETE FROM proxy_stats WHERE backend_id = ?`);+ deletedProxies = proxiesStmt.run(backendId).changes;++ const rulesStmt = this.db.prepare(`DELETE FROM rule_stats WHERE backend_id = ?`);+ deletedRules = rulesStmt.run(backendId).changes;+ } else {+ const cutoff = new Date(Date.now() - days * 24 * 60 * 60 * 1000).toISOString();+ const connectionsStmt = this.db.prepare(`DELETE FROM connection_logs WHERE backend_id = ? AND timestamp < ?`);+ const result = connectionsStmt.run(backendId, cutoff);+ deletedConnections = result.changes;+ deletedLogs = result.changes;+ // For partial cleanup, we keep the stats tables as they are aggregated data+ }+ } else {+ // Clean all backends+ if (days === 0) {+ // Clear all data+ const connectionsStmt = this.db.prepare(`DELETE FROM connection_logs`);+ const result = connectionsStmt.run();+ deletedConnections = result.changes;+ deletedLogs = result.changes;++ // Clear all stats tables+ const domainsStmt = this.db.prepare(`DELETE FROM domain_stats`);+ deletedDomains = domainsStmt.run().changes;++ const ipsStmt = this.db.prepare(`DELETE FROM ip_stats`);+ deletedIPs = ipsStmt.run().changes;++ const proxiesStmt = this.db.prepare(`DELETE FROM proxy_stats`);+ deletedProxies = proxiesStmt.run().changes;++ const rulesStmt = this.db.prepare(`DELETE FROM rule_stats`);+ deletedRules = rulesStmt.run().changes;+ } else {+ const cutoff = new Date(Date.now() - days * 24 * 60 * 60 * 1000).toISOString();+ const connectionsStmt = this.db.prepare(`DELETE FROM connection_logs WHERE timestamp < ?`);+ const result = connectionsStmt.run(cutoff);+ deletedConnections = result.changes;+ deletedLogs = result.changes;+ // For partial cleanup, we keep the stats tables as they are aggregated data+ }+ }++ // Vacuum database to reclaim space after clearing all data+ if (days === 0) {+ this.vacuum();+ }++ return { deletedConnections, deletedLogs, deletedDomains, deletedIPs, deletedProxies, deletedRules };+ }++ // Clean old ASN cache entries+ cleanupASNCache(days: number): number {+ const cutoff = new Date(Date.now() - days * 24 * 60 * 60 * 1000).toISOString();+ const stmt = this.db.prepare(`DELETE FROM asn_cache WHERE queried_at < ?`);+ const result = stmt.run(cutoff);+ return result.changes;+ }++ // Vacuum database to reclaim space+ vacuum(): void {+ this.db.exec('VACUUM');+ }++ // Get database file size in bytes+ getDatabaseSize(): number {+ try {+ const stats = fs.statSync(this.dbPath);+ return stats.size;+ } catch {+ return 0;+ }+ }++ // Get connection logs count for a specific backend+ getConnectionLogsCount(backendId: number): number {+ const stmt = this.db.prepare(`+ SELECT COUNT(*) as count FROM connection_logs WHERE backend_id = ?+ `);+ const result = stmt.get(backendId) as { count: number };+ return result.count;+ }++ // Get total connection logs count (all backends)+ getTotalConnectionLogsCount(): number {+ const stmt = this.db.prepare(`SELECT COUNT(*) as count FROM connection_logs`);+ const result = stmt.get() as { count: number };+ return result.count;+ }++ // Backend Management Methods++ // Create a new backend configuration+ createBackend(backend: { name: string; url: string; token?: string }): number {+ const stmt = this.db.prepare(`+ INSERT INTO backend_configs (name, url, token, enabled, is_active, listening)+ VALUES (?, ?, ?, 1, 0, 1)+ `);+ const result = stmt.run(backend.name, backend.url, backend.token || '');+ return Number(result.lastInsertRowid);+ }++ // Get all backend configurations+ getAllBackends(): BackendConfig[] {+ const stmt = this.db.prepare(`+ SELECT id, name, url, token, enabled, is_active, listening, created_at, updated_at+ FROM backend_configs+ ORDER BY created_at ASC+ `);+ return stmt.all() as BackendConfig[];+ }++ // Get a backend by ID+ getBackend(id: number): BackendConfig | undefined {+ const stmt = this.db.prepare(`+ SELECT id, name, url, token, enabled, is_active, listening, created_at, updated_at+ FROM backend_configs+ WHERE id = ?+ `);+ return stmt.get(id) as BackendConfig | undefined;+ }++ // Get the currently active backend+ getActiveBackend(): BackendConfig | undefined {+ const stmt = this.db.prepare(`+ SELECT id, name, url, token, enabled, is_active, listening, created_at, updated_at+ FROM backend_configs+ WHERE is_active = 1+ LIMIT 1+ `);+ return stmt.get() as BackendConfig | undefined;+ }++ // Get all backends that should be listening (collecting data)+ getListeningBackends(): BackendConfig[] {+ const stmt = this.db.prepare(`+ SELECT id, name, url, token, enabled, is_active, listening, created_at, updated_at+ FROM backend_configs+ WHERE listening = 1 AND enabled = 1+ `);+ return stmt.all() as BackendConfig[];+ }++ // Update a backend configuration+ updateBackend(id: number, updates: Partial<Omit<BackendConfig, 'id' | 'created_at'>>): void {+ const sets: string[] = [];+ const values: (string | number | boolean)[] = [];++ if (updates.name !== undefined) {+ sets.push('name = ?');+ values.push(updates.name);+ }+ if (updates.url !== undefined) {+ sets.push('url = ?');+ values.push(updates.url);+ }+ if (updates.token !== undefined) {+ sets.push('token = ?');+ values.push(updates.token);+ }+ if (updates.enabled !== undefined) {+ sets.push('enabled = ?');+ values.push(updates.enabled ? 1 : 0);+ }+ if (updates.listening !== undefined) {+ sets.push('listening = ?');+ values.push(updates.listening ? 1 : 0);+ }+ if (updates.is_active !== undefined) {+ sets.push('is_active = ?');+ values.push(updates.is_active ? 1 : 0);+ }++ if (sets.length === 0) return;++ sets.push('updated_at = CURRENT_TIMESTAMP');+ values.push(id);++ const stmt = this.db.prepare(`+ UPDATE backend_configs+ SET ${sets.join(', ')}+ WHERE id = ?+ `);+ stmt.run(...values);+ }++ // Set a backend as active (for display) - unsets all others+ setActiveBackend(id: number): void {+ this.db.exec('BEGIN TRANSACTION');+ try {+ // Unset all backends as active+ this.db.prepare(`UPDATE backend_configs SET is_active = 0`).run();+ // Set the specified backend as active+ this.db.prepare(`UPDATE backend_configs SET is_active = 1, updated_at = CURRENT_TIMESTAMP WHERE id = ?`).run(id);+ this.db.exec('COMMIT');+ } catch (error) {+ this.db.exec('ROLLBACK');+ throw error;+ }+ }++ // Set listening state for a backend (controls data collection)+ setBackendListening(id: number, listening: boolean): void {+ const stmt = this.db.prepare(`+ UPDATE backend_configs+ SET listening = ?, updated_at = CURRENT_TIMESTAMP+ WHERE id = ?+ `);+ stmt.run(listening ? 1 : 0, id);+ }++ // Delete a backend and all its associated data+ deleteBackend(id: number): void {+ // Due to ON DELETE CASCADE, all associated stats will be deleted automatically+ const stmt = this.db.prepare(`DELETE FROM backend_configs WHERE id = ?`);+ stmt.run(id);+ }++ // Delete all data for a specific backend+ deleteBackendData(id: number): void {+ this.db.exec('BEGIN TRANSACTION');+ try {+ this.db.prepare(`DELETE FROM domain_stats WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM ip_stats WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM proxy_stats WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM rule_stats WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM rule_proxy_map WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM country_stats WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM hourly_stats WHERE backend_id = ?`).run(id);+ this.db.prepare(`DELETE FROM connection_logs WHERE backend_id = ?`).run(id);+ this.db.exec('COMMIT');+ } catch (error) {+ this.db.exec('ROLLBACK');+ throw error;+ }+ }++ // Get total stats across all backends+ getGlobalSummary(): { totalConnections: number; totalUpload: number; totalDownload: number; uniqueDomains: number; uniqueIPs: number; backendCount: number } {+ const connectionsStmt = this.db.prepare(`+ SELECT COUNT(*) as count FROM connection_logs+ `);+ const totalConnections = (connectionsStmt.get() as { count: number }).count;++ const trafficStmt = this.db.prepare(`+ SELECT COALESCE(SUM(upload), 0) as upload, COALESCE(SUM(download), 0) as download+ FROM connection_logs+ `);+ const { upload, download } = trafficStmt.get() as { upload: number; download: number };++ const domainsStmt = this.db.prepare(`+ SELECT COUNT(DISTINCT domain) as count FROM domain_stats+ `);+ const uniqueDomains = (domainsStmt.get() as { count: number }).count;++ const ipsStmt = this.db.prepare(`+ SELECT COUNT(DISTINCT ip) as count FROM ip_stats+ `);+ const uniqueIPs = (ipsStmt.get() as { count: number }).count;++ const backendStmt = this.db.prepare(`+ SELECT COUNT(*) as count FROM backend_configs+ `);+ const backendCount = (backendStmt.get() as { count: number }).count;++ return {+ totalConnections,+ totalUpload: upload,+ totalDownload: download,+ uniqueDomains,+ uniqueIPs,+ backendCount+ };+ }++ close() {+ this.db.close();+ }+}++export default StatsDatabase;diff --git a/apps/collector/src/geo-service.ts b/apps/collector/src/geo-service.tsnew file mode 100644index 0000000..7648f1c--- /dev/null+++ b/apps/collector/src/geo-service.ts@@ -0,0 +1,226 @@+import type { StatsDatabase } from "./db.js";++export interface GeoLocation {+ country: string;+ country_name: string;+ city: string;+ asn: string;+ as_name: string;+ as_domain: string;+ continent: string;+ continent_name: string;+}++export class GeoIPService {+ private db: StatsDatabase;+ private pendingQueries: Map<string, Promise<GeoLocation | null>> = new Map();+ private lastRequestTime: number = 0;+ private minRequestInterval: number = 100; // Minimum 100ms between requests+ private queue: {+ ip: string;+ resolve: (value: GeoLocation | null) => void;+ }[] = [];+ private isProcessing: boolean = false;++ constructor(db: StatsDatabase) {+ this.db = db;+ this.startQueueProcessor();+ }++ // Get geolocation for an IP (with caching)+ async getGeoLocation(ip: string): Promise<GeoLocation | null> {+ // Skip private/local IPs+ if (this.isPrivateIP(ip)) {+ return {+ country: "LOCAL",+ country_name: "Local Network",+ city: "",+ asn: "",+ as_name: "Local Network",+ as_domain: "",+ continent: "LOCAL",+ continent_name: "Local Network",+ };+ }++ // Check cache first+ const cached = this.db.getIPGeolocation(ip);+ if (cached) {+ return {+ country: cached.country,+ country_name: cached.country_name,+ city: cached.city,+ asn: cached.asn,+ as_name: cached.as_name,+ as_domain: cached.as_domain,+ continent: cached.continent,+ continent_name: cached.continent_name,+ };+ }++ // Check if there's already a pending query for this IP+ const pending = this.pendingQueries.get(ip);+ if (pending) {+ return pending;+ }++ // Create new query promise+ const promise = this.queryWithQueue(ip);+ this.pendingQueries.set(ip, promise);++ try {+ const result = await promise;+ return result;+ } finally {+ this.pendingQueries.delete(ip);+ }+ }++ // Queue-based query to respect rate limits+ private async queryWithQueue(ip: string): Promise<GeoLocation | null> {+ return new Promise((resolve) => {+ this.queue.push({ ip, resolve });+ });+ }++ // Process queue with rate limiting+ private startQueueProcessor() {+ const processQueue = async () => {+ if (this.isProcessing || this.queue.length === 0) {+ setTimeout(processQueue, 100);+ return;+ }++ this.isProcessing = true;+ const item = this.queue.shift();++ if (item) {+ try {+ // Respect rate limit+ const now = Date.now();+ const timeSinceLastRequest = now - this.lastRequestTime;+ if (timeSinceLastRequest < this.minRequestInterval) {+ await this.sleep(this.minRequestInterval - timeSinceLastRequest);+ }++ const result = await this.queryAPI(item.ip);+ this.lastRequestTime = Date.now();+ item.resolve(result);+ } catch (err) {+ console.error(`[GeoIP] Error querying ${item.ip}:`, err);+ item.resolve(null);+ }+ }++ this.isProcessing = false;+ setTimeout(processQueue, 100);+ };++ processQueue();+ }++ // Query the API+ private async queryAPI(ip: string): Promise<GeoLocation | null> {+ try {+ console.log(`[GeoIP] Querying API for: ${ip}`);++ const controller = new AbortController();+ const timeout = setTimeout(() => controller.abort(), 5000);++ const response = await fetch(+ `https://api.ipinfo.es/ipinfo?ip=${ip}&meituan=false`,+ {+ signal: controller.signal,+ headers: {+ Accept: "application/json",+ },+ },+ );++ clearTimeout(timeout);++ if (!response.ok) {+ console.error(`[GeoIP] API error for ${ip}: ${response.status}`);+ return null;+ }++ const data = (await response.json()) as {+ country?: string;+ country_name?: string;+ city?: string;+ asn?: string;+ as_name?: string;+ as_domain?: string;+ continent?: string;+ continent_name?: string;+ };++ const geo: GeoLocation = {+ country: data.country || "Unknown",+ country_name: data.country_name || "Unknown",+ city: data.city || "",+ asn: data.asn || "",+ as_name: data.as_name || "",+ as_domain: data.as_domain || "",+ continent: data.continent || "Unknown",+ continent_name: data.continent_name || "Unknown",+ };++ // Save to cache+ this.db.saveIPGeolocation(ip, geo);+ console.log(`[GeoIP] Cached: ${ip} -> ${geo.country_name}`);++ return geo;+ } catch (err) {+ console.error(`[GeoIP] Failed to query ${ip}:`, err);+ return null;+ }+ }++ // Check if IP is private/local+ private isPrivateIP(ip: string): boolean {+ // IPv4 private ranges+ const privateRanges = [+ /^10\./,+ /^172\.(1[6-9]|2[0-9]|3[01])\./,+ /^192\.168\./,+ /^127\./,+ /^0\./,+ /^255\./,+ /^100\.(6[4-9]|[7-9][0-9]|1[0-1][0-9]|12[0-7])\./, // CGNAT+ ];++ // IPv6 private+ if (ip.includes(":")) {+ return (+ ip.startsWith("fc") ||+ ip.startsWith("fd") ||+ ip.startsWith("fe80") ||+ ip.startsWith("::1") ||+ ip === "::1"+ );+ }++ return privateRanges.some((range) => range.test(ip));+ }++ private sleep(ms: number): Promise<void> {+ return new Promise((resolve) => setTimeout(resolve, ms));+ }++ // Bulk query IPs (for backfill)+ async bulkQueryIPs(ips: string[]): Promise<void> {+ const uniqueIPs = [...new Set(ips)].filter((ip) => !this.isPrivateIP(ip));+ console.log(`[GeoIP] Bulk querying ${uniqueIPs.length} IPs`);++ for (const ip of uniqueIPs) {+ // Check if already cached+ const cached = this.db.getIPGeolocation(ip);+ if (!cached) {+ await this.getGeoLocation(ip);+ // Small delay to respect rate limits+ await this.sleep(150);+ }+ }+ }+}diff --git a/apps/collector/src/index.ts b/apps/collector/src/index.tsnew file mode 100644index 0000000..95c0a87--- /dev/null+++ b/apps/collector/src/index.ts@@ -0,0 +1,178 @@+import { config } from 'dotenv';+config();++import { StatsDatabase, BackendConfig } from './db.js';+import { createCollector, OpenClashCollector } from './collector.js';+import { StatsWebSocketServer } from './websocket.js';++let wsServer: StatsWebSocketServer;++import { APIServer } from './api.js';+import { GeoIPService } from './geo-service.js';+import path from 'path';++const COLLECTOR_WS_PORT = parseInt(process.env.COLLECTOR_WS_PORT || '3002');+const API_PORT = parseInt(process.env.API_PORT || '3001');+const DB_PATH = process.env.DB_PATH || path.join(process.cwd(), 'stats.db');++// Map of backend connections: backendId -> OpenClashCollector+const collectors = new Map<number, OpenClashCollector>();+let db: StatsDatabase;++let apiServer: APIServer;+let geoService: GeoIPService;++// Track last known backend configs to detect changes+let lastBackendConfigs: Map<number, BackendConfig> = new Map();++async function main() {+ console.log('[Main] Starting collector service...');++ // Initialize database+ console.log('[Main] Initializing database at:', DB_PATH);+ db = new StatsDatabase(DB_PATH);++ // Initialize GeoIP service+ geoService = new GeoIPService(db);++ // Initialize WebSocket server for real-time updates+ console.log('[Main] Starting WebSocket server on port', COLLECTOR_WS_PORT);+ wsServer = new StatsWebSocketServer(COLLECTOR_WS_PORT, db);+ wsServer.start();++ // Initialize API server+ console.log('[Main] Starting API server on port', API_PORT);+ apiServer = new APIServer(API_PORT, db);+ apiServer.start();++ // Start backend management loop+ console.log('[Main] Starting backend management loop...');+ manageBackends();++ // Check for backend config changes every 5 seconds+ setInterval(manageBackends, 5000);++ // Handle graceful shutdown+ process.on('SIGINT', shutdown);+ process.on('SIGTERM', shutdown);+}++// Manage backend connections based on database configuration+async function manageBackends() {+ try {+ // Get current backend configs from database+ const backends = db.getAllBackends();+ const currentConfigs = new Map(backends.map(b => [b.id, b]));++ // Find backends that need to be started (listening=true but not connected)+ for (const backend of backends) {+ const existingCollector = collectors.get(backend.id);+ const lastConfig = lastBackendConfigs.get(backend.id);++ // Check if we need to start or restart this backend connection+ const needsStart = backend.listening && backend.enabled && !existingCollector;+ const needsRestart = existingCollector && lastConfig && (+ lastConfig.url !== backend.url ||+ lastConfig.token !== backend.token ||+ lastConfig.listening !== backend.listening ||+ lastConfig.enabled !== backend.enabled+ );++ if (needsRestart) {+ console.log(`[Backends] Restarting collector for backend "${backend.name}" (ID: ${backend.id}) due to config change`);+ stopCollector(backend.id);+ }++ if (needsStart || needsRestart) {+ if (backend.listening && backend.enabled) {+ startCollector(backend);+ }+ }++ // Stop collectors for backends that are no longer listening or disabled+ if (existingCollector && (!backend.listening || !backend.enabled)) {+ console.log(`[Backends] Stopping collector for backend "${backend.name}" (ID: ${backend.id}) - listening=${backend.listening}, enabled=${backend.enabled}`);+ stopCollector(backend.id);+ }+ }++ // Stop collectors for deleted backends+ for (const [id, collector] of collectors) {+ if (!currentConfigs.has(id)) {+ console.log(`[Backends] Stopping collector for deleted backend (ID: ${id})`);+ stopCollector(id);+ }+ }++ // Update last known configs+ lastBackendConfigs = currentConfigs;+ } catch (error) {+ console.error('[Backends] Error managing backends:', error);+ }+}++// Start a collector for a specific backend+function startCollector(backend: BackendConfig) {+ if (collectors.has(backend.id)) {+ console.log(`[Collector] Backend "${backend.name}" (ID: ${backend.id}) already has a collector running`);+ return;+ }++ console.log(`[Collector] Starting collector for backend "${backend.name}" (ID: ${backend.id}) at ${backend.url}`);++ // Convert HTTP URL to WebSocket URL+ let wsUrl = backend.url.replace(/^http:\/\//, 'ws://').replace(/^https:\/\//, 'wss://');+ if (!wsUrl.endsWith('/connections')) {+ wsUrl = `${wsUrl}/connections`;+ }++ // Create and start collector+ const collector = createCollector(+ db,+ wsUrl,+ backend.token || undefined,+ geoService,+ () => {+ // Broadcast stats update via WebSocket when new data arrives+ wsServer.broadcastStats();+ },+ backend.id // Pass backend ID for data isolation+ );++ collectors.set(backend.id, collector);+ collector.connect();+}++// Stop a collector for a specific backend+function stopCollector(backendId: number) {+ const collector = collectors.get(backendId);+ if (collector) {+ console.log(`[Collector] Stopping collector for backend ID: ${backendId}`);+ collector.disconnect();+ collectors.delete(backendId);+ }+}++// Graceful shutdown+function shutdown() {+ console.log('[Main] Shutting down...');++ // Stop all collectors+ for (const [id, collector] of collectors) {+ console.log(`[Main] Disconnecting collector for backend ID: ${id}`);+ collector.disconnect();+ }+ collectors.clear();++ // Stop servers+ wsServer?.stop();+ apiServer?.stop();++ // Close database+ db?.close();++ console.log('[Main] Shutdown complete');+ process.exit(0);+}++main().catch(console.error);diff --git a/apps/collector/src/websocket.ts b/apps/collector/src/websocket.tsnew file mode 100644index 0000000..a00280c--- /dev/null+++ b/apps/collector/src/websocket.ts@@ -0,0 +1,202 @@+import { WebSocketServer as WSServer, WebSocket } from 'ws';+import type { StatsSummary } from '@clashstats/shared';+import type { StatsDatabase } from './db.js';++export interface WebSocketMessage {+ type: 'stats' | 'ping' | 'pong' | 'subscribe';+ backendId?: number;+ data?: StatsSummary;+ timestamp: string;+}++interface ClientInfo {+ ws: WebSocket;+ backendId: number | null; // null means use active backend+}++export class StatsWebSocketServer {+ private wss: WSServer | null = null;+ private db: StatsDatabase;+ private clients: Map<WebSocket, ClientInfo> = new Map();+ private port: number;+ private lastBroadcastTime: number = 0;+ private broadcastThrottleMs: number = 1000; // Minimum time between broadcasts++ constructor(port: number, db: StatsDatabase) {+ this.port = port;+ this.db = db;+ }++ start() {+ this.wss = new WSServer({+ port: this.port,+ host: '0.0.0.0',+ perMessageDeflate: false,+ });++ this.wss.on('connection', (ws: WebSocket, req) => {+ console.log(`[WebSocket] Connection from ${req.socket.remoteAddress}`);+ console.log(`[WebSocket] Client connected, total: ${this.clients.size + 1}`);++ // Store client with default to active backend+ const clientInfo: ClientInfo = { ws, backendId: null };+ this.clients.set(ws, clientInfo);++ // Send initial stats+ this.sendStatsToClient(ws);++ // Handle messages+ ws.on('message', (data) => {+ try {+ const msg = JSON.parse(data.toString()) as WebSocketMessage;++ if (msg.type === 'ping') {+ ws.send(JSON.stringify({ type: 'pong', timestamp: new Date().toISOString() }));+ } else if (msg.type === 'subscribe' && msg.backendId !== undefined) {+ // Client wants to subscribe to a specific backend+ const backend = this.db.getBackend(msg.backendId);+ if (backend) {+ clientInfo.backendId = msg.backendId;+ console.log(`[WebSocket] Client subscribed to backend: ${backend.name} (ID: ${msg.backendId})`);+ // Send immediate update+ this.sendStatsToClient(ws);+ } else {+ console.warn(`[WebSocket] Client tried to subscribe to non-existent backend: ${msg.backendId}`);+ }+ }+ } catch (err) {+ // Ignore invalid messages+ }+ });++ ws.on('close', () => {+ this.clients.delete(ws);+ console.log(`[WebSocket] Client disconnected, remaining: ${this.clients.size}`);+ });++ ws.on('error', (err) => {+ console.error('[WebSocket] Client error:', err.message);+ this.clients.delete(ws);+ });+ });++ console.log(`[WebSocket] Server running at ws://0.0.0.0:${this.port}`);+ }++ private getStatsForBackend(backendId: number | null): StatsSummary | null {+ // If no backendId specified, use the active backend+ if (backendId === null) {+ const activeBackend = this.db.getActiveBackend();+ if (!activeBackend) {+ return null;+ }+ backendId = activeBackend.id;+ }++ const backend = this.db.getBackend(backendId);+ if (!backend) {+ return null;+ }++ const summary = this.db.getSummary(backendId);+ const topDomains = this.db.getTopDomains(backendId, 100);+ const topIPs = this.db.getTopIPs(backendId, 100);+ const proxyStats = this.db.getProxyStats(backendId);+ const ruleStats = this.db.getRuleStats(backendId);+ const hourly = this.db.getHourlyStats(backendId, 24);++ return {+ totalUpload: summary.totalUpload,+ totalDownload: summary.totalDownload,+ totalConnections: summary.totalConnections,+ totalDomains: summary.uniqueDomains,+ totalIPs: summary.uniqueIPs,+ totalProxies: proxyStats.length,+ topDomains,+ topIPs,+ proxyStats,+ ruleStats,+ hourlyStats: hourly+ };+ }++ private async sendStatsToClient(ws: WebSocket) {+ if (ws.readyState !== WebSocket.OPEN) return;++ const clientInfo = this.clients.get(ws);+ if (!clientInfo) return;++ try {+ const stats = this.getStatsForBackend(clientInfo.backendId);+ if (!stats) {+ ws.send(JSON.stringify({+ type: 'stats',+ error: 'No backend available',+ timestamp: new Date().toISOString()+ }));+ return;+ }++ const message: WebSocketMessage = {+ type: 'stats',+ data: stats,+ timestamp: new Date().toISOString()+ };+ ws.send(JSON.stringify(message));+ } catch (err) {+ console.error('[WebSocket] Error sending stats:', err);+ }+ }++ // Broadcast stats to all connected clients+ async broadcastStats(force = false) {+ const now = Date.now();++ // Throttle broadcasts to prevent overwhelming clients+ if (!force && now - this.lastBroadcastTime < this.broadcastThrottleMs) {+ return;+ }++ this.lastBroadcastTime = now;++ if (this.clients.size === 0) return;++ try {+ let sentCount = 0;++ // Send stats to each client based on their subscribed backend+ for (const [ws, clientInfo] of this.clients) {+ if (ws.readyState === WebSocket.OPEN) {+ const stats = this.getStatsForBackend(clientInfo.backendId);+ if (stats) {+ const message: WebSocketMessage = {+ type: 'stats',+ data: stats,+ timestamp: new Date().toISOString()+ };+ ws.send(JSON.stringify(message));+ sentCount++;+ }+ }+ }++ if (sentCount > 0) {+ console.log(`[WebSocket] Broadcasted stats to ${sentCount} clients`);+ }+ } catch (err) {+ console.error('[WebSocket] Error broadcasting stats:', err);+ }+ }++ // Get number of connected clients+ getClientCount(): number {+ return this.clients.size;+ }++ stop() {+ this.clients.forEach((info) => info.ws.close());+ this.clients.clear();+ this.wss?.close();+ console.log('[WebSocket] Server stopped');+ }+}diff --git a/apps/collector/tsconfig.json b/apps/collector/tsconfig.jsonnew file mode 100644index 0000000..50f44ac--- /dev/null+++ b/apps/collector/tsconfig.json@@ -0,0 +1,17 @@+{+ "compilerOptions": {+ "target": "ES2022",+ "module": "NodeNext",+ "moduleResolution": "NodeNext",+ "lib": ["ES2022"],+ "outDir": "./dist",+ "rootDir": "./src",+ "strict": true,+ "esModuleInterop": true,+ "skipLibCheck": true,+ "forceConsistentCasingInFileNames": true,+ "resolveJsonModule": true+ },+ "include": ["src/**/*"],+ "exclude": ["node_modules", "dist"]+}diff --git a/apps/web/.gitignore b/apps/web/.gitignorenew file mode 100644index 0000000..5ef6a52--- /dev/null+++ b/apps/web/.gitignore@@ -0,0 +1,41 @@+# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.++# dependencies+/node_modules+/.pnp+.pnp.*+.yarn/*+!.yarn/patches+!.yarn/plugins+!.yarn/releases+!.yarn/versions++# testing+/coverage++# next.js+/.next/+/out/++# production+/build++# misc+.DS_Store+*.pem++# debug+npm-debug.log*+yarn-debug.log*+yarn-error.log*+.pnpm-debug.log*++# env files (can opt-in for committing if needed)+.env*++# vercel+.vercel++# typescript+*.tsbuildinfo+next-env.d.tsdiff --git a/apps/web/README.md b/apps/web/README.mdnew file mode 100644index 0000000..e215bc4--- /dev/null+++ b/apps/web/README.md@@ -0,0 +1,36 @@+This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).++## Getting Started++First, run the development server:++```bash+npm run dev+# or+yarn dev+# or+pnpm dev+# or+bun dev+```++Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.++You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.++This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.++## Learn More++To learn more about Next.js, take a look at the following resources:++- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.+- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.++You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!++## Deploy on Vercel++The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.++Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.diff --git a/apps/web/app/[locale]/layout.tsx b/apps/web/app/[locale]/layout.tsxnew file mode 100644index 0000000..3bcf9eb--- /dev/null+++ b/apps/web/app/[locale]/layout.tsx@@ -0,0 +1,55 @@+import type { Metadata } from "next";+import { Geist, Geist_Mono } from "next/font/google";+import "../globals.css";+import { ThemeProvider } from "@/components/providers/theme-provider";+import { NextIntlClientProvider } from "next-intl";+import { getMessages } from "next-intl/server";+import { notFound } from "next/navigation";+import { routing } from "@/i18n/routing";++const geistSans = Geist({+ variable: "--font-geist-sans",+ subsets: ["latin"],+});++const geistMono = Geist_Mono({+ variable: "--font-geist-mono",+ subsets: ["latin"],+});++export const metadata: Metadata = {+ title: "Clash Stats",+ description: "Clash connection statistics dashboard",+ icons: {+ icon: "/clash-master.png",+ shortcut: "/clash-master.png",+ apple: "/clash-master.png",+ },+};++export default async function RootLayout({+ children,+ params,+}: {+ children: React.ReactNode;+ params: Promise<{ locale: string }>;+}) {+ const { locale } = await params;+ if (!routing.locales.includes(locale as any)) notFound();++ const messages = await getMessages();++ return (+ <html lang={locale} suppressHydrationWarning>+ <body+ className={`${geistSans.variable} ${geistMono.variable} antialiased`}+ >+ <ThemeProvider attribute="class" defaultTheme="dark" enableSystem>+ <NextIntlClientProvider messages={messages}>+ {children}+ </NextIntlClientProvider>+ </ThemeProvider>+ </body>+ </html>+ );+}diff --git a/apps/web/app/[locale]/page.tsx b/apps/web/app/[locale]/page.tsxnew file mode 100644index 0000000..da07ab9--- /dev/null+++ b/apps/web/app/[locale]/page.tsx@@ -0,0 +1,465 @@+"use client";++import { useEffect, useState, useCallback, useRef, memo } from "react";+import { useTranslations } from "next-intl";+import { Globe, MapPin, Server, Route, Network, Activity, RefreshCw, Radio, ChevronDown, Pause } from "lucide-react";+import { Navigation } from "@/components/navigation";+import { StatsCards } from "@/components/stats-cards";+import { OverviewTab } from "@/components/overview";+import { TopDomainsChart } from "@/components/top-domains-chart";+import { ProxyStatsChart } from "@/components/proxy-stats-chart";+import { RuleChainChart } from "@/components/rule-chain-chart";+import { WorldTrafficMap } from "@/components/world-traffic-map";+import { CountryTrafficList } from "@/components/country-traffic-list";+import { DomainsTable } from "@/components/domains-table";+import { IPsTable } from "@/components/ips-table";+import { BackendConfigDialog } from "@/components/backend-config-dialog";+import { ThemeToggle } from "@/components/theme-toggle";+import { LanguageSwitcher } from "@/components/language-switcher";+import { Button } from "@/components/ui/button";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs";+import { Badge } from "@/components/ui/badge";+import {+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuItem,+ DropdownMenuLabel,+ DropdownMenuSeparator,+ DropdownMenuTrigger,+} from "@/components/ui/dropdown-menu";+import { Switch } from "@/components/ui/switch";+import { api, getPresetTimeRange, type TimeRange, type Backend } from "@/lib/api";+import { cn } from "@/lib/utils";+import type { StatsSummary, CountryStats } from "@clashstats/shared";++function formatTimeAgo(date: Date, t: any): string {+ const now = new Date();+ const diff = now.getTime() - date.getTime();+ const seconds = Math.floor(diff / 1000);+ if (seconds < 5) return t("justNow");+ if (seconds < 60) return t("secondsAgo", { seconds });+ const minutes = Math.floor(seconds / 60);+ if (minutes < 60) return t("minutesAgo", { minutes });+ const hours = Math.floor(minutes / 60);+ if (hours < 24) return t("hoursAgo", { hours });+ return t("daysAgo", { days: Math.floor(hours / 24) });+}++const NAV_ITEMS = [+ { id: "overview", label: "overview" },+ { id: "domains", label: "domains" },+ { id: "countries", label: "countries" },+ { id: "proxies", label: "proxies" },+ { id: "rules", label: "rules" },+ { id: "network", label: "network" },+];++// Memoized tab content components to prevent unnecessary re-renders+const OverviewContent = memo(function OverviewContent({+ data,+ countryData,+ error,+ activeBackendId,+}: {+ data: StatsSummary | null;+ countryData: CountryStats[];+ error: string | null;+ activeBackendId?: number;+}) {+ return (+ <div className="space-y-6">+ <StatsCards data={data} error={error} />+ <OverviewTab+ domains={data?.topDomains || []}+ proxies={data?.proxyStats || []}+ countries={countryData}+ activeBackendId={activeBackendId}+ />+ </div>+ );+});++const DomainsContent = memo(function DomainsContent({+ data,+}: {+ data: StatsSummary | null;+}) {+ const t = useTranslations("domains");+ return (+ <div className="space-y-6">+ <TopDomainsChart data={data?.topDomains || []} />+ <Tabs defaultValue="domains" className="w-full">+ <TabsList className="glass">+ <TabsTrigger value="domains">{t("domainList")}</TabsTrigger>+ <TabsTrigger value="ips">{t("ipList")}</TabsTrigger>+ </TabsList>+ <TabsContent value="domains">+ <DomainsTable data={data?.topDomains || []} />+ </TabsContent>+ <TabsContent value="ips">+ <IPsTable data={data?.topIPs || []} />+ </TabsContent>+ </Tabs>+ </div>+ );+});++const CountriesContent = memo(function CountriesContent({+ countryData,+}: {+ countryData: CountryStats[];+}) {+ const t = useTranslations("countries");+ return (+ <div className="space-y-6">+ <WorldTrafficMap data={countryData} />+ <Card>+ <CardHeader>+ <CardTitle className="text-lg font-semibold">{t("details")}</CardTitle>+ </CardHeader>+ <CardContent>+ <CountryTrafficList data={countryData} />+ </CardContent>+ </Card>+ </div>+ );+});++const ProxiesContent = memo(function ProxiesContent({+ data,+}: {+ data: StatsSummary | null;+}) {+ return (+ <div className="space-y-6">+ <ProxyStatsChart data={data?.proxyStats || []} />+ </div>+ );+});++const RulesContent = memo(function RulesContent({+ data,+}: {+ data: StatsSummary | null;+}) {+ return (+ <div className="space-y-6">+ <RuleChainChart data={data?.ruleStats || []} />+ </div>+ );+});++const NetworkContent = memo(function NetworkContent() {+ const t = useTranslations("network");+ return (+ <div className="space-y-6">+ <div className="p-12 text-center text-muted-foreground border rounded-xl">+ <Activity className="w-12 h-12 mx-auto mb-4 opacity-50" />+ <p>{t("comingSoon")}</p>+ </div>+ </div>+ );+});++export default function DashboardPage() {+ const t = useTranslations("nav");+ const dashboardT = useTranslations("dashboard");+ const backendT = useTranslations("backend");+ const [activeTab, setActiveTab] = useState("overview");+ const [data, setData] = useState<StatsSummary | null>(null);+ const [countryData, setCountryData] = useState<CountryStats[]>([]);+ const [error, setError] = useState<string | null>(null);+ const [timeRange] = useState<TimeRange>(getPresetTimeRange("24h"));+ const [lastUpdated, setLastUpdated] = useState<Date>(new Date());+ const [isLoading, setIsLoading] = useState(false);+ const [autoRefresh, setAutoRefresh] = useState(true);+ const [showBackendDialog, setShowBackendDialog] = useState(false);+ const [isFirstTime, setIsFirstTime] = useState(false);+ const [backends, setBackends] = useState<Backend[]>([]);+ const [activeBackend, setActiveBackend] = useState<Backend | null>(null);+ const [listeningBackends, setListeningBackends] = useState<Backend[]>([]);+ const initialLoaded = useRef(false);+ const lastDataRef = useRef<string>("");++ // Check if backend is configured+ const checkBackend = useCallback(async () => {+ try {+ const backendsData = await api.getBackends();+ setBackends(backendsData);++ if (backendsData.length === 0) {+ setIsFirstTime(true);+ setShowBackendDialog(true);+ } else {+ // Find active backend+ const active = backendsData.find(b => b.is_active) || backendsData[0];+ setActiveBackend(active);++ // Find listening backends+ const listening = backendsData.filter(b => b.listening);+ setListeningBackends(listening);+ }+ } catch (err) {+ console.error("Failed to check backends:", err);+ }+ }, []);++ // Load stats with deduplication+ const loadStats = useCallback(async (showLoading = false) => {+ if (showLoading) setIsLoading(true);++ try {+ // Get active backend ID if available+ const activeBackendData = await api.getActiveBackend();++ // If no active backend, skip stats loading+ if ('error' in activeBackendData) {+ setData(null);+ setCountryData([]);+ setError(null);+ return;+ }++ const backendId = activeBackendData.id;++ const [stats, countries] = await Promise.all([+ api.getSummary(backendId, timeRange),+ api.getCountries(backendId, 50, timeRange),+ ]);++ // Check if data actually changed by comparing JSON+ const newDataJson = JSON.stringify({+ totalDownload: stats?.totalDownload,+ totalUpload: stats?.totalUpload,+ totalDomains: stats?.totalDomains,+ });++ if (newDataJson !== lastDataRef.current) {+ lastDataRef.current = newDataJson;+ setData(stats);+ setCountryData(countries);+ setLastUpdated(new Date());+ }+ setError(null);+ } catch (err) {+ setError(err instanceof Error ? err.message : "Unknown error");+ } finally {+ if (showLoading) setIsLoading(false);+ }+ }, [timeRange]);++ // Switch active backend+ const handleSwitchBackend = async (backendId: number) => {+ try {+ await api.setActiveBackend(backendId);+ await checkBackend();+ await loadStats(true);+ } catch (err) {+ console.error("Failed to switch backend:", err);+ }+ };++ // Handle backend configuration changes+ const handleBackendChange = useCallback(() => {+ checkBackend();+ loadStats(true);+ }, [checkBackend, loadStats]);++ // Initial load+ useEffect(() => {+ if (!initialLoaded.current) {+ checkBackend();+ loadStats(true);+ initialLoaded.current = true;+ }+ }, [loadStats, checkBackend]);++ // Background polling - every 5 seconds without loading state (only when autoRefresh is on)+ useEffect(() => {+ if (!autoRefresh) return;++ const interval = setInterval(() => {+ loadStats(false);+ }, 5000);+ return () => clearInterval(interval);+ }, [loadStats, autoRefresh]);++ const renderContent = () => {+ switch (activeTab) {+ case "overview":+ return (+ <OverviewContent+ data={data}+ countryData={countryData}+ error={error}+ activeBackendId={activeBackend?.id}+ />+ );+ case "domains":+ return <DomainsContent data={data} />;+ case "countries":+ return <CountriesContent countryData={countryData} />;+ case "proxies":+ return <ProxiesContent data={data} />;+ case "rules":+ return <RulesContent data={data} />;+ case "network":+ return <NetworkContent />;+ default:+ return (+ <OverviewContent+ data={data}+ countryData={countryData}+ error={error}+ activeBackendId={activeBackend?.id}+ />+ );+ }+ };++ return (+ <div className="flex min-h-screen bg-background">+ <Navigation activeTab={activeTab} onTabChange={setActiveTab} />++ <main className="flex-1 lg:ml-0">+ <header className="sticky top-0 z-40 lg:static border-b border-border/40 bg-background/80 backdrop-blur-md">+ <div className="flex items-center justify-between h-14 px-4 lg:px-6">+ <div className="flex items-center gap-3">+ <h2 className="font-semibold">+ {t(activeTab)}+ </h2>++ {/* Backend Selector */}+ {backends.length > 0 && (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button variant="ghost" size="sm" className="gap-1">+ <Server className="w-4 h-4" />+ <span className="max-w-[120px] truncate">+ {activeBackend?.name || backendT("selectBackend")}+ </span>+ <ChevronDown className="w-3 h-3" />+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="start" className="w-56">+ <DropdownMenuLabel>{backendT("backendsTab")}</DropdownMenuLabel>+ <DropdownMenuSeparator />+ {backends.map((backend) => (+ <DropdownMenuItem+ key={backend.id}+ onClick={() => handleSwitchBackend(backend.id)}+ className="flex items-center justify-between"+ >+ <span className={cn(+ "truncate",+ backend.is_active && "font-medium"+ )}>+ {backend.name}+ </span>+ <div className="flex items-center gap-1">+ {backend.is_active && (+ <Badge variant="default" className="text-[10px] h-5">+ {backendT("displaying")}+ </Badge>+ )}+ {backend.listening && !backend.is_active && (+ <Badge variant="secondary" className="text-[10px] h-5">+ <Radio className="w-2 h-2 mr-1" />+ {backendT("collecting")}+ </Badge>+ )}+ </div>+ </DropdownMenuItem>+ ))}+ <DropdownMenuSeparator />+ <DropdownMenuItem onClick={() => setShowBackendDialog(true)}>+ <Server className="w-4 h-4 mr-2" />+ {backendT("manageBackends")}+ </DropdownMenuItem>+ </DropdownMenuContent>+ </DropdownMenu>+ )}++ {/* Listening Indicators */}+ {listeningBackends.length > 0 && (+ <div className="hidden md:flex items-center gap-1">+ {listeningBackends.slice(0, 3).map((backend) => (+ <Badge+ key={backend.id}+ variant="outline"+ className="text-[10px] h-5 gap-1 border-green-500/30 text-green-600"+ >+ <Radio className="w-2 h-2" />+ {backend.name}+ </Badge>+ ))}+ {listeningBackends.length > 3 && (+ <Badge variant="outline" className="text-[10px] h-5">+ +{listeningBackends.length - 3}+ </Badge>+ )}+ </div>+ )}+ </div>++ <div className="flex items-center gap-2">+ {/* Auto refresh toggle */}+ <div className="hidden sm:flex items-center gap-2 mr-2">+ <Switch+ id="auto-refresh"+ checked={autoRefresh}+ onCheckedChange={setAutoRefresh}+ className="data-[state=checked]:bg-emerald-500"+ />+ <label+ htmlFor="auto-refresh"+ className="text-sm text-muted-foreground cursor-pointer select-none flex items-center gap-1.5"+ >+ {autoRefresh ? (+ <>+ <RefreshCw className="w-3.5 h-3.5 text-emerald-500" />+ <span className="text-emerald-600">{dashboardT("autoRefresh")}</span>+ </>+ ) : (+ <>+ <Pause className="w-3.5 h-3.5" />+ <span>{dashboardT("paused")}</span>+ </>+ )}+ </label>+ </div>+ <LanguageSwitcher />+ <ThemeToggle />+ <Button+ variant="outline"+ size="icon"+ onClick={() => loadStats(true)}+ disabled={isLoading}+ className="ml-1"+ >+ <RefreshCw className={cn("w-4 h-4", isLoading && "animate-spin")} />+ </Button>+ </div>+ </div>+ </header>++ <div className="p-4 lg:p-6 pb-24 lg:pb-6 max-w-7xl mx-auto">+ {renderContent()}+ </div>+ </main>++ {/* Backend Configuration Dialog */}+ <BackendConfigDialog+ open={showBackendDialog}+ onOpenChange={setShowBackendDialog}+ isFirstTime={isFirstTime}+ onConfigComplete={() => {+ setIsFirstTime(false);+ handleBackendChange();+ }}+ onBackendChange={handleBackendChange}+ />+ </div>+ );+}diff --git a/apps/web/app/globals.css b/apps/web/app/globals.cssnew file mode 100644index 0000000..4dacd87--- /dev/null+++ b/apps/web/app/globals.css@@ -0,0 +1,274 @@+@import "tailwindcss";++@custom-variant dark (&:is(.dark *));++@theme inline {+ --color-background: var(--background);+ --color-foreground: var(--foreground);+ --font-sans: var(--font-geist-sans);+ --font-mono: var(--font-geist-mono);+ --color-sidebar-ring: var(--sidebar-ring);+ --color-sidebar-border: var(--sidebar-border);+ --color-sidebar-accent-foreground: var(--sidebar-accent-foreground);+ --color-sidebar-accent: var(--sidebar-accent);+ --color-sidebar-primary-foreground: var(--sidebar-primary-foreground);+ --color-sidebar-primary: var(--sidebar-primary);+ --color-sidebar-foreground: var(--sidebar-foreground);+ --color-sidebar: var(--sidebar);+ --color-chart-5: var(--chart-5);+ --color-chart-4: var(--chart-4);+ --color-chart-3: var(--chart-3);+ --color-chart-2: var(--chart-2);+ --color-chart-1: var(--chart-1);+ --color-ring: var(--ring);+ --color-input: var(--input);+ --color-border: var(--border);+ --color-destructive: var(--destructive);+ --color-accent-foreground: var(--accent-foreground);+ --color-accent: var(--accent);+ --color-muted-foreground: var(--muted-foreground);+ --color-muted: var(--muted);+ --color-secondary-foreground: var(--secondary-foreground);+ --color-secondary: var(--secondary);+ --color-primary-foreground: var(--primary-foreground);+ --color-primary: var(--primary);+ --color-popover-foreground: var(--popover-foreground);+ --color-popover: var(--popover);+ --color-card-foreground: var(--card-foreground);+ --color-card: var(--card);+ --radius-sm: calc(var(--radius) - 4px);+ --radius-md: calc(var(--radius) - 2px);+ --radius-lg: var(--radius);+ --radius-xl: calc(var(--radius) + 4px);+ --radius-2xl: calc(var(--radius) + 8px);+ --radius-3xl: calc(var(--radius) + 12px);+ --radius-4xl: calc(var(--radius) + 16px);++ /* UniFi Style Colors */+ --color-unifi-blue: #0063FF;+ --color-unifi-purple: #7B61FF;+ --color-unifi-cyan: #00C7FF;+ --color-unifi-green: #00D084;+ --color-unifi-orange: #FF8C42;+ --color-unifi-pink: #FF6B9D;+}++:root {+ --radius: 0.75rem;+ /* Light Mode - Clean white background */+ --background: #F5F7FA;+ --foreground: #1A1D29;+ --card: #FFFFFF;+ --card-foreground: #1A1D29;+ --popover: #FFFFFF;+ --popover-foreground: #1A1D29;+ --primary: #0063FF;+ --primary-foreground: #FFFFFF;+ --secondary: #E8ECF2;+ --secondary-foreground: #1A1D29;+ --muted: #E8ECF2;+ --muted-foreground: #6B7280;+ --accent: #E8ECF2;+ --accent-foreground: #1A1D29;+ --destructive: #EF4444;+ --border: #E2E8F0;+ --input: #E2E8F0;+ --ring: #0063FF;+ --chart-1: #0063FF;+ --chart-2: #7B61FF;+ --chart-3: #00C7FF;+ --chart-4: #00D084;+ --chart-5: #FF8C42;+ --sidebar: #FFFFFF;+ --sidebar-foreground: #1A1D29;+ --sidebar-primary: #0063FF;+ --sidebar-primary-foreground: #FFFFFF;+ --sidebar-accent: #E8ECF2;+ --sidebar-accent-foreground: #1A1D29;+ --sidebar-border: #E2E8F0;+ --sidebar-ring: #0063FF;+}++.dark {+ /* Dark Mode - UniFi Dark Theme */+ --background: #0B0F19;+ --foreground: #F8FAFC;+ --card: rgba(23, 28, 43, 0.8);+ --card-foreground: #F8FAFC;+ --popover: #171C2B;+ --popover-foreground: #F8FAFC;+ --primary: #3B82F6;+ --primary-foreground: #FFFFFF;+ --secondary: rgba(59, 130, 246, 0.15);+ --secondary-foreground: #F8FAFC;+ --muted: #1E2538;+ --muted-foreground: #94A3B8;+ --accent: rgba(59, 130, 246, 0.15);+ --accent-foreground: #F8FAFC;+ --destructive: #EF4444;+ --border: rgba(255, 255, 255, 0.08);+ --input: rgba(255, 255, 255, 0.08);+ --ring: #3B82F6;+ --chart-1: #3B82F6;+ --chart-2: #8B5CF6;+ --chart-3: #06B6D4;+ --chart-4: #10B981;+ --chart-5: #F59E0B;+ --sidebar: #0F1420;+ --sidebar-foreground: #F8FAFC;+ --sidebar-primary: #3B82F6;+ --sidebar-primary-foreground: #FFFFFF;+ --sidebar-accent: rgba(59, 130, 246, 0.15);+ --sidebar-accent-foreground: #F8FAFC;+ --sidebar-border: rgba(255, 255, 255, 0.08);+ --sidebar-ring: #3B82F6;+}++@layer base {+ * {+ @apply border-border outline-ring/50;+ }+ body {+ @apply bg-background text-foreground antialiased;+ background-image:+ radial-gradient(ellipse at 0% 0%, rgba(59, 130, 246, 0.08) 0%, transparent 50%),+ radial-gradient(ellipse at 100% 0%, rgba(139, 92, 246, 0.05) 0%, transparent 50%),+ radial-gradient(ellipse at 100% 100%, rgba(6, 182, 212, 0.05) 0%, transparent 50%);+ background-attachment: fixed;+ }+}++/* Glass Card Effect */+.glass-card {+ background: rgba(23, 28, 43, 0.6);+ backdrop-filter: blur(20px);+ -webkit-backdrop-filter: blur(20px);+ border: 1px solid rgba(255, 255, 255, 0.08);+ box-shadow:+ 0 4px 6px -1px rgba(0, 0, 0, 0.1),+ 0 2px 4px -2px rgba(0, 0, 0, 0.1),+ inset 0 1px 0 0 rgba(255, 255, 255, 0.05);+}++.light .glass-card {+ background: rgba(255, 255, 255, 0.8);+ border: 1px solid rgba(0, 0, 0, 0.06);+ box-shadow:+ 0 4px 6px -1px rgba(0, 0, 0, 0.05),+ 0 2px 4px -2px rgba(0, 0, 0, 0.05),+ inset 0 1px 0 0 rgba(255, 255, 255, 0.8);+}++/* Gradient Text */+.gradient-text {+ background: linear-gradient(135deg, #3B82F6 0%, #8B5CF6 50%, #06B6D4 100%);+ -webkit-background-clip: text;+ -webkit-text-fill-color: transparent;+ background-clip: text;+}++/* Glow Effects */+.glow-blue {+ box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);+}++.glow-purple {+ box-shadow: 0 0 20px rgba(139, 92, 246, 0.3);+}++/* Custom Scrollbar */+::-webkit-scrollbar {+ width: 6px;+ height: 6px;+}++::-webkit-scrollbar-track {+ background: transparent;+}++::-webkit-scrollbar-thumb {+ background: rgba(148, 163, 184, 0.3);+ border-radius: 3px;+}++::-webkit-scrollbar-thumb:hover {+ background: rgba(148, 163, 184, 0.5);+}++/* Animations */+@keyframes fade-in-up {+ from {+ opacity: 0;+ transform: translateY(20px);+ }+ to {+ opacity: 1;+ transform: translateY(0);+ }+}++@keyframes pulse-glow {+ 0%, 100% {+ box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);+ }+ 50% {+ box-shadow: 0 0 30px rgba(59, 130, 246, 0.5);+ }+}++@keyframes shimmer {+ 0% {+ background-position: -200% 0;+ }+ 100% {+ background-position: 200% 0;+ }+}++.animate-fade-in-up {+ animation: fade-in-up 0.5s ease-out forwards;+}++.animate-pulse-glow {+ animation: pulse-glow 3s ease-in-out infinite;+}++.animate-shimmer {+ background: linear-gradient(+ 90deg,+ transparent 0%,+ rgba(255, 255, 255, 0.1) 50%,+ transparent 100%+ );+ background-size: 200% 100%;+ animation: shimmer 2s infinite;+}++/* Number font */+.tabular-nums {+ font-variant-numeric: tabular-nums;+}++/* Status indicators */+.status-dot {+ @apply w-2 h-2 rounded-full;+}++.status-online {+ @apply bg-emerald-500;+ box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);+}++.status-offline {+ @apply bg-slate-500;+}++/* Card hover effects */+.hover-lift {+ transition: transform 0.2s ease, box-shadow 0.2s ease;+}++.hover-lift:hover {+ transform: translateY(-2px);+ box-shadow: 0 12px 24px -8px rgba(0, 0, 0, 0.2);+}diff --git a/apps/web/components.json b/apps/web/components.jsonnew file mode 100644index 0000000..f3cef3b--- /dev/null+++ b/apps/web/components.json@@ -0,0 +1,23 @@+{+ "$schema": "https://ui.shadcn.com/schema.json",+ "style": "new-york",+ "rsc": true,+ "tsx": true,+ "tailwind": {+ "config": "",+ "css": "app/globals.css",+ "baseColor": "zinc",+ "cssVariables": true,+ "prefix": ""+ },+ "iconLibrary": "lucide",+ "rtl": false,+ "aliases": {+ "components": "@/components",+ "utils": "@/lib/utils",+ "ui": "@/components/ui",+ "lib": "@/lib",+ "hooks": "@/hooks"+ },+ "registries": {}+}diff --git a/apps/web/components/backend-config-dialog.tsx b/apps/web/components/backend-config-dialog.tsxnew file mode 100644index 0000000..b1020ae--- /dev/null+++ b/apps/web/components/backend-config-dialog.tsx@@ -0,0 +1,748 @@+"use client";++import { useState, useEffect } from "react";+import { useTranslations } from "next-intl";+import {+ Server,+ Plus,+ Trash2,+ Edit2,+ Check,+ X,+ RefreshCw,+ AlertCircle,+ CheckCircle2,+ Database,+ HardDrive,+ Trash,+ Settings,+ Radio,+ Eye,+} from "lucide-react";+import { Button } from "@/components/ui/button";+import { Input } from "@/components/ui/input";+import { Switch } from "@/components/ui/switch";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import {+ AlertDialog,+ AlertDialogAction,+ AlertDialogCancel,+ AlertDialogContent,+ AlertDialogDescription,+ AlertDialogFooter,+ AlertDialogHeader,+ AlertDialogTitle,+} from "@/components/ui/alert-dialog";+import { cn, formatBytes } from "@/lib/utils";+import { api } from "@/lib/api";++interface Backend {+ id: number;+ name: string;+ url: string;+ host: string;+ port: number;+ token: string;+ enabled: boolean;+ is_active: boolean;+ listening: boolean;+ hasToken?: boolean;+ created_at: string;+}++interface BackendConfigDialogProps {+ open: boolean;+ onOpenChange: (open: boolean) => void;+ isFirstTime?: boolean;+ onConfigComplete?: () => void;+ onBackendChange?: () => void;+}++interface DbStats {+ size: number;+ totalConnectionsCount: number;+}++// Parse URL to host and port+function parseUrl(url: string): { host: string; port: string; ssl: boolean } {+ try {+ const urlObj = new URL(url);+ return {+ host: urlObj.hostname,+ port: urlObj.port || (urlObj.protocol === 'https:' ? '443' : '80'),+ ssl: urlObj.protocol === 'https:',+ };+ } catch {+ return { host: '', port: '9090', ssl: false };+ }+}++// Build URL from host, port, ssl+function buildUrl(host: string, port: string, ssl: boolean): string {+ const protocol = ssl ? 'https' : 'http';+ return `${protocol}://${host}:${port}`;+}++export function BackendConfigDialog({+ open,+ onOpenChange,+ isFirstTime = false,+ onConfigComplete,+ onBackendChange,+}: BackendConfigDialogProps) {+ const t = useTranslations("backend");+ const commonT = useTranslations("common");++ const [backends, setBackends] = useState<Backend[]>([]);+ const [loading, setLoading] = useState(false);+ const [editingId, setEditingId] = useState<number | null>(null);+ const [testingId, setTestingId] = useState<number | null>(null);+ const [testResult, setTestResult] = useState<{ success: boolean; message: string } | null>(null);+ const [activeTab, setActiveTab] = useState<'backends' | 'database'>('backends');+ const [dbStats, setDbStats] = useState<DbStats | null>(null);+ const [clearingLogs, setClearingLogs] = useState(false);++ // Alert Dialog States+ const [deleteDialogOpen, setDeleteDialogOpen] = useState(false);+ const [deleteBackendId, setDeleteBackendId] = useState<number | null>(null);+ const [clearLogsDialogOpen, setClearLogsDialogOpen] = useState(false);+ const [clearLogsDays, setClearLogsDays] = useState<number>(0);+ const [clearBackendDataDialogOpen, setClearBackendDataDialogOpen] = useState(false);+ const [clearDataBackendId, setClearDataBackendId] = useState<number | null>(null);++ const [formData, setFormData] = useState({+ name: "",+ host: "",+ port: "9090",+ ssl: false,+ token: "",+ });++ useEffect(() => {+ if (open) {+ loadBackends();+ loadDbStats();+ }+ }, [open]);++ const loadBackends = async () => {+ try {+ const data = await api.getBackends();+ // Parse URL to host/port for display+ const parsedData: Backend[] = data.map((b) => {+ const parsed = parseUrl(b.url);+ return { ...b, host: parsed.host, port: parseInt(parsed.port) || 9090 };+ });+ setBackends(parsedData);+ } catch (error) {+ console.error("Failed to load backends:", error);+ }+ };++ const loadDbStats = async () => {+ try {+ const stats = await api.getDbStats();+ setDbStats(stats);+ } catch (error) {+ console.error("Failed to load DB stats:", error);+ }+ };++ const handleAdd = async () => {+ if (!formData.name || !formData.host) return;++ setLoading(true);+ try {+ const url = buildUrl(formData.host, formData.port, formData.ssl);+ const result = await api.createBackend({+ name: formData.name,+ url,+ token: formData.token+ });+ setFormData({ name: "", host: "", port: "9090", ssl: false, token: "" });+ await loadBackends();+ onBackendChange?.();++ // Show success message for first backend+ if (result.isActive) {+ setTestResult({ success: true, message: t("firstBackendAutoActive") });+ setTimeout(() => setTestResult(null), 3000);+ }++ if (isFirstTime && onConfigComplete) {+ onConfigComplete();+ onOpenChange(false);+ }+ } catch (error: any) {+ alert(error.message || "Failed to create backend");+ } finally {+ setLoading(false);+ }+ };++ const handleUpdate = async (id: number) => {+ setLoading(true);+ try {+ const url = buildUrl(formData.host, formData.port, formData.ssl);+ await api.updateBackend(id, {+ name: formData.name,+ url,+ token: formData.token || undefined+ });+ setEditingId(null);+ setFormData({ name: "", host: "", port: "9090", ssl: false, token: "" });+ await loadBackends();+ onBackendChange?.();+ } catch (error: any) {+ alert(error.message || "Failed to update backend");+ } finally {+ setLoading(false);+ }+ };++ // Open delete confirmation dialog+ const openDeleteDialog = (id: number) => {+ setDeleteBackendId(id);+ setDeleteDialogOpen(true);+ };++ // Handle actual delete+ const handleDelete = async () => {+ if (!deleteBackendId) return;++ setLoading(true);+ try {+ await api.deleteBackend(deleteBackendId);+ await loadBackends();+ onBackendChange?.();+ setDeleteDialogOpen(false);+ setDeleteBackendId(null);+ } catch (error: any) {+ alert(error.message || "Failed to delete backend");+ } finally {+ setLoading(false);+ }+ };++ // Handle set active backend (for display)+ const handleSetActive = async (id: number) => {+ try {+ await api.setActiveBackend(id);+ await loadBackends();+ onBackendChange?.();+ // Show success message+ setTestResult({ success: true, message: t("switchSuccess") });+ // Clear success message after 3 seconds+ setTimeout(() => setTestResult(null), 3000);+ } catch (error: any) {+ alert(error.message || t("switchFailed"));+ }+ };++ // Handle toggle listening (data collection)+ const handleToggleListening = async (id: number, listening: boolean) => {+ try {+ await api.setBackendListening(id, listening);+ await loadBackends();+ onBackendChange?.();+ } catch (error: any) {+ alert(error.message || "Failed to update listening state");+ }+ };++ // Open clear backend data dialog+ const openClearBackendDataDialog = (id: number) => {+ setClearDataBackendId(id);+ setClearBackendDataDialogOpen(true);+ };++ // Handle clear backend data+ const handleClearBackendData = async () => {+ if (!clearDataBackendId) return;++ setLoading(true);+ try {+ await api.clearBackendData(clearDataBackendId);+ await loadDbStats();+ onBackendChange?.();+ setClearBackendDataDialogOpen(false);+ setClearDataBackendId(null);+ } catch (error: any) {+ alert(error.message || "Failed to clear backend data");+ } finally {+ setLoading(false);+ }+ };++ const handleTest = async (backend: Backend) => {+ setTestingId(backend.id);+ setTestResult(null);+ try {+ const result = await api.testBackend(backend.url, backend.token);+ setTestResult(result);+ } catch (error: any) {+ setTestResult({ success: false, message: error.message || "Test failed" });+ } finally {+ setTestingId(null);+ }+ };++ // Open clear logs dialog+ const openClearLogsDialog = (days: number) => {+ setClearLogsDays(days);+ setClearLogsDialogOpen(true);+ };++ // Handle actual clear logs+ const handleClearLogs = async () => {+ setClearingLogs(true);+ try {+ await api.clearLogs(clearLogsDays);+ await loadDbStats();+ setClearLogsDialogOpen(false);+ alert(t("logsCleared"));+ } catch (error: any) {+ alert(error.message || "Failed to clear logs");+ } finally {+ setClearingLogs(false);+ }+ };++ const startEdit = (backend: Backend) => {+ setEditingId(backend.id);+ setFormData({+ name: backend.name,+ host: backend.host,+ port: String(backend.port || 9090),+ ssl: backend.url.startsWith('https'),+ token: "",+ });+ };++ const cancelEdit = () => {+ setEditingId(null);+ setFormData({ name: "", host: "", port: "9090", ssl: false, token: "" });+ };++ if (!open) return null;++ return (+ <>+ <div className="fixed inset-0 z-50 bg-background/80 backdrop-blur-sm flex items-center justify-center p-4">+ <Card className="w-full max-w-2xl max-h-[90vh] overflow-y-auto">+ <CardHeader>+ <CardTitle className="flex items-center gap-2">+ <Settings className="w-5 h-5" />+ {isFirstTime ? t("firstTimeTitle") : t("title")}+ </CardTitle>+ <p className="text-sm text-muted-foreground">+ {isFirstTime ? t("firstTimeDescription") : t("description")}+ </p>++ {/* Tabs */}+ <div className="flex gap-2 mt-4">+ <Button+ variant={activeTab === 'backends' ? 'default' : 'ghost'}+ size="sm"+ onClick={() => setActiveTab('backends')}+ >+ <Server className="w-4 h-4 mr-2" />+ {t("backendsTab")}+ </Button>+ <Button+ variant={activeTab === 'database' ? 'default' : 'ghost'}+ size="sm"+ onClick={() => setActiveTab('database')}+ >+ <Database className="w-4 h-4 mr-2" />+ {t("databaseTab")}+ </Button>+ </div>+ </CardHeader>++ <CardContent className="space-y-4">+ {activeTab === 'backends' ? (+ // Backends Tab+ <div className="space-y-3">+ {backends.map((backend) => (+ <div+ key={backend.id}+ className={cn(+ "p-4 rounded-lg border transition-all",+ backend.is_active+ ? "border-primary bg-primary/5"+ : "border-border bg-card",+ !backend.enabled && "opacity-60"+ )}+ >+ {editingId === backend.id ? (+ // Edit Mode+ <div className="space-y-3">+ <div className="grid grid-cols-2 gap-3">+ <div>+ <label className="text-xs font-medium">{t("name")}</label>+ <Input+ value={formData.name}+ onChange={(e) => setFormData({ ...formData, name: e.target.value })}+ placeholder={t("namePlaceholder")}+ className="h-9 mt-1"+ />+ </div>+ <div>+ <label className="text-xs font-medium">{t("host")}</label>+ <Input+ value={formData.host}+ onChange={(e) => setFormData({ ...formData, host: e.target.value })}+ placeholder="192.168.1.1"+ className="h-9 mt-1"+ />+ </div>+ </div>+ <div className="grid grid-cols-3 gap-3">+ <div>+ <label className="text-xs font-medium">{t("port")}</label>+ <Input+ value={formData.port}+ onChange={(e) => setFormData({ ...formData, port: e.target.value })}+ placeholder="9090"+ className="h-9 mt-1"+ />+ </div>+ <div className="col-span-2 flex items-center gap-2 pt-5">+ <Switch+ checked={formData.ssl}+ onCheckedChange={(checked) => setFormData({ ...formData, ssl: checked })}+ />+ <label className="text-sm">{t("useSsl")}</label>+ </div>+ </div>+ <div>+ <label className="text-xs font-medium">{t("token")}</label>+ <Input+ type="password"+ value={formData.token}+ onChange={(e) => setFormData({ ...formData, token: e.target.value })}+ placeholder={t("tokenPlaceholder")}+ className="h-9 mt-1"+ />+ </div>+ <div className="flex gap-2 justify-end">+ <Button variant="ghost" size="sm" onClick={cancelEdit}>+ <X className="w-4 h-4 mr-1" />+ {commonT("cancel")}+ </Button>+ <Button size="sm" onClick={() => handleUpdate(backend.id)} disabled={loading}>+ <Check className="w-4 h-4 mr-1" />+ {commonT("save")}+ </Button>+ </div>+ </div>+ ) : (+ // View Mode+ <div className="flex items-center justify-between">+ <div className="flex-1 min-w-0">+ <div className="flex items-center gap-2 flex-wrap">+ <span className="font-medium truncate">{backend.name}</span>+ {backend.is_active && (+ <span className="px-2 py-0.5 rounded-full bg-primary text-primary-foreground text-xs">+ {t("displaying")}+ </span>+ )}+ {backend.listening && (+ <span className="px-2 py-0.5 rounded-full bg-green-500 text-white text-xs flex items-center gap-1">+ <Radio className="w-3 h-3" />+ {t("collecting")}+ </span>+ )}+ {!backend.enabled && (+ <span className="px-2 py-0.5 rounded-full bg-muted text-muted-foreground text-xs">+ {t("disabled")}+ </span>+ )}+ </div>+ <div className="text-sm text-muted-foreground truncate mt-0.5">+ {backend.host}:{backend.port}+ </div>+ </div>++ <div className="flex items-center gap-1 ml-4">+ {/* Listening Toggle */}+ <div className="flex items-center gap-2 mr-2 pr-2 border-r">+ <Switch+ checked={backend.listening}+ onCheckedChange={(checked) => handleToggleListening(backend.id, checked)}+ className="data-[state=checked]:bg-green-500"+ />+ <span className="text-xs text-muted-foreground hidden sm:inline">+ {t("collect")}+ </span>+ </div>++ {/* Set Active (Display) Button */}+ {!backend.is_active && (+ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => handleSetActive(backend.id)}+ title={t("setActive")}+ >+ <Eye className="w-4 h-4" />+ </Button>+ )}++ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => handleTest(backend)}+ disabled={testingId === backend.id}+ title={t("testConnection")}+ >+ <RefreshCw className={cn("w-4 h-4", testingId === backend.id && "animate-spin")} />+ </Button>++ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => startEdit(backend)}+ title={commonT("edit")}+ >+ <Edit2 className="w-4 h-4" />+ </Button>++ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8 text-destructive hover:text-destructive"+ onClick={() => openDeleteDialog(backend.id)}+ title={commonT("delete")}+ >+ <Trash2 className="w-4 h-4" />+ </Button>+ </div>+ </div>+ )}+ </div>+ ))}++ {/* Test Result */}+ {testResult && (+ <div+ className={cn(+ "p-3 rounded-lg flex items-center gap-2 text-sm",+ testResult.success+ ? "bg-green-500/10 text-green-600 border border-green-500/20"+ : "bg-destructive/10 text-destructive border border-destructive/20"+ )}+ >+ {testResult.success ? (+ <CheckCircle2 className="w-4 h-4 shrink-0" />+ ) : (+ <AlertCircle className="w-4 h-4 shrink-0" />+ )}+ {testResult.message}+ </div>+ )}++ {/* Add New Backend Form */}+ <div className="p-4 rounded-lg border border-dashed border-border bg-muted/50">+ <h4 className="text-sm font-medium mb-3 flex items-center gap-2">+ <Plus className="w-4 h-4" />+ {backends.length === 0 && isFirstTime ? t("firstTimeTitle") : t("addNew")}+ </h4>+ <div className="space-y-3">+ <div className="grid grid-cols-2 gap-3">+ <div>+ <label className="text-xs font-medium">{t("name")} *</label>+ <Input+ value={formData.name}+ onChange={(e) => setFormData({ ...formData, name: e.target.value })}+ placeholder={t("namePlaceholder")}+ className="h-9 mt-1"+ />+ </div>+ <div>+ <label className="text-xs font-medium">{t("host")} *</label>+ <Input+ value={formData.host}+ onChange={(e) => setFormData({ ...formData, host: e.target.value })}+ placeholder="192.168.1.1"+ className="h-9 mt-1"+ />+ </div>+ </div>+ <div className="grid grid-cols-3 gap-3">+ <div>+ <label className="text-xs font-medium">{t("port")}</label>+ <Input+ value={formData.port}+ onChange={(e) => setFormData({ ...formData, port: e.target.value })}+ placeholder="9090"+ className="h-9 mt-1"+ />+ </div>+ <div className="col-span-2 flex items-center gap-2 pt-5">+ <Switch+ checked={formData.ssl}+ onCheckedChange={(checked) => setFormData({ ...formData, ssl: checked })}+ />+ <label className="text-sm">{t("useSsl")}</label>+ </div>+ </div>+ <div>+ <label className="text-xs font-medium">{t("token")}</label>+ <Input+ type="password"+ value={formData.token}+ onChange={(e) => setFormData({ ...formData, token: e.target.value })}+ placeholder={t("tokenPlaceholder")}+ className="h-9 mt-1"+ />+ </div>+ <Button+ onClick={handleAdd}+ disabled={loading || !formData.name || !formData.host}+ className="w-full"+ >+ <Plus className="w-4 h-4 mr-2" />+ {isFirstTime && backends.length === 0 ? t("saveAndContinue") : t("addBackend")}+ </Button>+ </div>+ </div>+ </div>+ ) : (+ // Database Tab+ <div className="space-y-6">+ {/* DB Stats */}+ <div className="p-4 rounded-lg border bg-card">+ <h4 className="text-sm font-medium mb-4 flex items-center gap-2">+ <HardDrive className="w-4 h-4" />+ {t("databaseStats")}+ </h4>+ <div className="grid grid-cols-2 gap-4">+ <div className="p-3 rounded-lg bg-muted">+ <div className="text-xs text-muted-foreground">{t("dbSize")}</div>+ <div className="text-lg font-semibold">+ {dbStats ? formatBytes(dbStats.size) : "--"}+ </div>+ </div>+ <div className="p-3 rounded-lg bg-muted">+ <div className="text-xs text-muted-foreground">{t("connectionsCount")}</div>+ <div className="text-lg font-semibold">+ {dbStats ? dbStats.totalConnectionsCount.toLocaleString() : "--"}+ </div>+ </div>+ </div>+ </div>++ {/* Clear Logs */}+ <div className="p-4 rounded-lg border bg-card">+ <h4 className="text-sm font-medium mb-4 flex items-center gap-2">+ <Trash className="w-4 h-4" />+ {t("clearLogs")}+ </h4>+ <p className="text-sm text-muted-foreground mb-4">+ {t("clearLogsDescription")}+ </p>+ <div className="flex flex-wrap gap-2">+ <Button+ variant="outline"+ size="sm"+ onClick={() => openClearLogsDialog(1)}+ disabled={clearingLogs}+ >+ {t("clear1Day")}+ </Button>+ <Button+ variant="outline"+ size="sm"+ onClick={() => openClearLogsDialog(7)}+ disabled={clearingLogs}+ >+ {t("clear7Days")}+ </Button>+ <Button+ variant="outline"+ size="sm"+ onClick={() => openClearLogsDialog(30)}+ disabled={clearingLogs}+ >+ {t("clear30Days")}+ </Button>+ <Button+ variant="destructive"+ size="sm"+ onClick={() => openClearLogsDialog(0)}+ disabled={clearingLogs}+ >+ {t("clearAll")}+ </Button>+ </div>+ </div>+ </div>+ )}++ {/* Close button for non-first-time */}+ {!isFirstTime && (+ <div className="flex justify-end pt-4 border-t">+ <Button variant="outline" onClick={() => onOpenChange(false)}>+ {commonT("close")}+ </Button>+ </div>+ )}+ </CardContent>+ </Card>+ </div>++ {/* Delete Confirmation Dialog */}+ <AlertDialog open={deleteDialogOpen} onOpenChange={setDeleteDialogOpen}>+ <AlertDialogContent>+ <AlertDialogHeader>+ <AlertDialogTitle>{t("confirmDelete")}</AlertDialogTitle>+ <AlertDialogDescription>+ {t("deleteDescription")}+ </AlertDialogDescription>+ </AlertDialogHeader>+ <AlertDialogFooter>+ <AlertDialogCancel onClick={() => setDeleteBackendId(null)}>+ {commonT("cancel")}+ </AlertDialogCancel>+ <AlertDialogAction+ onClick={handleDelete}+ className="bg-destructive text-destructive-foreground hover:bg-destructive/90"+ >+ {commonT("delete")}+ </AlertDialogAction>+ </AlertDialogFooter>+ </AlertDialogContent>+ </AlertDialog>++ {/* Clear Logs Confirmation Dialog */}+ <AlertDialog open={clearLogsDialogOpen} onOpenChange={setClearLogsDialogOpen}>+ <AlertDialogContent>+ <AlertDialogHeader>+ <AlertDialogTitle>{t("clearLogs")}</AlertDialogTitle>+ <AlertDialogDescription>+ {clearLogsDays === 0+ ? t("confirmClearAllLogs")+ : t("confirmClearLogs", { days: clearLogsDays })}+ </AlertDialogDescription>+ </AlertDialogHeader>+ <AlertDialogFooter>+ <AlertDialogCancel>+ {commonT("cancel")}+ </AlertDialogCancel>+ <AlertDialogAction+ onClick={handleClearLogs}+ className={clearLogsDays === 0 ? "bg-destructive text-destructive-foreground hover:bg-destructive/90" : ""}+ >+ {commonT("confirm")}+ </AlertDialogAction>+ </AlertDialogFooter>+ </AlertDialogContent>+ </AlertDialog>+ </>+ );+}diff --git a/apps/web/components/country-top-list.tsx b/apps/web/components/country-top-list.tsxnew file mode 100644index 0000000..7642ea3--- /dev/null+++ b/apps/web/components/country-top-list.tsx@@ -0,0 +1,92 @@+"use client";++import { useMemo } from "react";+import { MapPin } from "lucide-react";+import { OverviewCard } from "./overview-card";+import { TopListItem } from "./top-list-item";+import { Button } from "@/components/ui/button";+import type { CountryStats } from "@clashstats/shared";++interface CountryTopListProps {+ data: CountryStats[];+ limit?: number;+ onViewAll?: () => void;+}++const COUNTRY_FLAGS: Record<string, string> = {+ US: "🇺🇸", CN: "🇨🇳", JP: "🇯🇵", SG: "🇸🇬", HK: "🇭🇰",+ TW: "🇹🇼", KR: "🇰🇷", GB: "🇬🇧", DE: "🇩🇪", FR: "🇫🇷",+ NL: "🇳🇱", CA: "🇨🇦", AU: "🇦🇺", IN: "🇮🇳", BR: "🇧🇷",+ RU: "🇷🇺", SE: "🇸🇪", CH: "🇨🇭", IL: "🇮🇱", ID: "🇮🇩",+ LOCAL: "🏠",+};++const CONTINENT_COLORS: Record<string, string> = {+ AS: "#F59E0B", NA: "#3B82F6", EU: "#8B5CF6",+ SA: "#10B981", AF: "#EF4444", OC: "#06B6D4",+ LOCAL: "#6B7280",+};++function getFlag(country: string): string {+ return COUNTRY_FLAGS[country] || COUNTRY_FLAGS[country.toUpperCase()] || "🌐";+}++function getContinentColor(continent: string): string {+ return CONTINENT_COLORS[continent] || "#6B7280";+}++export function CountryTopList({ data, limit = 7, onViewAll }: CountryTopListProps) {+ const { countries, totalTraffic } = useMemo(() => {+ if (!data) return { countries: [], totalTraffic: 0 };+ const list = data+ .filter(c => c.country !== "LOCAL" && c.country !== "Unknown")+ .slice(0, limit)+ .map(c => ({+ ...c,+ total: c.totalDownload + c.totalUpload,+ flag: getFlag(c.country),+ color: getContinentColor(c.continent),+ }));+ const total = list.reduce((sum, c) => sum + c.total, 0);+ return { countries: list, totalTraffic: total };+ }, [data, limit]);++ if (countries.length === 0) {+ return (+ <OverviewCard title="Top 国家/地区" icon={<MapPin className="w-4 h-4" />}>+ <div className="py-8 text-center text-sm text-muted-foreground">+ 暂无数据+ </div>+ </OverviewCard>+ );+ }++ return (+ <OverviewCard+ title="Top 国家/地区"+ icon={<MapPin className="w-4 h-4" />}+ footer={+ onViewAll && (+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs" onClick={onViewAll}>+ 查看全部+ </Button>+ )+ }+ >+ <div className="space-y-1 min-h-[320px]">+ {countries.map((country, index) => (+ <TopListItem+ key={country.country}+ rank={index + 1}+ icon={<span className="text-xl">{country.flag}</span>}+ title={country.countryName || country.country}+ subtitle={country.continent}+ value={country.total}+ total={totalTraffic}+ color={country.color}+ />+ ))}+ </div>+ </OverviewCard>+ );+}diff --git a/apps/web/components/country-traffic-chart.tsx b/apps/web/components/country-traffic-chart.tsxnew file mode 100644index 0000000..fc09c14--- /dev/null+++ b/apps/web/components/country-traffic-chart.tsx@@ -0,0 +1,216 @@+"use client";++import { useMemo } from "react";+import { PieChart, Pie, Cell, ResponsiveContainer, Tooltip } from "recharts";+import { Globe, MapPin } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { formatBytes } from "@/lib/utils";+import type { CountryStats } from "@clashstats/shared";++interface CountryTrafficChartProps {+ data: CountryStats[];+}++// Country flag emoji mapping+const COUNTRY_FLAGS: Record<string, string> = {+ US: "🇺🇸",+ CN: "🇨🇳",+ JP: "🇯🇵",+ SG: "🇸🇬",+ HK: "🇭🇰",+ TW: "🇹🇼",+ KR: "🇰🇷",+ GB: "🇬🇧",+ DE: "🇩🇪",+ FR: "🇫🇷",+ NL: "🇳🇱",+ CA: "🇨🇦",+ AU: "🇦🇺",+ IN: "🇮🇳",+ BR: "🇧🇷",+ RU: "🇷🇺",+ LOCAL: "🏠",+ Unknown: "❓",+};++// Continent colors+const CONTINENT_COLORS: Record<string, string> = {+ AS: "#F59E0B", // Asia - Amber+ NA: "#3B82F6", // North America - Blue+ EU: "#8B5CF6", // Europe - Purple+ SA: "#10B981", // South America - Emerald+ AF: "#EF4444", // Africa - Red+ OC: "#06B6D4", // Oceania - Cyan+ LOCAL: "#6B7280", // Local - Gray+ Unknown: "#9CA3AF", // Unknown - Gray+};++// Get flag for country+function getCountryFlag(country: string): string {+ return COUNTRY_FLAGS[country] || COUNTRY_FLAGS[country.toUpperCase()] || "🌐";+}++// Get color for continent+function getContinentColor(continent: string): string {+ return CONTINENT_COLORS[continent] || CONTINENT_COLORS.Unknown;+}++export function CountryTrafficChart({ data }: CountryTrafficChartProps) {+ const chartData = useMemo(() => {+ if (!data) return [];+ return data.map((country) => ({+ name: country.countryName || country.country,+ code: country.country,+ flag: getCountryFlag(country.country),+ value: country.totalDownload + country.totalUpload,+ download: country.totalDownload,+ upload: country.totalUpload,+ connections: country.totalConnections,+ continent: country.continent,+ color: getContinentColor(country.continent),+ }));+ }, [data]);++ const totalTraffic = useMemo(() => {+ return chartData.reduce((sum, item) => sum + item.value, 0);+ }, [chartData]);++ const CustomTooltip = ({ active, payload }: any) => {+ if (active && payload && payload.length) {+ const item = payload[0].payload;+ return (+ <div className="glass-card p-3 rounded-lg border shadow-lg">+ <div className="flex items-center gap-2 mb-2">+ <span className="text-2xl">{item.flag}</span>+ <span className="font-medium text-sm">{item.name}</span>+ </div>+ <div className="space-y-1 text-xs">+ <div className="flex justify-between gap-4">+ <span className="text-muted-foreground">Total:</span>+ <span className="font-medium">{formatBytes(item.value)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-blue-500">↓ Download:</span>+ <span>{formatBytes(item.download)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-purple-500">↑ Upload:</span>+ <span>{formatBytes(item.upload)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-emerald-500">Connections:</span>+ <span>{item.connections.toLocaleString()}</span>+ </div>+ </div>+ </div>+ );+ }+ return null;+ };++ return (+ <Card>+ <CardHeader className="pb-2">+ <CardTitle className="text-lg font-semibold flex items-center gap-2">+ <Globe className="h-5 w-5 text-primary" />+ Country Traffic Distribution+ </CardTitle>+ </CardHeader>+ <CardContent className="space-y-6">+ {/* Pie Chart at Top */}+ <div className="h-[220px] w-full">+ <ResponsiveContainer width="100%" height="100%">+ <PieChart>+ <Pie+ data={chartData}+ cx="50%"+ cy="50%"+ innerRadius={50}+ outerRadius={80}+ paddingAngle={2}+ dataKey="value"+ >+ {chartData.map((entry, index) => (+ <Cell key={`cell-${index}`} fill={entry.color} />+ ))}+ </Pie>+ <Tooltip content={<CustomTooltip />} />+ </PieChart>+ </ResponsiveContainer>+ </div>++ {/* Country Cards Grid */}+ <div className="grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-3">+ {chartData.map((item) => {+ const percentage = totalTraffic > 0 ? (item.value / totalTraffic) * 100 : 0;++ return (+ <div+ key={item.code}+ className="p-3 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Header: Flag + Name */}+ <div className="flex items-center gap-2 mb-2">+ <span className="text-xl">{item.flag}</span>+ <p className="font-medium text-sm truncate" title={item.name}>+ {item.name}+ </p>+ </div>++ {/* Traffic Stats */}+ <div className="space-y-2">+ {/* Total with percentage */}+ <div className="flex items-baseline justify-between">+ <span className="text-lg font-bold tabular-nums">+ {formatBytes(item.value)}+ </span>+ <span className="text-xs text-muted-foreground">+ {percentage.toFixed(1)}%+ </span>+ </div>++ {/* Progress bar */}+ <div className="h-1.5 bg-muted rounded-full overflow-hidden">+ <div+ className="h-full rounded-full transition-all duration-500"+ style={{ width: `${percentage}%`, backgroundColor: item.color }}+ />+ </div>++ {/* Download/Upload row */}+ <div className="flex items-center justify-between text-xs pt-1">+ <span className="text-blue-500 tabular-nums">+ ↓ {formatBytes(item.download)}+ </span>+ <span className="text-purple-500 tabular-nums">+ ↑ {formatBytes(item.upload)}+ </span>+ </div>++ {/* Connections */}+ <div className="flex items-center gap-1 text-xs text-muted-foreground">+ <MapPin className="w-3 h-3" />+ <span>{item.connections.toLocaleString()} conn</span>+ </div>+ </div>+ </div>+ );+ })}+ </div>++ {/* Legend */}+ <div className="flex flex-wrap gap-3 text-xs text-muted-foreground pt-2 border-t border-border">+ <span className="font-medium">大洲:</span>+ {Object.entries(CONTINENT_COLORS)+ .filter(([key]) => key !== "Unknown" && key !== "LOCAL")+ .map(([continent, color]) => (+ <span key={continent} className="flex items-center gap-1">+ <span className="w-2 h-2 rounded-full" style={{ backgroundColor: color }} />+ {continent}+ </span>+ ))}+ </div>+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/country-traffic-list.tsx b/apps/web/components/country-traffic-list.tsxnew file mode 100644index 0000000..8cffe0b--- /dev/null+++ b/apps/web/components/country-traffic-list.tsx@@ -0,0 +1,125 @@+"use client";++import { useMemo } from "react";+import { MapPin, ArrowDown, ArrowUp } from "lucide-react";+import { formatBytes } from "@/lib/utils";+import type { CountryStats } from "@clashstats/shared";++interface CountryTrafficListProps {+ data: CountryStats[];+}++// Country flag emoji mapping+const COUNTRY_FLAGS: Record<string, string> = {+ US: "🇺🇸", CN: "🇨🇳", JP: "🇯🇵", SG: "🇸🇬", HK: "🇭🇰",+ TW: "🇹🇼", KR: "🇰🇷", GB: "🇬🇧", DE: "🇩🇪", FR: "🇫🇷",+ NL: "🇳🇱", CA: "🇨🇦", AU: "🇦🇺", IN: "🇮🇳", BR: "🇧🇷",+ RU: "🇷🇺", SE: "🇸🇪", CH: "🇨🇭", IL: "🇮🇱", LOCAL: "🏠",+ Unknown: "❓",+};++// Continent colors+const CONTINENT_COLORS: Record<string, string> = {+ AS: "#F59E0B", NA: "#3B82F6", EU: "#8B5CF6",+ SA: "#10B981", AF: "#EF4444", OC: "#06B6D4",+ LOCAL: "#6B7280", Unknown: "#9CA3AF",+};++function getCountryFlag(country: string): string {+ return COUNTRY_FLAGS[country] || COUNTRY_FLAGS[country.toUpperCase()] || "🌐";+}++function getContinentColor(continent: string): string {+ return CONTINENT_COLORS[continent] || CONTINENT_COLORS.Unknown;+}++export function CountryTrafficList({ data }: CountryTrafficListProps) {+ const countries = useMemo(() => {+ if (!data) return [];+ return data+ .filter(c => c.country !== "LOCAL" && c.country !== "Unknown")+ .map((country) => ({+ ...country,+ flag: getCountryFlag(country.country),+ color: getContinentColor(country.continent),+ total: country.totalDownload + country.totalUpload,+ }))+ .sort((a, b) => b.total - a.total);+ }, [data]);++ const totalTraffic = useMemo(() => {+ return countries.reduce((sum, c) => sum + c.total, 0);+ }, [countries]);++ if (countries.length === 0) {+ return (+ <div className="grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 xl:grid-cols-6 gap-3">+ {[...Array(6)].map((_, i) => (+ <div key={i} className="p-3 rounded-xl border border-border/30 bg-muted/50 h-24" />+ ))}+ </div>+ );+ }++ return (+ <div className="grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 xl:grid-cols-6 gap-3">+ {countries.map((country) => {+ const percentage = totalTraffic > 0 ? (country.total / totalTraffic) * 100 : 0;++ return (+ <div+ key={country.country}+ className="p-3 rounded-xl border border-border/50 bg-card/30 hover:bg-card/60 transition-colors"+ >+ {/* Header: Flag + Name */}+ <div className="flex items-center gap-2 mb-2">+ <span className="text-xl">{country.flag}</span>+ <p className="font-medium text-sm truncate" title={country.countryName}>+ {country.countryName || country.country}+ </p>+ </div>++ {/* Traffic Stats */}+ <div className="space-y-1.5">+ {/* Total */}+ <div className="flex items-baseline justify-between">+ <span className="text-lg font-bold tabular-nums">+ {formatBytes(country.total)}+ </span>+ <span className="text-xs text-muted-foreground">+ {percentage.toFixed(1)}%+ </span>+ </div>++ {/* Progress bar */}+ <div className="h-1 bg-muted rounded-full overflow-hidden">+ <div+ className="h-full rounded-full transition-all duration-500"+ style={{ width: `${percentage}%`, backgroundColor: country.color }}+ />+ </div>++ {/* DL/UL row */}+ <div className="flex items-center justify-between text-xs">+ <span className="flex items-center gap-0.5 text-blue-500">+ <ArrowDown className="w-3 h-3" />+ {formatBytes(country.totalDownload)}+ </span>+ <span className="flex items-center gap-0.5 text-purple-500">+ <ArrowUp className="w-3 h-3" />+ {formatBytes(country.totalUpload)}+ </span>+ </div>++ {/* Connections */}+ <div className="flex items-center gap-1 text-xs text-muted-foreground">+ <MapPin className="w-3 h-3" />+ <span>{country.totalConnections.toLocaleString()}</span>+ </div>+ </div>+ </div>+ );+ })}+ </div>+ );+}diff --git a/apps/web/components/domain-top-grid.tsx b/apps/web/components/domain-top-grid.tsxnew file mode 100644index 0000000..3c3c3ab--- /dev/null+++ b/apps/web/components/domain-top-grid.tsx@@ -0,0 +1,128 @@+"use client";++import { useMemo, useState } from "react";+import { Globe, Users, ArrowUpDown, ArrowRight } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { Button } from "@/components/ui/button";+import { formatBytes } from "@/lib/utils";+import type { DomainStats } from "@clashstats/shared";++interface DomainTopGridProps {+ data: DomainStats[];+ limit?: number;+ onViewAll?: () => void;+}++type SortBy = "traffic" | "connections";++function getFaviconUrl(domain: string): string {+ return `https://www.google.com/s2/favicons?domain=${domain}&sz=64`;+}++function getInitials(domain: string): string {+ return domain.slice(0, 2).toUpperCase();+}++export function DomainTopGrid({ data, limit = 5, onViewAll }: DomainTopGridProps) {+ const [sortBy, setSortBy] = useState<SortBy>("traffic");++ const domains = useMemo(() => {+ if (!data) return [];+ const sorted = [...data]+ .sort((a, b) => {+ if (sortBy === "traffic") {+ return (b.totalDownload + b.totalUpload) - (a.totalDownload + a.totalUpload);+ }+ return b.totalConnections - a.totalConnections;+ });+ return sorted.slice(0, limit).map(d => ({+ ...d,+ total: d.totalDownload + d.totalUpload,+ }));+ }, [data, limit, sortBy]);++ const toggleSort = () => setSortBy(prev => prev === "traffic" ? "connections" : "traffic");++ return (+ <Card className="h-full flex flex-col">+ <CardHeader className="pb-3 flex-shrink-0">+ <div className="flex items-center justify-between">+ <CardTitle className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Globe className="w-4 h-4" />+ Top 域名+ </CardTitle>+ <Button variant="ghost" size="sm" className="h-7 px-2 text-xs" onClick={toggleSort}>+ {sortBy === "traffic" ? (+ <><ArrowUpDown className="w-3 h-3 mr-1" /> 流量</>+ ) : (+ <><Users className="w-3 h-3 mr-1" /> 连接</>+ )}+ </Button>+ </div>+ </CardHeader>+ <CardContent className="flex-1 flex flex-col pt-0">+ <div className="space-y-2 flex-1">+ {domains.map((domain, index) => (+ <div+ key={domain.domain}+ className="p-3 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Row 1: Rank + Icon + Domain + Total */}+ <div className="flex items-center gap-2 mb-2">+ <span className={`+ w-5 h-5 rounded text-[10px] font-bold flex items-center justify-center shrink-0+ ${index < 3 ? "bg-primary/10 text-primary" : "bg-muted text-muted-foreground"}+ `}>+ {index + 1}+ </span>++ <img+ src={getFaviconUrl(domain.domain)}+ alt=""+ className="w-5 h-5 rounded"+ onError={(e) => {+ const target = e.target as HTMLImageElement;+ target.style.display = "none";+ const parent = target.parentElement;+ if (parent) {+ parent.innerHTML = `<span class="w-5 h-5 rounded bg-muted flex items-center justify-center text-[9px] font-bold text-muted-foreground">${getInitials(domain.domain)}</span>`;+ }+ }}+ />++ <span className="flex-1 text-sm font-medium truncate" title={domain.domain}>+ {domain.domain}+ </span>++ <span className="text-sm font-bold tabular-nums text-foreground">+ {formatBytes(domain.total)}+ </span>+ </div>++ {/* Row 2: Stats */}+ <div className="flex items-center justify-between text-xs text-muted-foreground pl-7">+ <div className="flex items-center gap-3">+ <span className="text-blue-500">↓ {formatBytes(domain.totalDownload)}</span>+ <span className="text-purple-500">↑ {formatBytes(domain.totalUpload)}</span>+ </div>+ <span className="flex items-center gap-1">+ <Users className="w-3 h-3" />+ {domain.totalConnections}+ </span>+ </div>+ </div>+ ))}+ </div>++ {onViewAll && (+ <div className="mt-4 pt-3 border-t border-border/30">+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs" onClick={onViewAll}>+ 查看全部+ <ArrowRight className="w-3 h-3 ml-1" />+ </Button>+ </div>+ )}+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/domain-top-list.tsx b/apps/web/components/domain-top-list.tsxnew file mode 100644index 0000000..30c03a8--- /dev/null+++ b/apps/web/components/domain-top-list.tsx@@ -0,0 +1,132 @@+"use client";++import { useMemo, useState } from "react";+import { Globe, Users, ArrowUpDown } from "lucide-react";+import { OverviewCard } from "./overview-card";+import { TopListItem } from "./top-list-item";+import { Button } from "@/components/ui/button";+import type { DomainStats } from "@clashstats/shared";++interface DomainTopListProps {+ data: DomainStats[];+ limit?: number;+ onViewAll?: () => void;+}++type SortBy = "traffic" | "connections";++const COLORS = [+ "#3B82F6", "#8B5CF6", "#06B6D4", "#10B981", "#F59E0B",+ "#EF4444", "#EC4899", "#6366F1"+];++function getFaviconUrl(domain: string): string {+ return `https://www.google.com/s2/favicons?domain=${domain}&sz=64`;+}++function getInitials(domain: string): string {+ return domain.charAt(0).toUpperCase();+}++export function DomainTopList({ data, limit = 7, onViewAll }: DomainTopListProps) {+ const [sortBy, setSortBy] = useState<SortBy>("traffic");++ const { domains, totalTraffic, totalConnections } = useMemo(() => {+ if (!data) return { domains: [], totalTraffic: 0, totalConnections: 0 };++ const sorted = [...data]+ .sort((a, b) => {+ if (sortBy === "traffic") {+ const totalA = a.totalDownload + a.totalUpload;+ const totalB = b.totalDownload + b.totalUpload;+ return totalB - totalA;+ }+ return b.totalConnections - a.totalConnections;+ });++ const list = sorted.slice(0, limit).map((d, i) => ({+ ...d,+ total: d.totalDownload + d.totalUpload,+ color: COLORS[i % COLORS.length],+ }));++ const totalT = list.reduce((sum, d) => sum + d.total, 0);+ const totalC = list.reduce((sum, d) => sum + d.totalConnections, 0);++ return { domains: list, totalTraffic: totalT, totalConnections: totalC };+ }, [data, limit, sortBy]);++ const toggleSort = () => {+ setSortBy(prev => prev === "traffic" ? "connections" : "traffic");+ };++ if (domains.length === 0) {+ return (+ <OverviewCard title="Top 域名" icon={<Globe className="w-4 h-4" />}>+ <div className="py-8 text-center text-sm text-muted-foreground">+ 暂无数据+ </div>+ </OverviewCard>+ );+ }++ return (+ <OverviewCard+ title="Top 域名"+ icon={<Globe className="w-4 h-4" />}+ action={+ <Button+ variant="ghost"+ size="sm"+ className="h-7 px-2 text-xs"+ onClick={toggleSort}+ >+ {sortBy === "traffic" ? (+ <><ArrowUpDown className="w-3 h-3 mr-1" /> 按流量</>+ ) : (+ <><Users className="w-3 h-3 mr-1" /> 按连接</>+ )}+ </Button>+ }+ footer={+ onViewAll && (+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs" onClick={onViewAll}>+ 查看全部+ </Button>+ )+ }+ >+ <div className="space-y-1 min-h-[320px]">+ {domains.map((domain, index) => (+ <TopListItem+ key={domain.domain}+ rank={index + 1}+ icon={+ <img+ src={getFaviconUrl(domain.domain)}+ alt=""+ className="w-5 h-5"+ onError={(e) => {+ const target = e.target as HTMLImageElement;+ target.style.display = "none";+ target.parentElement!.innerHTML = `<span class="text-xs font-bold text-muted-foreground">${getInitials(domain.domain)}</span>`;+ }}+ />+ }+ title={domain.domain}+ subtitle={sortBy === "traffic"+ ? `${domain.totalConnections} 连接`+ : `${formatBytes(domain.total)}`+ }+ value={sortBy === "traffic" ? domain.total : domain.totalConnections}+ total={sortBy === "traffic" ? totalTraffic : totalConnections}+ color={domain.color}+ valueFormatter={sortBy === "connections" ? (v) => `${v}` : undefined}+ />+ ))}+ </div>+ </OverviewCard>+ );+}++import { formatBytes } from "@/lib/utils";diff --git a/apps/web/components/domains-table.tsx b/apps/web/components/domains-table.tsxnew file mode 100644index 0000000..a457ef0--- /dev/null+++ b/apps/web/components/domains-table.tsx@@ -0,0 +1,386 @@+"use client";++import { useState, useMemo } from "react";+import { Search, ArrowUpDown, ArrowDown, ArrowUp, ChevronLeft, ChevronRight, Rows3, ChevronDown, ChevronUp, Globe, Server } from "lucide-react";+import { useTranslations } from "next-intl";+import { Input } from "@/components/ui/input";+import { Button } from "@/components/ui/button";+import { Favicon } from "@/components/favicon";+import { formatBytes, formatDuration } from "@/lib/utils";+import { cn } from "@/lib/utils";+import type { DomainStats } from "@clashstats/shared";+import {+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuItem,+ DropdownMenuTrigger,+} from "@/components/ui/dropdown-menu";++interface DomainsTableProps {+ data: DomainStats[];+}++type SortKey = "domain" | "totalDownload" | "totalUpload" | "totalConnections" | "lastSeen";+type SortOrder = "asc" | "desc";++const PAGE_SIZE_OPTIONS = [10, 20, 50, 100] as const;+type PageSize = typeof PAGE_SIZE_OPTIONS[number];++// Generate gradient based on IP+const getIPGradient = (ip: string) => {+ const colors = [+ "from-emerald-500 to-teal-400",+ "from-blue-500 to-cyan-400",+ "from-violet-500 to-purple-400",+ "from-orange-500 to-amber-400",+ "from-rose-500 to-pink-400",+ ];+ let hash = 0;+ for (let i = 0; i < ip.length; i++) {+ hash = ip.charCodeAt(i) + ((hash << 5) - hash);+ }+ return colors[Math.abs(hash) % colors.length];+};++export function DomainsTable({ data }: DomainsTableProps) {+ const t = useTranslations("domains");+ const [search, setSearch] = useState("");+ const [sortKey, setSortKey] = useState<SortKey>("totalDownload");+ const [sortOrder, setSortOrder] = useState<SortOrder>("desc");+ const [currentPage, setCurrentPage] = useState(1);+ const [pageSize, setPageSize] = useState<PageSize>(10);+ const [expandedDomain, setExpandedDomain] = useState<string | null>(null);++ const handleSort = (key: SortKey) => {+ if (sortKey === key) {+ setSortOrder(sortOrder === "asc" ? "desc" : "asc");+ } else {+ setSortKey(key);+ setSortOrder("desc");+ }+ setCurrentPage(1);+ };++ const filteredData = useMemo(() => {+ return (data || [])+ .filter((domain) =>+ domain.domain.toLowerCase().includes(search.toLowerCase())+ )+ .sort((a, b) => {+ const aValue = a[sortKey];+ const bValue = b[sortKey];+ const modifier = sortOrder === "asc" ? 1 : -1;++ if (typeof aValue === "string" && typeof bValue === "string") {+ return aValue.localeCompare(bValue) * modifier;+ }+ return ((aValue as number) - (bValue as number)) * modifier;+ });+ }, [data, search, sortKey, sortOrder]);++ // Pagination+ const totalPages = Math.ceil(filteredData.length / pageSize);+ const paginatedData = useMemo(() => {+ const start = (currentPage - 1) * pageSize;+ return filteredData.slice(start, start + pageSize);+ }, [filteredData, currentPage, pageSize]);++ const handleSearchChange = (value: string) => {+ setSearch(value);+ setCurrentPage(1);+ };++ const handlePageSizeChange = (size: PageSize) => {+ setPageSize(size);+ setCurrentPage(1);+ };++ const toggleExpand = (domain: string) => {+ setExpandedDomain(expandedDomain === domain ? null : domain);+ };++ const SortIcon = ({ column }: { column: SortKey }) => {+ if (sortKey !== column) return <ArrowUpDown className="ml-2 h-3 w-3 text-muted-foreground" />;+ return sortOrder === "asc" ? (+ <ArrowUp className="ml-2 h-3 w-3 text-primary" />+ ) : (+ <ArrowDown className="ml-2 h-3 w-3 text-primary" />+ );+ };++ // Generate page numbers to display+ const getPageNumbers = () => {+ const pages: (number | string)[] = [];+ const maxVisible = 5;++ if (totalPages <= maxVisible) {+ for (let i = 1; i <= totalPages; i++) pages.push(i);+ } else {+ if (currentPage <= 3) {+ for (let i = 1; i <= 4; i++) pages.push(i);+ pages.push('...');+ pages.push(totalPages);+ } else if (currentPage >= totalPages - 2) {+ pages.push(1);+ pages.push('...');+ for (let i = totalPages - 3; i <= totalPages; i++) pages.push(i);+ } else {+ pages.push(1);+ pages.push('...');+ for (let i = currentPage - 1; i <= currentPage + 1; i++) pages.push(i);+ pages.push('...');+ pages.push(totalPages);+ }+ }+ return pages;+ };++ return (+ <div className="glass-card rounded-2xl overflow-hidden">+ {/* Header */}+ <div className="p-5 border-b border-border/50">+ <div className="flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4">+ <div>+ <h3 className="text-lg font-semibold">{t("title")}</h3>+ <p className="text-sm text-muted-foreground">+ {filteredData.length} {t("domainsCount")}+ </p>+ </div>+ <div className="relative">+ <Search className="absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground" />+ <Input+ placeholder={t("search")}+ value={search}+ onChange={(e) => handleSearchChange(e.target.value)}+ className="pl-10 h-10 w-full sm:w-[240px] bg-secondary/50 border-0"+ />+ </div>+ </div>+ </div>++ {/* Table Header */}+ <div className="grid grid-cols-12 gap-4 px-5 py-3 bg-secondary/30 text-xs font-medium text-muted-foreground uppercase tracking-wider">+ <div+ className="col-span-4 sm:col-span-3 flex items-center cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("domain")}+ >+ {t("domain")}+ <SortIcon column="domain" />+ </div>+ <div+ className="col-span-3 sm:col-span-2 flex items-center justify-end cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("totalDownload")}+ >+ {t("download")}+ <SortIcon column="totalDownload" />+ </div>+ <div+ className="col-span-3 sm:col-span-2 flex items-center justify-end cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("totalUpload")}+ >+ {t("upload")}+ <SortIcon column="totalUpload" />+ </div>+ <div+ className="hidden sm:col-span-2 sm:flex items-center justify-end cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("totalConnections")}+ >+ {t("conn")}+ <SortIcon column="totalConnections" />+ </div>+ <div className="col-span-2 flex items-center justify-end">+ {t("ipCount")}+ </div>+ </div>++ {/* Table Body */}+ <div className="divide-y divide-border/30 min-h-[300px]">+ {paginatedData.length === 0 ? (+ <div className="px-5 py-12 text-center text-muted-foreground">+ {t("noResults")}+ </div>+ ) : (+ paginatedData.map((domain, index) => {+ const isExpanded = expandedDomain === domain.domain;++ return (+ <div key={domain.domain} className="group">+ {/* Main Row */}+ <div+ className={cn(+ "grid grid-cols-12 gap-4 px-5 py-4 items-center hover:bg-secondary/20 transition-colors cursor-pointer",+ isExpanded && "bg-secondary/10"+ )}+ style={{ animationDelay: `${index * 50}ms` }}+ onClick={() => toggleExpand(domain.domain)}+ >+ {/* Domain with Favicon */}+ <div className="col-span-4 sm:col-span-3 flex items-center gap-3 min-w-0">+ <Favicon domain={domain.domain} size="sm" />+ <div className="min-w-0">+ <p className="font-medium truncate text-sm">+ {domain.domain || t("unknown")}+ </p>+ <p className="text-xs text-muted-foreground">+ {formatDuration(domain.lastSeen)}+ </p>+ </div>+ </div>++ {/* Download */}+ <div className="col-span-3 sm:col-span-2 text-right tabular-nums text-sm">+ <span className="text-blue-500">{formatBytes(domain.totalDownload)}</span>+ </div>++ {/* Upload */}+ <div className="col-span-3 sm:col-span-2 text-right tabular-nums text-sm">+ <span className="text-purple-500">{formatBytes(domain.totalUpload)}</span>+ </div>++ {/* Connections */}+ <div className="hidden sm:col-span-2 sm:flex items-center justify-end">+ <span className="px-2.5 py-1 rounded-full bg-secondary text-xs font-medium">+ {domain.totalConnections}+ </span>+ </div>++ {/* IP Count - Clickable */}+ <div className="col-span-2 flex items-center justify-end">+ <Button+ variant="ghost"+ size="sm"+ className={cn(+ "h-7 px-2 gap-1 text-xs font-medium transition-all",+ isExpanded+ ? "bg-primary/10 text-primary hover:bg-primary/20"+ : "bg-secondary/50 text-muted-foreground hover:text-foreground hover:bg-secondary"+ )}+ onClick={(e) => {+ e.stopPropagation();+ toggleExpand(domain.domain);+ }}+ >+ <Server className="h-3 w-3" />+ {domain.ips.length}+ {isExpanded ? (+ <ChevronUp className="h-3 w-3 ml-0.5" />+ ) : (+ <ChevronDown className="h-3 w-3 ml-0.5" />+ )}+ </Button>+ </div>+ </div>++ {/* Expanded IP List */}+ {isExpanded && (+ <div className="px-5 pb-4 bg-secondary/5">+ <div className="pt-2 pb-1 px-1">+ <p className="text-xs font-medium text-muted-foreground mb-2 flex items-center gap-1.5">+ <Globe className="h-3 w-3" />+ {t("associatedIPs")}+ </p>+ <div className="flex flex-wrap gap-2">+ {domain.ips.map((ip, ipIndex) => {+ const gradient = getIPGradient(ip);+ return (+ <div+ key={ip}+ className="flex items-center gap-2 px-3 py-2 rounded-lg bg-card border border-border/50 hover:border-primary/30 hover:shadow-sm transition-all"+ >+ <div className={`w-6 h-6 rounded-md bg-gradient-to-br ${gradient} flex items-center justify-center shrink-0`}>+ <Server className="w-3 h-3 text-white" />+ </div>+ <code className="text-xs font-mono">{ip}</code>+ </div>+ );+ })}+ </div>+ </div>+ </div>+ )}+ </div>+ );+ })+ )}+ </div>++ {/* Pagination Footer */}+ {totalPages > 0 && (+ <div className="p-4 border-t border-border/50 bg-secondary/20">+ <div className="flex flex-col sm:flex-row items-center justify-between gap-4">+ {/* Page size selector */}+ <div className="flex items-center gap-2">+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button variant="ghost" size="sm" className="h-8 gap-1.5 text-muted-foreground hover:text-foreground">+ <Rows3 className="h-4 w-4" />+ <span>{pageSize} / {t("page")}</span>+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="start">+ {PAGE_SIZE_OPTIONS.map((size) => (+ <DropdownMenuItem+ key={size}+ onClick={() => handlePageSizeChange(size)}+ className={pageSize === size ? "bg-primary/10" : ""}+ >+ {size} / {t("page")}+ </DropdownMenuItem>+ ))}+ </DropdownMenuContent>+ </DropdownMenu>+ <span className="text-sm text-muted-foreground">+ {t("total")} {filteredData.length}+ </span>+ </div>++ {/* Pagination info and controls */}+ <div className="flex items-center gap-3">+ <p className="text-sm text-muted-foreground">+ {t("showing")} {(currentPage - 1) * pageSize + 1} - {Math.min(currentPage * pageSize, filteredData.length)} {t("of")} {filteredData.length}+ </p>++ <div className="flex items-center gap-1">+ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => setCurrentPage(p => Math.max(1, p - 1))}+ disabled={currentPage === 1}+ >+ <ChevronLeft className="h-4 w-4" />+ </Button>++ {getPageNumbers().map((page, idx) => (+ page === '...' ? (+ <span key={`ellipsis-${idx}`} className="px-2 text-muted-foreground">...</span>+ ) : (+ <Button+ key={page}+ variant={currentPage === page ? "default" : "ghost"}+ size="sm"+ className="h-8 w-8 px-0 text-xs"+ onClick={() => setCurrentPage(page as number)}+ >+ {page}+ </Button>+ )+ ))}++ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => setCurrentPage(p => Math.min(totalPages, p + 1))}+ disabled={currentPage === totalPages}+ >+ <ChevronRight className="h-4 w-4" />+ </Button>+ </div>+ </div>+ </div>+ </div>+ )}+ </div>+ );+}diff --git a/apps/web/components/favicon.tsx b/apps/web/components/favicon.tsxnew file mode 100644index 0000000..262a8f6--- /dev/null+++ b/apps/web/components/favicon.tsx@@ -0,0 +1,144 @@+"use client";++import { useState } from "react";+import { Globe } from "lucide-react";+import { cn } from "@/lib/utils";++interface FaviconProps {+ domain: string;+ size?: "sm" | "md" | "lg";+ className?: string;+}++const sizeMap = {+ sm: "w-5 h-5",+ md: "w-8 h-8",+ lg: "w-12 h-12",+};++const iconSizeMap = {+ sm: "w-3 h-3",+ md: "w-4 h-4",+ lg: "w-6 h-6",+};++export function Favicon({ domain, size = "md", className }: FaviconProps) {+ const [error, setError] = useState(false);+ const [loading, setLoading] = useState(true);++ // Clean domain (remove protocol, path, etc.)+ const cleanDomain = domain+ .replace(/^https?:\/\//, "")+ .replace(/^www\./, "")+ .split("/")[0];++ // Use Google's favicon service+ const faviconUrl = `https://www.google.com/s2/favicons?domain=${encodeURIComponent(+ cleanDomain+ )}&sz=128`;++ // Generate gradient background based on domain+ const getGradient = (domain: string) => {+ const colors = [+ ["from-blue-500", "to-cyan-400"],+ ["from-purple-500", "to-pink-400"],+ ["from-emerald-500", "to-teal-400"],+ ["from-orange-500", "to-amber-400"],+ ["from-rose-500", "to-red-400"],+ ["from-indigo-500", "to-violet-400"],+ ];+ let hash = 0;+ for (let i = 0; i < domain.length; i++) {+ hash = domain.charCodeAt(i) + ((hash << 5) - hash);+ }+ return colors[Math.abs(hash) % colors.length];+ };++ const gradient = getGradient(cleanDomain);++ if (error || !cleanDomain) {+ return (+ <div+ className={cn(+ "rounded-lg flex items-center justify-center bg-gradient-to-br",+ gradient,+ sizeMap[size],+ className+ )}+ >+ <Globe className={cn("text-white/90", iconSizeMap[size])} />+ </div>+ );+ }++ return (+ <div+ className={cn(+ "rounded-lg overflow-hidden bg-slate-800/50 flex items-center justify-center relative",+ sizeMap[size],+ className+ )}+ >+ {loading && (+ <div+ className={cn(+ "absolute inset-0 bg-gradient-to-br",+ gradient+ )}+ />+ )}+ <img+ src={faviconUrl}+ alt={cleanDomain}+ className={cn(+ "w-full h-full object-contain p-0.5",+ loading ? "opacity-0" : "opacity-100"+ )}+ onError={() => setError(true)}+ onLoad={() => setLoading(false)}+ />+ </div>+ );+}++// Fallback component for when favicon fails+export function DomainInitial({ domain, size = "md", className }: FaviconProps) {+ const cleanDomain = domain+ .replace(/^https?:\/\//, "")+ .replace(/^www\./, "")+ .split("/")[0];++ const initial = cleanDomain.charAt(0).toUpperCase();++ const getGradient = (domain: string) => {+ const colors = [+ ["from-blue-500", "to-cyan-400"],+ ["from-purple-500", "to-pink-400"],+ ["from-emerald-500", "to-teal-400"],+ ["from-orange-500", "to-amber-400"],+ ["from-rose-500", "to-red-400"],+ ["from-indigo-500", "to-violet-400"],+ ];+ let hash = 0;+ for (let i = 0; i < domain.length; i++) {+ hash = domain.charCodeAt(i) + ((hash << 5) - hash);+ }+ return colors[Math.abs(hash) % colors.length];+ };++ const gradient = getGradient(cleanDomain);++ return (+ <div+ className={cn(+ "rounded-lg flex items-center justify-center bg-gradient-to-br font-semibold text-white",+ gradient,+ sizeMap[size],+ size === "sm" ? "text-xs" : size === "lg" ? "text-xl" : "text-sm",+ className+ )}+ >+ {initial}+ </div>+ );+}diff --git a/apps/web/components/header.tsx b/apps/web/components/header.tsxnew file mode 100644index 0000000..2ee5c3c--- /dev/null+++ b/apps/web/components/header.tsx@@ -0,0 +1,71 @@+"use client";++import { Activity, Wifi, WifiOff } from "lucide-react";+import { useTranslations } from "next-intl";+import { ThemeToggle } from "./theme-toggle";+import { LanguageSwitcher } from "./language-switcher";+import { TimeRangePicker } from "./time-range-picker";+import type { TimeRange } from "@/lib/api";++interface HeaderProps {+ isConnected: boolean;+ timeRange?: TimeRange;+ onTimeRangeChange?: (range: TimeRange) => void;+}++export function Header({+ isConnected,+ timeRange,+ onTimeRangeChange,+}: HeaderProps) {+ const t = useTranslations("header");++ return (+ <header className="sticky top-0 z-50 w-full border-b border-border/40 bg-background/80 backdrop-blur-md supports-[backdrop-filter]:bg-background/60">+ <div className="flex h-14 max-w-7xl mx-auto items-center justify-between px-4 md:px-6">+ {/* Left: Logo + Connection Status */}+ <div className="flex items-center gap-3">+ <div className="relative flex items-center justify-center">+ <Activity className="h-6 w-6 text-primary" />+ {isConnected ? (+ <span className="absolute -right-0.5 -top-0.5 flex h-2.5 w-2.5">+ <span className="absolute inline-flex h-full w-full animate-ping rounded-full bg-emerald-400 opacity-75"></span>+ <span className="relative inline-flex h-2.5 w-2.5 rounded-full bg-emerald-500"></span>+ </span>+ ) : (+ <span className="absolute -right-0.5 -top-0.5 flex h-2.5 w-2.5 rounded-full bg-red-500"></span>+ )}+ </div>+ <div className="flex flex-col">+ <h1 className="text-lg font-semibold tracking-tight leading-none">{t("title")}</h1>+ <div className="flex items-center gap-1 mt-0.5">+ {isConnected ? (+ <>+ <Wifi className="w-3 h-3 text-emerald-500" />+ <span className="text-[10px] text-emerald-500 font-medium">已连接</span>+ </>+ ) : (+ <>+ <WifiOff className="w-3 h-3 text-red-500" />+ <span className="text-[10px] text-red-500 font-medium">未连接</span>+ </>+ )}+ </div>+ </div>+ </div>++ {/* Right: Controls */}+ <div className="flex items-center gap-2">+ {timeRange && onTimeRangeChange && (+ <TimeRangePicker+ value={timeRange}+ onChange={(range) => onTimeRangeChange(range)}+ />+ )}+ <LanguageSwitcher />+ <ThemeToggle />+ </div>+ </div>+ </header>+ );+}diff --git a/apps/web/components/ips-table.tsx b/apps/web/components/ips-table.tsxnew file mode 100644index 0000000..115840e--- /dev/null+++ b/apps/web/components/ips-table.tsx@@ -0,0 +1,402 @@+"use client";++import { useState, useMemo } from "react";+import { Search, ArrowUpDown, ArrowDown, ArrowUp, ChevronLeft, ChevronRight, Rows3, Globe, Server, ChevronDown, ChevronUp, Link2 } from "lucide-react";+import { useTranslations } from "next-intl";+import { Input } from "@/components/ui/input";+import { Button } from "@/components/ui/button";+import { formatBytes } from "@/lib/utils";+import { cn } from "@/lib/utils";+import type { IPStats } from "@clashstats/shared";+import {+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuItem,+ DropdownMenuTrigger,+} from "@/components/ui/dropdown-menu";++interface IPsTableProps {+ data: IPStats[];+}++type SortKey = "ip" | "totalDownload" | "totalUpload" | "totalConnections" | "lastSeen";+type SortOrder = "asc" | "desc";++const PAGE_SIZE_OPTIONS = [10, 20, 50, 100] as const;+type PageSize = typeof PAGE_SIZE_OPTIONS[number];++// Color palette for IP icons - solid colors that work in both light/dark modes+const IP_COLORS = [+ { bg: "bg-blue-500", text: "text-white" },+ { bg: "bg-violet-500", text: "text-white" },+ { bg: "bg-emerald-500", text: "text-white" },+ { bg: "bg-amber-500", text: "text-white" },+ { bg: "bg-rose-500", text: "text-white" },+ { bg: "bg-cyan-500", text: "text-white" },+ { bg: "bg-indigo-500", text: "text-white" },+ { bg: "bg-teal-500", text: "text-white" },+];++// Get color for IP+const getIPColor = (ip: string) => {+ let hash = 0;+ for (let i = 0; i < ip.length; i++) {+ hash = ip.charCodeAt(i) + ((hash << 5) - hash);+ }+ return IP_COLORS[Math.abs(hash) % IP_COLORS.length];+};++// Get color for domain+const getDomainColor = (domain: string) => {+ let hash = 0;+ for (let i = 0; i < domain.length; i++) {+ hash = domain.charCodeAt(i) + ((hash << 5) - hash);+ }+ return IP_COLORS[Math.abs(hash) % IP_COLORS.length];+};++export function IPsTable({ data }: IPsTableProps) {+ const t = useTranslations("ips");+ const [search, setSearch] = useState("");+ const [sortKey, setSortKey] = useState<SortKey>("totalDownload");+ const [sortOrder, setSortOrder] = useState<SortOrder>("desc");+ const [currentPage, setCurrentPage] = useState(1);+ const [pageSize, setPageSize] = useState<PageSize>(10);+ const [expandedIP, setExpandedIP] = useState<string | null>(null);++ const handleSort = (key: SortKey) => {+ if (sortKey === key) {+ setSortOrder(sortOrder === "asc" ? "desc" : "asc");+ } else {+ setSortKey(key);+ setSortOrder("desc");+ }+ setCurrentPage(1);+ };++ const filteredData = useMemo(() => {+ return (data || [])+ .filter((ip) =>+ ip.ip.toLowerCase().includes(search.toLowerCase()) ||+ ip.domains.some((d) => d.toLowerCase().includes(search.toLowerCase()))+ )+ .sort((a, b) => {+ const aValue = a[sortKey];+ const bValue = b[sortKey];+ const modifier = sortOrder === "asc" ? 1 : -1;++ if (typeof aValue === "string" && typeof bValue === "string") {+ return aValue.localeCompare(bValue) * modifier;+ }+ return ((aValue as number) - (bValue as number)) * modifier;+ });+ }, [data, search, sortKey, sortOrder]);++ // Pagination+ const totalPages = Math.ceil(filteredData.length / pageSize);+ const paginatedData = useMemo(() => {+ const start = (currentPage - 1) * pageSize;+ return filteredData.slice(start, start + pageSize);+ }, [filteredData, currentPage, pageSize]);++ const handleSearchChange = (value: string) => {+ setSearch(value);+ setCurrentPage(1);+ };++ const handlePageSizeChange = (size: PageSize) => {+ setPageSize(size);+ setCurrentPage(1);+ };++ const toggleExpand = (ip: string) => {+ setExpandedIP(expandedIP === ip ? null : ip);+ };++ const SortIcon = ({ column }: { column: SortKey }) => {+ if (sortKey !== column) return <ArrowUpDown className="ml-2 h-3 w-3 text-muted-foreground" />;+ return sortOrder === "asc" ? (+ <ArrowUp className="ml-2 h-3 w-3 text-primary" />+ ) : (+ <ArrowDown className="ml-2 h-3 w-3 text-primary" />+ );+ };++ // Generate page numbers to display+ const getPageNumbers = () => {+ const pages: (number | string)[] = [];+ const maxVisible = 5;++ if (totalPages <= maxVisible) {+ for (let i = 1; i <= totalPages; i++) pages.push(i);+ } else {+ if (currentPage <= 3) {+ for (let i = 1; i <= 4; i++) pages.push(i);+ pages.push('...');+ pages.push(totalPages);+ } else if (currentPage >= totalPages - 2) {+ pages.push(1);+ pages.push('...');+ for (let i = totalPages - 3; i <= totalPages; i++) pages.push(i);+ } else {+ pages.push(1);+ pages.push('...');+ for (let i = currentPage - 1; i <= currentPage + 1; i++) pages.push(i);+ pages.push('...');+ pages.push(totalPages);+ }+ }+ return pages;+ };++ return (+ <div className="glass-card rounded-2xl overflow-hidden">+ {/* Header */}+ <div className="p-5 border-b border-border/50">+ <div className="flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4">+ <div>+ <h3 className="text-lg font-semibold">{t("title")}</h3>+ <p className="text-sm text-muted-foreground">{t("topIPsByTraffic")}</p>+ </div>+ <div className="relative">+ <Search className="absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground" />+ <Input+ placeholder={t("search")}+ value={search}+ onChange={(e) => handleSearchChange(e.target.value)}+ className="pl-10 h-10 w-full sm:w-[240px] bg-secondary/50 border-0"+ />+ </div>+ </div>+ </div>++ {/* Table Header */}+ <div className="grid grid-cols-12 gap-4 px-5 py-3 bg-secondary/30 text-xs font-medium text-muted-foreground uppercase tracking-wider">+ <div+ className="col-span-4 sm:col-span-3 flex items-center cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("ip")}+ >+ {t("ipAddress")}+ <SortIcon column="ip" />+ </div>+ <div className="col-span-2 flex items-center">+ {t("location")}+ </div>+ <div+ className="col-span-3 sm:col-span-2 flex items-center justify-end cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("totalDownload")}+ >+ {t("download")}+ <SortIcon column="totalDownload" />+ </div>+ <div+ className="col-span-3 sm:col-span-2 flex items-center justify-end cursor-pointer hover:text-foreground transition-colors"+ onClick={() => handleSort("totalUpload")}+ >+ {t("upload")}+ <SortIcon column="totalUpload" />+ </div>+ <div className="hidden sm:col-span-2 sm:flex items-center justify-end">+ {t("domainCount")}+ </div>+ </div>++ {/* Table Body */}+ <div className="divide-y divide-border/30 min-h-[300px]">+ {paginatedData.length === 0 ? (+ <div className="px-5 py-12 text-center text-muted-foreground">+ {t("noResults")}+ </div>+ ) : (+ paginatedData.map((ip, index) => {+ const ipColor = getIPColor(ip.ip);+ const isExpanded = expandedIP === ip.ip;++ return (+ <div key={ip.ip} className="group">+ {/* Main Row */}+ <div+ className={cn(+ "grid grid-cols-12 gap-4 px-5 py-4 items-center hover:bg-secondary/20 transition-colors cursor-pointer",+ isExpanded && "bg-secondary/10"+ )}+ style={{ animationDelay: `${index * 50}ms` }}+ onClick={() => toggleExpand(ip.ip)}+ >+ {/* IP with Icon */}+ <div className="col-span-4 sm:col-span-3 flex items-center gap-3 min-w-0">+ <div className={`w-8 h-8 rounded-lg ${ipColor.bg} ${ipColor.text} flex items-center justify-center shrink-0`}>+ <Server className="w-4 h-4" />+ </div>+ <div className="min-w-0">+ <code className="text-sm font-medium truncate block">{ip.ip}</code>+ {ip.asn && (+ <p className="text-xs text-muted-foreground truncate max-w-[150px]">+ {ip.asn}+ </p>+ )}+ </div>+ </div>++ {/* Location */}+ <div className="col-span-2 flex items-center">+ {ip.geoIP && ip.geoIP.length > 0 ? (+ <div className="flex items-center gap-1.5">+ <Globe className="w-3 h-3 text-muted-foreground" />+ <span className="text-xs truncate">{ip.geoIP[0]}</span>+ </div>+ ) : (+ <span className="text-xs text-muted-foreground">-</span>+ )}+ </div>++ {/* Download */}+ <div className="col-span-3 sm:col-span-2 text-right tabular-nums text-sm">+ <span className="text-blue-500">{formatBytes(ip.totalDownload)}</span>+ </div>++ {/* Upload */}+ <div className="col-span-3 sm:col-span-2 text-right tabular-nums text-sm">+ <span className="text-purple-500">{formatBytes(ip.totalUpload)}</span>+ </div>++ {/* Domains Count - Clickable */}+ <div className="hidden sm:col-span-2 sm:flex items-center justify-end">+ <Button+ variant="ghost"+ size="sm"+ className={cn(+ "h-7 px-2 gap-1 text-xs font-medium transition-all",+ isExpanded+ ? "bg-primary/10 text-primary hover:bg-primary/20"+ : "bg-secondary/50 text-muted-foreground hover:text-foreground hover:bg-secondary"+ )}+ onClick={(e) => {+ e.stopPropagation();+ toggleExpand(ip.ip);+ }}+ >+ <Link2 className="h-3 w-3" />+ {ip.domains.length}+ {isExpanded ? (+ <ChevronUp className="h-3 w-3 ml-0.5" />+ ) : (+ <ChevronDown className="h-3 w-3 ml-0.5" />+ )}+ </Button>+ </div>+ </div>++ {/* Expanded Domains List */}+ {isExpanded && (+ <div className="px-5 pb-4 bg-secondary/5">+ <div className="pt-2 pb-1 px-1">+ <p className="text-xs font-medium text-muted-foreground mb-2 flex items-center gap-1.5">+ <Link2 className="h-3 w-3" />+ {t("associatedDomains")}+ </p>+ <div className="flex flex-wrap gap-2">+ {ip.domains.map((domain) => {+ const domainColor = getDomainColor(domain);+ return (+ <div+ key={domain}+ className="flex items-center gap-2 px-3 py-2 rounded-lg bg-card border border-border/50 hover:border-primary/30 hover:shadow-sm transition-all"+ >+ <div className={`w-6 h-6 rounded-md ${domainColor.bg} ${domainColor.text} flex items-center justify-center shrink-0`}>+ <Globe className="w-3 h-3" />+ </div>+ <span className="text-xs font-medium truncate max-w-[200px]">{domain}</span>+ </div>+ );+ })}+ </div>+ </div>+ </div>+ )}+ </div>+ );+ })+ )}+ </div>++ {/* Pagination Footer */}+ {totalPages > 0 && (+ <div className="p-4 border-t border-border/50 bg-secondary/20">+ <div className="flex flex-col sm:flex-row items-center justify-between gap-4">+ {/* Page size selector */}+ <div className="flex items-center gap-2">+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button variant="ghost" size="sm" className="h-8 gap-1.5 text-muted-foreground hover:text-foreground">+ <Rows3 className="h-4 w-4" />+ <span>{pageSize} / {t("page")}</span>+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="start">+ {PAGE_SIZE_OPTIONS.map((size) => (+ <DropdownMenuItem+ key={size}+ onClick={() => handlePageSizeChange(size)}+ className={pageSize === size ? "bg-primary/10" : ""}+ >+ {size} / {t("page")}+ </DropdownMenuItem>+ ))}+ </DropdownMenuContent>+ </DropdownMenu>+ <span className="text-sm text-muted-foreground">+ {t("total")} {filteredData.length}+ </span>+ </div>++ {/* Pagination info and controls */}+ <div className="flex items-center gap-3">+ <p className="text-sm text-muted-foreground">+ {t("showing")} {(currentPage - 1) * pageSize + 1} - {Math.min(currentPage * pageSize, filteredData.length)} {t("of")} {filteredData.length}+ </p>++ <div className="flex items-center gap-1">+ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => setCurrentPage(p => Math.max(1, p - 1))}+ disabled={currentPage === 1}+ >+ <ChevronLeft className="h-4 w-4" />+ </Button>++ {getPageNumbers().map((page, idx) => (+ page === '...' ? (+ <span key={`ellipsis-${idx}`} className="px-2 text-muted-foreground">...</span>+ ) : (+ <Button+ key={page}+ variant={currentPage === page ? "default" : "ghost"}+ size="sm"+ className="h-8 w-8 px-0 text-xs"+ onClick={() => setCurrentPage(page as number)}+ >+ {page}+ </Button>+ )+ ))}++ <Button+ variant="ghost"+ size="icon"+ className="h-8 w-8"+ onClick={() => setCurrentPage(p => Math.min(totalPages, p + 1))}+ disabled={currentPage === totalPages}+ >+ <ChevronRight className="h-4 w-4" />+ </Button>+ </div>+ </div>+ </div>+ </div>+ )}+ </div>+ );+}diff --git a/apps/web/components/language-switcher.tsx b/apps/web/components/language-switcher.tsxnew file mode 100644index 0000000..78d25b0--- /dev/null+++ b/apps/web/components/language-switcher.tsx@@ -0,0 +1,54 @@+"use client";++import { useRouter, usePathname } from "next/navigation";+import { useLocale, useTranslations } from "next-intl";+import { Globe } from "lucide-react";+import { Button } from "@/components/ui/button";+import {+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuItem,+ DropdownMenuTrigger,+} from "@/components/ui/dropdown-menu";++const locales = ["en", "zh"] as const;+type Locale = (typeof locales)[number];++const localeLabels: Record<Locale, string> = {+ en: "English",+ zh: "中文",+};++export function LanguageSwitcher() {+ const router = useRouter();+ const pathname = usePathname();+ const currentLocale = useLocale() as Locale;+ const t = useTranslations("language");++ const handleLocaleChange = (newLocale: Locale) => {+ const newPathname = pathname.replace(`/${currentLocale}`, `/${newLocale}`);+ router.push(newPathname);+ };++ return (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button variant="ghost" size="icon" className="h-9 w-9 rounded-full">+ <Globe className="h-4 w-4" />+ <span className="sr-only">{t("select")}</span>+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="end" className="glass-card">+ {locales.map((locale) => (+ <DropdownMenuItem+ key={locale}+ onClick={() => handleLocaleChange(locale)}+ className={currentLocale === locale ? "bg-muted" : ""}+ >+ {localeLabels[locale]}+ </DropdownMenuItem>+ ))}+ </DropdownMenuContent>+ </DropdownMenu>+ );+}diff --git a/apps/web/components/navigation.tsx b/apps/web/components/navigation.tsxnew file mode 100644index 0000000..74c3907--- /dev/null+++ b/apps/web/components/navigation.tsx@@ -0,0 +1,196 @@+"use client";++import { useState } from "react";+import { useTranslations } from "next-intl";+import Image from "next/image";+import {+ LayoutDashboard,+ Globe,+ MapPin,+ Server,+ Route,+ Network,+ Settings,+ Menu,+ X,+} from "lucide-react";+import { cn } from "@/lib/utils";+import { Button } from "@/components/ui/button";+import { BackendConfigDialog } from "./backend-config-dialog";++interface NavigationProps {+ activeTab: string;+ onTabChange: (tab: string) => void;+}++const NAV_ITEMS = [+ { id: "overview", icon: LayoutDashboard },+ { id: "domains", icon: Globe },+ { id: "countries", icon: MapPin },+ { id: "proxies", icon: Server },+ { id: "rules", icon: Route },+ { id: "network", icon: Network },+];++export function Navigation({ activeTab, onTabChange }: NavigationProps) {+ const [mobileMenuOpen, setMobileMenuOpen] = useState(false);+ const [settingsOpen, setSettingsOpen] = useState(false);+ const t = useTranslations("nav");+ const headerT = useTranslations("header");+ const backendT = useTranslations("backend");++ return (+ <>+ {/* Desktop Navigation - Sidebar */}+ <aside className="hidden lg:flex flex-col w-64 h-screen sticky top-0 border-r border-border/40 bg-background/80 backdrop-blur-md">+ {/* Logo */}+ <div className="flex items-center gap-3 p-6 border-b border-border/40">+ <div className="w-10 h-10 rounded-xl bg-primary/10 flex items-center justify-center overflow-hidden">+ <Image+ src="/clash-master.png"+ alt="Clash Master"+ width={40}+ height={40}+ className="w-full h-full object-cover"+ />+ </div>+ <div>+ <h1 className="font-bold text-lg">{headerT("title")}</h1>+ <p className="text-xs text-muted-foreground">{headerT("subtitle")}</p>+ </div>+ </div>++ {/* Nav Items */}+ <nav className="flex-1 p-4 space-y-1">+ {NAV_ITEMS.map((item) => {+ const Icon = item.icon;+ const isActive = activeTab === item.id;+ return (+ <button+ key={item.id}+ onClick={() => onTabChange(item.id)}+ className={cn(+ "w-full flex items-center gap-3 px-4 py-3 rounded-xl text-sm font-medium transition-all",+ isActive+ ? "bg-primary text-primary-foreground shadow-sm"+ : "text-muted-foreground hover:bg-secondary hover:text-foreground"+ )}+ >+ <Icon className="w-5 h-5" />+ {t(item.id)}+ </button>+ );+ })}+ </nav>++ {/* Bottom Actions */}+ <div className="p-4 border-t border-border/40">+ <button+ onClick={() => setSettingsOpen(true)}+ className={cn(+ "w-full flex items-center gap-3 px-4 py-3 rounded-xl text-sm font-medium transition-all",+ "text-muted-foreground hover:bg-secondary hover:text-foreground"+ )}+ >+ <Settings className="w-5 h-5" />+ {backendT("title")}+ </button>+ </div>+ </aside>++ {/* Mobile Navigation - Header */}+ <header className="lg:hidden fixed top-0 left-0 right-0 z-50 border-b border-border/40 bg-background/80 backdrop-blur-md">+ <div className="flex items-center justify-between h-14 px-4">+ <div className="flex items-center gap-3">+ <div className="w-8 h-8 rounded-lg bg-primary/10 flex items-center justify-center overflow-hidden">+ <Image+ src="/clash-master.png"+ alt="Clash Master"+ width={32}+ height={32}+ className="w-full h-full object-cover"+ />+ </div>+ <h1 className="font-bold">{headerT("title")}</h1>+ </div>+ <div className="flex items-center gap-2">+ <Button+ variant="ghost"+ size="icon"+ onClick={() => setSettingsOpen(true)}+ >+ <Settings className="w-5 h-5" />+ </Button>+ <Button+ variant="ghost"+ size="icon"+ onClick={() => setMobileMenuOpen(!mobileMenuOpen)}+ >+ {mobileMenuOpen ? <X className="w-5 h-5" /> : <Menu className="w-5 h-5" />}+ </Button>+ </div>+ </div>++ {/* Mobile Menu */}+ {mobileMenuOpen && (+ <nav className="absolute top-full left-0 right-0 bg-background border-b border-border/40 p-4 space-y-1">+ {NAV_ITEMS.map((item) => {+ const Icon = item.icon;+ const isActive = activeTab === item.id;+ return (+ <button+ key={item.id}+ onClick={() => {+ onTabChange(item.id);+ setMobileMenuOpen(false);+ }}+ className={cn(+ "w-full flex items-center gap-3 px-4 py-3 rounded-xl text-sm font-medium transition-all",+ isActive+ ? "bg-primary text-primary-foreground"+ : "text-muted-foreground hover:bg-secondary"+ )}+ >+ <Icon className="w-5 h-5" />+ {t(item.id)}+ </button>+ );+ })}+ </nav>+ )}+ </header>++ {/* Mobile Bottom Navigation */}+ <nav className="lg:hidden fixed bottom-0 left-0 right-0 z-50 border-t border-border/40 bg-background/80 backdrop-blur-md">+ <div className="flex items-center justify-around h-16 px-2">+ {NAV_ITEMS.slice(0, 5).map((item) => {+ const Icon = item.icon;+ const isActive = activeTab === item.id;+ return (+ <button+ key={item.id}+ onClick={() => onTabChange(item.id)}+ className={cn(+ "flex flex-col items-center gap-1 px-3 py-2 rounded-lg transition-all",+ isActive+ ? "text-primary"+ : "text-muted-foreground"+ )}+ >+ <Icon className={cn("w-5 h-5", isActive && "scale-110")} />+ <span className="text-[10px]">{t(item.id)}</span>+ </button>+ );+ })}+ </div>+ </nav>++ {/* Settings Dialog */}+ <BackendConfigDialog+ open={settingsOpen}+ onOpenChange={setSettingsOpen}+ isFirstTime={false}+ />+ </>+ );+}diff --git a/apps/web/components/overview-card.tsx b/apps/web/components/overview-card.tsxnew file mode 100644index 0000000..900d3e5--- /dev/null+++ b/apps/web/components/overview-card.tsx@@ -0,0 +1,44 @@+"use client";++import { ReactNode } from "react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";++interface OverviewCardProps {+ title: string;+ icon: ReactNode;+ children: ReactNode;+ action?: ReactNode;+ footer?: ReactNode;+}++export function OverviewCard({+ title,+ icon,+ children,+ action,+ footer+}: OverviewCardProps) {+ return (+ <Card className="flex flex-col h-full overflow-hidden border-border/50 bg-gradient-to-b from-card to-card/50">+ <CardHeader className="pb-3 space-y-0 flex-shrink-0">+ <div className="flex items-center justify-between">+ <CardTitle className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ {icon}+ {title}+ </CardTitle>+ {action && <div className="flex items-center">{action}</div>}+ </div>+ </CardHeader>+ <CardContent className="flex-1 flex flex-col pt-0">+ <div className="flex-1">+ {children}+ </div>+ {footer && (+ <div className="mt-auto pt-4 border-t border-border/30">+ {footer}+ </div>+ )}+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/overview/index.tsx b/apps/web/components/overview/index.tsxnew file mode 100644index 0000000..da94200--- /dev/null+++ b/apps/web/components/overview/index.tsx@@ -0,0 +1,150 @@+"use client";++import { useState, useEffect, useCallback, useRef, useTransition } from "react";+import { TopDomainsSimple } from "./top-domains-simple";+import { TopProxiesSimple } from "./top-proxies-simple";+import { TopCountriesSimple } from "./top-countries-simple";+import { TrafficTrendChart } from "@/components/traffic-trend-chart";+import { api } from "@/lib/api";+import type { DomainStats, ProxyStats, CountryStats, TrafficTrendPoint } from "@clashstats/shared";++type TrendTimeRange = "30m" | "1h" | "24h";++interface OverviewTabProps {+ domains: DomainStats[];+ proxies: ProxyStats[];+ countries: CountryStats[];+ activeBackendId?: number;+}++// Cache for trend data: key = `${backendId}-${timeRange}`+const trendDataCache = new Map<string, TrafficTrendPoint[]>();++export function OverviewTab({ domains, proxies, countries, activeBackendId }: OverviewTabProps) {+ const [domainSort, setDomainSort] = useState<"traffic" | "connections">("traffic");+ const [proxySort, setProxySort] = useState<"traffic" | "connections">("traffic");++ // Traffic trend state+ const [trendData, setTrendData] = useState<TrafficTrendPoint[]>([]);+ const [trendTimeRange, setTrendTimeRange] = useState<TrendTimeRange>("1h");+ const [trendLoading, setTrendLoading] = useState(false);+ const [isPending, startTransition] = useTransition();+ const initialLoadedRef = useRef(false);+ const abortControllerRef = useRef<AbortController | null>(null);++ // Load traffic trend data with caching+ const loadTrendData = useCallback(async (showLoading = false) => {+ if (!activeBackendId) return;++ const cacheKey = `${activeBackendId}-${trendTimeRange}`;++ // Check cache first+ const cached = trendDataCache.get(cacheKey);+ if (cached) {+ startTransition(() => {+ setTrendData(cached);+ });+ // Still fetch fresh data in background+ }++ if (showLoading && !cached) setTrendLoading(true);++ // Cancel previous request+ if (abortControllerRef.current) {+ abortControllerRef.current.abort();+ }+ abortControllerRef.current = new AbortController();++ try {+ let data: TrafficTrendPoint[];++ // Use aggregated API for large time ranges to reduce data volume+ if (trendTimeRange === "24h") {+ // For 24h, aggregate by 10-minute buckets+ data = await api.getTrafficTrendAggregated(activeBackendId, 1440, 10);+ } else if (trendTimeRange === "1h") {+ // For 1h, aggregate by 2-minute buckets+ data = await api.getTrafficTrendAggregated(activeBackendId, 60, 2);+ } else {+ // For 30m, use raw data (1-minute buckets)+ data = await api.getTrafficTrendAggregated(activeBackendId, 30, 1);+ }++ // Update cache+ trendDataCache.set(cacheKey, data);++ // Update state with transition to avoid blocking UI+ startTransition(() => {+ setTrendData(data);+ });+ } catch (error) {+ if ((error as Error).name !== 'AbortError') {+ console.error("Failed to load traffic trend:", error);+ }+ } finally {+ setTrendLoading(false);+ }+ }, [trendTimeRange, activeBackendId]);++ // Initial load+ useEffect(() => {+ if (!initialLoadedRef.current && activeBackendId) {+ loadTrendData(true);+ initialLoadedRef.current = true;+ }+ }, [loadTrendData, activeBackendId]);++ // Reload when time range or backend changes+ useEffect(() => {+ if (initialLoadedRef.current && activeBackendId) {+ loadTrendData(true);+ }+ }, [trendTimeRange, activeBackendId, loadTrendData]);++ // Cleanup on unmount+ useEffect(() => {+ return () => {+ if (abortControllerRef.current) {+ abortControllerRef.current.abort();+ }+ };+ }, []);++ // Handle time range change with transition+ const handleTimeRangeChange = (range: TrendTimeRange) => {+ startTransition(() => {+ setTrendTimeRange(range);+ });+ };++ return (+ <div className="space-y-6">+ {/* Traffic Trend Chart - Full width */}+ <TrafficTrendChart+ data={trendData}+ timeRange={trendTimeRange}+ onTimeRangeChange={handleTimeRangeChange}+ isLoading={trendLoading || isPending}+ />++ <div className="grid grid-cols-1 lg:grid-cols-3 gap-6">+ {/* Top Domains */}+ <TopDomainsSimple+ domains={domains}+ sortBy={domainSort}+ onSortChange={setDomainSort}+ />++ {/* Top Proxies */}+ <TopProxiesSimple+ proxies={proxies}+ sortBy={proxySort}+ onSortChange={setProxySort}+ />++ {/* Top Countries */}+ <TopCountriesSimple countries={countries} />+ </div>+ </div>+ );+}diff --git a/apps/web/components/overview/top-countries-simple.tsx b/apps/web/components/overview/top-countries-simple.tsxnew file mode 100644index 0000000..5d06d57--- /dev/null+++ b/apps/web/components/overview/top-countries-simple.tsx@@ -0,0 +1,153 @@+"use client";++import React, { useMemo } from "react";+import { Globe, ArrowRight } from "lucide-react";+import { useTranslations } from "next-intl";+import { Button } from "@/components/ui/button";+import { formatBytes, cn } from "@/lib/utils";+import type { CountryStats } from "@clashstats/shared";++interface TopCountriesSimpleProps {+ countries: CountryStats[];+}++// Country code to flag emoji mapping+const countryFlags: Record<string, string> = {+ "CN": "🇨🇳", "US": "🇺🇸", "JP": "🇯🇵", "HK": "🇭🇰", "TW": "🇹🇼",+ "SG": "🇸🇬", "KR": "🇰🇷", "DE": "🇩🇪", "GB": "🇬🇧", "FR": "🇫🇷",+ "NL": "🇳🇱", "CA": "🇨🇦", "AU": "🇦🇺", "IN": "🇮🇳", "RU": "🇷🇺",+ "BR": "🇧🇷", "TR": "🇹🇷", "VN": "🇻🇳", "TH": "🇹🇭", "ID": "🇮🇩",+ "MY": "🇲🇾", "PH": "🇵🇭", "SE": "🇸🇪", "CH": "🇨🇭", "IT": "🇮🇹",+ "ES": "🇪🇸", "PT": "🇵🇹", "PL": "🇵🇱", "UA": "🇺🇦", "MX": "🇲🇽",+ "AR": "🇦🇷", "CL": "🇨🇱", "CO": "🇨🇴", "ZA": "🇿🇦", "EG": "🇪🇬",+ "AE": "🇦🇪", "SA": "🇸🇦", "IL": "🇮🇱", "FI": "🇫🇮", "NO": "🇳🇴",+ "DK": "🇩🇰", "AT": "🇦🇹", "BE": "🇧🇪", "CZ": "🇨🇿", "HU": "🇭🇺",+ "RO": "🇷🇴", "BG": "🇧🇬", "HR": "🇭🇷", "RS": "🇷🇸", "SK": "🇸🇰",+ "SI": "🇸🇮", "LT": "🇱🇹", "LV": "🇱🇻", "EE": "🇪🇪", "IE": "🇮🇪",+ "NZ": "🇳🇿", "BD": "🇧🇩", "PK": "🇵🇰", "LK": "🇱🇰", "NP": "🇳🇵",+ "MM": "🇲🇲", "KH": "🇰🇭", "LA": "🇱🇦", "MN": "🇲🇳", "KZ": "🇰🇿",+ "UZ": "🇺🇿", "AZ": "🇦🇿", "GE": "🇬🇪", "AM": "🇦🇲", "MD": "🇲🇩",+ "BY": "🇧🇾", "KG": "🇰🇬", "TJ": "🇹🇯", "TM": "🇹🇲", "AF": "🇦🇫",+ "IQ": "🇮🇶", "IR": "🇮🇷", "JO": "🇯🇴", "LB": "🇱🇧", "SY": "🇸🇾",+ "YE": "🇾🇪", "OM": "🇴🇲", "QA": "🇶🇦", "BH": "🇧🇭", "KW": "🇰🇼",+ "LOCAL": "🏠", "UNKNOWN": "🌐", "PRIVATE": "🔒",+};++const countryNames: Record<string, string> = {+ "CN": "China", "US": "United States", "JP": "Japan", "HK": "Hong Kong", "TW": "Taiwan",+ "SG": "Singapore", "KR": "South Korea", "DE": "Germany", "GB": "United Kingdom", "FR": "France",+ "NL": "Netherlands", "CA": "Canada", "AU": "Australia", "IN": "India", "RU": "Russia",+ "BR": "Brazil", "TR": "Turkey", "VN": "Vietnam", "TH": "Thailand", "ID": "Indonesia",+ "MY": "Malaysia", "PH": "Philippines", "SE": "Sweden", "CH": "Switzerland", "IT": "Italy",+ "ES": "Spain", "PT": "Portugal", "PL": "Poland", "UA": "Ukraine", "MX": "Mexico",+ "AR": "Argentina", "CL": "Chile", "ZA": "South Africa", "AE": "UAE", "SA": "Saudi Arabia",+ "LOCAL": "Local", "UNKNOWN": "Unknown", "PRIVATE": "Private",+};++function getCountryFlag(countryCode: string): string {+ return countryFlags[countryCode.toUpperCase()] || "🌐";+}++function getCountryName(code: string): string {+ return countryNames[code.toUpperCase()] || code;+}++export const TopCountriesSimple = React.memo(function TopCountriesSimple({+ countries,+}: TopCountriesSimpleProps) {+ const t = useTranslations("topCountries");++ const sortedCountries = useMemo(() => {+ if (!countries?.length) return [];+ return [...countries]+ .sort((a, b) => b.totalDownload + b.totalUpload - a.totalDownload - a.totalUpload)+ .slice(0, 6);+ }, [countries]);++ const maxTotal = useMemo(() => {+ if (!sortedCountries.length) return 1;+ return Math.max(...sortedCountries.map(c => c.totalDownload + c.totalUpload));+ }, [sortedCountries]);++ return (+ <div className="space-y-3 h-full flex flex-col">+ {/* Header */}+ <div className="flex items-center justify-between">+ <h3 className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Globe className="w-4 h-4" />+ {t("title")}+ </h3>+ </div>++ {/* List */}+ <div className="space-y-2 flex-1">+ {sortedCountries.map((country, index) => {+ const total = country.totalDownload + country.totalUpload;+ const percent = (total / maxTotal) * 100;+ const badgeColor = index === 0+ ? "bg-amber-100 text-amber-700 dark:bg-amber-900/30 dark:text-amber-400"+ : index === 1+ ? "bg-slate-100 text-slate-700 dark:bg-slate-800 dark:text-slate-300"+ : index === 2+ ? "bg-orange-100 text-orange-700 dark:bg-orange-900/30 dark:text-orange-400"+ : "bg-muted text-muted-foreground";++ return (+ <div+ key={country.country}+ className="p-2.5 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Row 1: Rank + Flag + Name + Total */}+ <div className="flex items-center gap-2 mb-1.5">+ <span className={cn(+ "w-5 h-5 rounded-md text-[10px] font-bold flex items-center justify-center shrink-0",+ badgeColor+ )}>+ {index + 1}+ </span>+ <span className="text-base shrink-0">{getCountryFlag(country.country)}</span>+ <span className="flex-1 text-sm font-medium">+ {getCountryName(country.country)}+ </span>+ <span className="text-sm font-bold tabular-nums shrink-0">+ {formatBytes(total)}+ </span>+ </div>++ {/* Row 2: Progress bar with download/upload breakdown */}+ <div className="pl-7 space-y-1.5">+ {/* Progress bar */}+ <div className="h-1.5 rounded-full bg-muted overflow-hidden flex">+ <div+ className="h-full bg-blue-500 dark:bg-blue-400"+ style={{ width: `${(country.totalDownload / total) * percent}%` }}+ />+ <div+ className="h-full bg-purple-500 dark:bg-purple-400"+ style={{ width: `${(country.totalUpload / total) * percent}%` }}+ />+ </div>+ {/* Stats */}+ <div className="flex items-center justify-between text-xs text-muted-foreground">+ <div className="flex items-center gap-2">+ <span className="text-blue-500 dark:text-blue-400">↓ {formatBytes(country.totalDownload)}</span>+ <span className="text-purple-500 dark:text-purple-400">↑ {formatBytes(country.totalUpload)}</span>+ </div>+ <span className="tabular-nums">{percent.toFixed(0)}%</span>+ </div>+ </div>+ </div>+ );+ })}+ </div>++ {/* Footer */}+ <div className="pt-2 border-t border-border/30">+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs">+ {t("viewAll")}+ <ArrowRight className="w-3 h-3 ml-1" />+ </Button>+ </div>+ </div>+ );+}, (prev, next) => JSON.stringify(prev.countries) === JSON.stringify(next.countries));diff --git a/apps/web/components/overview/top-domains-simple.tsx b/apps/web/components/overview/top-domains-simple.tsxnew file mode 100644index 0000000..02a5d67--- /dev/null+++ b/apps/web/components/overview/top-domains-simple.tsx@@ -0,0 +1,175 @@+"use client";++import React, { useMemo } from "react";+import { Globe, ArrowRight, BarChart3, Link2 } from "lucide-react";+import { useTranslations } from "next-intl";+import { Button } from "@/components/ui/button";+import { cn, formatBytes } from "@/lib/utils";+import type { DomainStats } from "@clashstats/shared";++interface TopDomainsSimpleProps {+ domains: DomainStats[];+ sortBy: "traffic" | "connections";+ onSortChange: (mode: "traffic" | "connections") => void;+}++function getFaviconUrl(domain: string): string {+ return `https://www.google.com/s2/favicons?domain=${domain}&sz=64`;+}++function getInitials(domain: string): string {+ return domain.slice(0, 2).toUpperCase();+}++export const TopDomainsSimple = React.memo(function TopDomainsSimple({+ domains,+ sortBy,+ onSortChange,+}: TopDomainsSimpleProps) {+ const t = useTranslations("topDomains");++ const sortedDomains = useMemo(() => {+ if (!domains?.length) return [];++ const sorted = [...domains]+ .sort((a, b) => {+ if (sortBy === "traffic") {+ const totalA = a.totalDownload + a.totalUpload;+ const totalB = b.totalDownload + b.totalUpload;+ return totalB - totalA;+ } else {+ return b.totalConnections - a.totalConnections;+ }+ });++ return sorted.slice(0, 6);+ }, [domains, sortBy]);++ return (+ <div className="space-y-3 h-full flex flex-col">+ {/* Header */}+ <div className="flex items-center justify-between">+ <h3 className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Globe className="w-4 h-4" />+ {t("title")}+ </h3>++ {/* Sort toggle */}+ <div className="flex items-center gap-0.5 bg-muted/50 rounded-lg p-0.5">+ <Button+ variant="ghost"+ size="icon"+ className={cn(+ "h-7 w-7 rounded-md transition-all",+ sortBy === "traffic"+ ? "bg-background shadow-sm text-primary"+ : "text-muted-foreground hover:text-foreground"+ )}+ onClick={() => onSortChange("traffic")}+ title={t("sortByTraffic")}+ >+ <BarChart3 className="w-4 h-4" />+ </Button>+ <Button+ variant="ghost"+ size="icon"+ className={cn(+ "h-7 w-7 rounded-md transition-all",+ sortBy === "connections"+ ? "bg-background shadow-sm text-primary"+ : "text-muted-foreground hover:text-foreground"+ )}+ onClick={() => onSortChange("connections")}+ title={t("sortByConnections")}+ >+ <Link2 className="w-4 h-4" />+ </Button>+ </div>+ </div>++ {/* List */}+ <div className="space-y-2 flex-1">+ {sortedDomains.map((domain, index) => {+ const total = domain.totalDownload + domain.totalUpload;+ const badgeColor = index === 0+ ? "bg-amber-100 text-amber-700 dark:bg-amber-900/30 dark:text-amber-400"+ : index === 1+ ? "bg-slate-100 text-slate-700 dark:bg-slate-800 dark:text-slate-300"+ : index === 2+ ? "bg-orange-100 text-orange-700 dark:bg-orange-900/30 dark:text-orange-400"+ : "bg-muted text-muted-foreground";++ return (+ <div+ key={domain.domain}+ className="p-2.5 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Row 1: Rank + Icon + Domain + Total */}+ <div className="flex items-center gap-2 mb-1.5">+ <span className={cn(+ "w-5 h-5 rounded-md text-[10px] font-bold flex items-center justify-center shrink-0",+ badgeColor+ )}>+ {index + 1}+ </span>++ {/* Favicon */}+ <div className="w-5 h-5 rounded bg-muted flex items-center justify-center shrink-0 overflow-hidden">+ <img+ src={getFaviconUrl(domain.domain)}+ alt=""+ className="w-4 h-4"+ loading="lazy"+ onError={(e) => {+ const target = e.target as HTMLImageElement;+ target.style.display = "none";+ const parent = target.parentElement;+ if (parent) {+ parent.innerHTML = `<span class="text-[9px] font-bold text-muted-foreground">${getInitials(domain.domain)}</span>`;+ }+ }}+ />+ </div>++ <span className="flex-1 text-sm font-medium truncate" title={domain.domain}>+ {domain.domain}+ </span>++ <span className="text-sm font-bold tabular-nums shrink-0">+ {formatBytes(total)}+ </span>+ </div>++ {/* Row 2: Download | Upload | Connections */}+ <div className="flex items-center justify-between text-xs text-muted-foreground pl-7">+ <div className="flex items-center gap-3">+ <span className="text-blue-500 dark:text-blue-400">↓ {formatBytes(domain.totalDownload)}</span>+ <span className="text-purple-500 dark:text-purple-400">↑ {formatBytes(domain.totalUpload)}</span>+ </div>+ <span className="flex items-center gap-1 tabular-nums">+ <svg className="w-3 h-3" fill="none" stroke="currentColor" viewBox="0 0 24 24">+ <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M13.828 10.172a4 4 0 00-5.656 0l-4 4a4 4 0 105.656 5.656l1.102-1.101m-.758-4.899a4 4 0 005.656 0l4-4a4 4 0 00-5.656-5.656l-1.1 1.1" />+ </svg>+ {domain.totalConnections}+ </span>+ </div>+ </div>+ );+ })}+ </div>++ {/* Footer */}+ <div className="pt-2 border-t border-border/30">+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs">+ {t("viewAll")}+ <ArrowRight className="w-3 h-3 ml-1" />+ </Button>+ </div>+ </div>+ );+}, (prev, next) => {+ return (+ JSON.stringify(prev.domains) === JSON.stringify(next.domains) &&+ prev.sortBy === next.sortBy+ );+});diff --git a/apps/web/components/overview/top-proxies-simple.tsx b/apps/web/components/overview/top-proxies-simple.tsxnew file mode 100644index 0000000..5800497--- /dev/null+++ b/apps/web/components/overview/top-proxies-simple.tsx@@ -0,0 +1,156 @@+"use client";++import React, { useMemo } from "react";+import { Server, ArrowRight, BarChart3, Link2 } from "lucide-react";+import { useTranslations } from "next-intl";+import { Button } from "@/components/ui/button";+import { cn, formatBytes } from "@/lib/utils";+import type { ProxyStats } from "@clashstats/shared";++interface TopProxiesSimpleProps {+ proxies: ProxyStats[];+ sortBy: "traffic" | "connections";+ onSortChange: (mode: "traffic" | "connections") => void;+}++function simplifyProxyName(name: string): string {+ return name+ .replace(/[✈️🚀📹🚚🏠🐟🛡️⭐💎🔥⚡💨🌟🇨🇳🇺🇸🇯🇵🇭🇰🇸🇬🇬🇧🇩🇪🇫🇷]/gu, "")+ .replace(/^\s+|\s+$/g, "")+ .replace(/^\[.*?\]\s*/, "");+}++export const TopProxiesSimple = React.memo(function TopProxiesSimple({+ proxies,+ sortBy,+ onSortChange,+}: TopProxiesSimpleProps) {+ const t = useTranslations("topProxies");++ const sortedProxies = useMemo(() => {+ if (!proxies?.length) return [];++ const sorted = [...proxies].sort((a, b) => {+ if (sortBy === "traffic") {+ const totalA = a.totalDownload + a.totalUpload;+ const totalB = b.totalDownload + b.totalUpload;+ return totalB - totalA;+ } else {+ return b.totalConnections - a.totalConnections;+ }+ });++ return sorted.slice(0, 6);+ }, [proxies, sortBy]);++ return (+ <div className="space-y-3 h-full flex flex-col">+ {/* Header */}+ <div className="flex items-center justify-between">+ <h3 className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Server className="w-4 h-4" />+ {t("title")}+ </h3>++ {/* Sort toggle */}+ <div className="flex items-center gap-0.5 bg-muted/50 rounded-lg p-0.5">+ <Button+ variant="ghost"+ size="icon"+ className={cn(+ "h-7 w-7 rounded-md transition-all",+ sortBy === "traffic"+ ? "bg-background shadow-sm text-primary"+ : "text-muted-foreground hover:text-foreground"+ )}+ onClick={() => onSortChange("traffic")}+ title={t("sortByTraffic")}+ >+ <BarChart3 className="w-4 h-4" />+ </Button>+ <Button+ variant="ghost"+ size="icon"+ className={cn(+ "h-7 w-7 rounded-md transition-all",+ sortBy === "connections"+ ? "bg-background shadow-sm text-primary"+ : "text-muted-foreground hover:text-foreground"+ )}+ onClick={() => onSortChange("connections")}+ title={t("sortByConnections")}+ >+ <Link2 className="w-4 h-4" />+ </Button>+ </div>+ </div>++ {/* List */}+ <div className="space-y-2 flex-1">+ {sortedProxies.map((proxyItem, index) => {+ const total = proxyItem.totalDownload + proxyItem.totalUpload;+ const displayName = simplifyProxyName(proxyItem.chain);+ const badgeColor = index === 0+ ? "bg-amber-100 text-amber-700 dark:bg-amber-900/30 dark:text-amber-400"+ : index === 1+ ? "bg-slate-100 text-slate-700 dark:bg-slate-800 dark:text-slate-300"+ : index === 2+ ? "bg-orange-100 text-orange-700 dark:bg-orange-900/30 dark:text-orange-400"+ : "bg-muted text-muted-foreground";++ return (+ <div+ key={proxyItem.chain}+ className="p-2.5 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Row 1: Rank + Name + Total */}+ <div className="flex items-center gap-2 mb-1.5">+ <span className={cn(+ "w-5 h-5 rounded-md text-[10px] font-bold flex items-center justify-center shrink-0",+ badgeColor+ )}>+ {index + 1}+ </span>++ <span className="flex-1 text-sm font-medium truncate" title={proxyItem.chain}>+ {displayName || proxyItem.chain}+ </span>++ <span className="text-sm font-bold tabular-nums shrink-0">+ {formatBytes(total)}+ </span>+ </div>++ {/* Row 2: Download | Upload | Connections */}+ <div className="flex items-center justify-between text-xs text-muted-foreground pl-7">+ <div className="flex items-center gap-3">+ <span className="text-blue-500 dark:text-blue-400">↓ {formatBytes(proxyItem.totalDownload)}</span>+ <span className="text-purple-500 dark:text-purple-400">↑ {formatBytes(proxyItem.totalUpload)}</span>+ </div>+ <span className="flex items-center gap-1 tabular-nums">+ <svg className="w-3 h-3" fill="none" stroke="currentColor" viewBox="0 0 24 24">+ <path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M13.828 10.172a4 4 0 00-5.656 0l-4 4a4 4 0 105.656 5.656l1.102-1.101m-.758-4.899a4 4 0 005.656 0l4-4a4 4 0 00-5.656-5.656l-1.1 1.1" />+ </svg>+ {proxyItem.totalConnections}+ </span>+ </div>+ </div>+ );+ })}+ </div>++ {/* Footer */}+ <div className="pt-2 border-t border-border/30">+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs">+ {t("viewAll")}+ <ArrowRight className="w-3 h-3 ml-1" />+ </Button>+ </div>+ </div>+ );+}, (prev, next) => {+ return (+ JSON.stringify(prev.proxies) === JSON.stringify(next.proxies) &&+ prev.sortBy === next.sortBy+ );+});diff --git a/apps/web/components/providers/theme-provider.tsx b/apps/web/components/providers/theme-provider.tsxnew file mode 100644index 0000000..189a2b1--- /dev/null+++ b/apps/web/components/providers/theme-provider.tsx@@ -0,0 +1,11 @@+"use client";++import * as React from "react";+import { ThemeProvider as NextThemesProvider } from "next-themes";++export function ThemeProvider({+ children,+ ...props+}: React.ComponentProps<typeof NextThemesProvider>) {+ return <NextThemesProvider {...props}>{children}</NextThemesProvider>;+}diff --git a/apps/web/components/proxy-stats-chart.tsx b/apps/web/components/proxy-stats-chart.tsxnew file mode 100644index 0000000..ba1ea3a--- /dev/null+++ b/apps/web/components/proxy-stats-chart.tsx@@ -0,0 +1,170 @@+"use client";++import { useMemo } from "react";+import { PieChart, Pie, Cell, ResponsiveContainer, Tooltip } from "recharts";+import { Server } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { formatBytes } from "@/lib/utils";+import type { ProxyStats } from "@clashstats/shared";++interface ProxyStatsChartProps {+ data: ProxyStats[];+}++const COLORS = [+ "#3B82F6", "#8B5CF6", "#06B6D4", "#10B981", "#F59E0B",+ "#EF4444", "#EC4899", "#6366F1", "#14B8A6", "#F97316",+];++// Format proxy name for display+function formatProxyName(name: string): string {+ if (!name) return "DIRECT";+ return name+ .replace(/^\["?/, "")+ .replace(/"?\]$/, "")+ .trim();+}++export function ProxyStatsChart({ data }: ProxyStatsChartProps) {+ const chartData = useMemo(() => {+ if (!data) return [];+ return data.map((proxy, index) => ({+ name: formatProxyName(proxy.chain),+ rawName: proxy.chain,+ value: proxy.totalDownload + proxy.totalUpload,+ download: proxy.totalDownload,+ upload: proxy.totalUpload,+ connections: proxy.totalConnections,+ color: COLORS[index % COLORS.length],+ }));+ }, [data]);++ const totalTraffic = useMemo(() => {+ return chartData.reduce((sum, item) => sum + item.value, 0);+ }, [chartData]);++ const CustomTooltip = ({ active, payload }: any) => {+ if (active && payload && payload.length) {+ const item = payload[0].payload;+ return (+ <div className="glass-card p-3 rounded-lg border shadow-lg">+ <p className="font-medium text-sm mb-2">{item.name}</p>+ <div className="space-y-1 text-xs">+ <div className="flex justify-between gap-4">+ <span className="text-muted-foreground">Total:</span>+ <span className="font-medium">{formatBytes(item.value)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-blue-500">↓ Download:</span>+ <span>{formatBytes(item.download)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-purple-500">↑ Upload:</span>+ <span>{formatBytes(item.upload)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-emerald-500">Connections:</span>+ <span>{item.connections.toLocaleString()}</span>+ </div>+ </div>+ </div>+ );+ }+ return null;+ };++ return (+ <Card>+ <CardHeader className="pb-2">+ <CardTitle className="text-lg font-semibold flex items-center gap-2">+ <Server className="h-5 w-5 text-primary" />+ Proxy Traffic Distribution+ </CardTitle>+ </CardHeader>+ <CardContent className="space-y-6">+ {/* Pie Chart at Top */}+ <div className="h-[220px] w-full">+ <ResponsiveContainer width="100%" height="100%">+ <PieChart>+ <Pie+ data={chartData}+ cx="50%"+ cy="50%"+ innerRadius={50}+ outerRadius={80}+ paddingAngle={2}+ dataKey="value"+ >+ {chartData.map((entry, index) => (+ <Cell key={`cell-${index}`} fill={entry.color} />+ ))}+ </Pie>+ <Tooltip content={<CustomTooltip />} />+ </PieChart>+ </ResponsiveContainer>+ </div>++ {/* Proxy Cards Grid */}+ <div className="grid grid-cols-2 gap-3">+ {chartData.map((item) => {+ const percentage = totalTraffic > 0 ? (item.value / totalTraffic) * 100 : 0;++ return (+ <div+ key={item.rawName}+ className="p-4 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Header: Color dot + Name */}+ <div className="flex items-center gap-2 mb-3">+ <div+ className="w-3 h-3 rounded-full shrink-0"+ style={{ backgroundColor: item.color }}+ />+ <p className="font-medium text-sm truncate" title={item.name}>+ {item.name}+ </p>+ </div>++ {/* Traffic Stats */}+ <div className="space-y-2">+ {/* Total with percentage */}+ <div className="flex items-baseline justify-between">+ <span className="text-2xl font-bold tabular-nums">+ {formatBytes(item.value)}+ </span>+ <span className="text-xs text-muted-foreground">+ {percentage.toFixed(1)}%+ </span>+ </div>++ {/* Progress bar */}+ <div className="h-1.5 bg-muted rounded-full overflow-hidden">+ <div+ className="h-full rounded-full transition-all duration-500"+ style={{ width: `${percentage}%`, backgroundColor: item.color }}+ />+ </div>++ {/* Download/Upload row */}+ <div className="flex items-center justify-between text-xs pt-1">+ <span className="text-blue-500 tabular-nums">+ ↓ {formatBytes(item.download)}+ </span>+ <span className="text-purple-500 tabular-nums">+ ↑ {formatBytes(item.upload)}+ </span>+ </div>++ {/* Connections */}+ <p className="text-xs text-muted-foreground">+ {item.connections.toLocaleString()} connections+ </p>+ </div>+ </div>+ );+ })}+ </div>+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/proxy-top-grid.tsx b/apps/web/components/proxy-top-grid.tsxnew file mode 100644index 0000000..1f0b117--- /dev/null+++ b/apps/web/components/proxy-top-grid.tsx@@ -0,0 +1,152 @@+"use client";++import { useMemo, useState } from "react";+import { Server, Users, ArrowUpDown, ArrowRight } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { Button } from "@/components/ui/button";+import { formatBytes } from "@/lib/utils";+import type { ProxyStats } from "@clashstats/shared";++interface ProxyTopGridProps {+ data: ProxyStats[];+ limit?: number;+ onViewAll?: () => void;+}++type SortBy = "traffic" | "connections";++const COLORS = ["#3B82F6", "#8B5CF6", "#06B6D4", "#10B981", "#F59E0B", "#EF4444"];++function formatProxyName(name: string): string {+ if (!name) return "DIRECT";+ return name+ .replace(/^\["?/, "")+ .replace(/"?\]$/, "")+ .replace(/^🇺🇸\s*/, "")+ .replace(/^🇯🇵\s*/, "")+ .replace(/^🇸🇬\s*/, "")+ .trim();+}++function getProxyEmoji(name: string): string {+ if (name.includes("🇺🇸")) return "🇺🇸";+ if (name.includes("🇯🇵")) return "🇯🇵";+ if (name.includes("🇸🇬")) return "🇸🇬";+ if (name.includes("🇭🇰")) return "🇭🇰";+ if (name.includes("🇹🇼")) return "🇹🇼";+ if (name.includes("🇰🇷")) return "🇰🇷";+ if (name === "DIRECT" || name === "Direct") return "🏠";+ return "🌐";+}++export function ProxyTopGrid({ data, limit = 5, onViewAll }: ProxyTopGridProps) {+ const [sortBy, setSortBy] = useState<SortBy>("traffic");++ const proxies = useMemo(() => {+ if (!data) return [];++ const sorted = [...data].sort((a, b) => {+ if (sortBy === "traffic") {+ return (b.totalDownload + b.totalUpload) - (a.totalDownload + a.totalUpload);+ }+ return b.totalConnections - a.totalConnections;+ });++ return sorted.slice(0, limit).map((p, i) => ({+ ...p,+ total: p.totalDownload + p.totalUpload,+ color: COLORS[i % COLORS.length],+ displayName: formatProxyName(p.chain),+ emoji: getProxyEmoji(p.chain),+ }));+ }, [data, limit, sortBy]);++ const toggleSort = () => setSortBy(prev => prev === "traffic" ? "connections" : "traffic");++ return (+ <Card className="h-full flex flex-col">+ <CardHeader className="pb-3 flex-shrink-0">+ <div className="flex items-center justify-between">+ <CardTitle className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Server className="w-4 h-4" />+ Top 代理+ </CardTitle>+ <Button+ variant="ghost"+ size="sm"+ className="h-7 px-2 text-xs"+ onClick={toggleSort}+ >+ {sortBy === "traffic" ? (+ <><ArrowUpDown className="w-3 h-3 mr-1" /> 流量</>+ ) : (+ <><Users className="w-3 h-3 mr-1" /> 连接</>+ )}+ </Button>+ </div>+ </CardHeader>+ <CardContent className="flex-1 flex flex-col pt-0">+ <div className="space-y-2 flex-1">+ {proxies.map((proxy, index) => (+ <div+ key={proxy.chain}+ className="flex items-center gap-3 p-3 rounded-xl border border-border/50 bg-card/50 hover:bg-card transition-colors"+ >+ {/* Rank */}+ <span className={`+ w-6 h-6 rounded-md text-xs font-bold flex items-center justify-center shrink-0+ ${index < 3+ ? "bg-primary/10 text-primary"+ : "bg-muted text-muted-foreground"+ }+ `}>+ {index + 1}+ </span>++ {/* Emoji */}+ <span className="text-2xl">{proxy.emoji}</span>++ {/* Name */}+ <div className="flex-1 min-w-0">+ <p className="font-medium text-sm truncate" title={proxy.chain}>+ {proxy.displayName}+ </p>+ </div>++ {/* Stats */}+ <div className="flex items-center gap-4 text-xs">+ <span className="text-blue-500 tabular-nums">+ ↓ {formatBytes(proxy.totalDownload)}+ </span>+ <span className="text-purple-500 tabular-nums">+ ↑ {formatBytes(proxy.totalUpload)}+ </span>+ <span className="text-muted-foreground flex items-center gap-1">+ <Users className="w-3 h-3" />+ {proxy.totalConnections}+ </span>+ </div>++ {/* Total */}+ <div className="text-right min-w-[80px]">+ <p className="font-bold tabular-nums">+ {formatBytes(proxy.total)}+ </p>+ </div>+ </div>+ ))}+ </div>++ {/* Footer */}+ {onViewAll && (+ <div className="mt-4 pt-3 border-t border-border/30">+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs" onClick={onViewAll}>+ 查看全部+ <ArrowRight className="w-3 h-3 ml-1" />+ </Button>+ </div>+ )}+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/proxy-top-list.tsx b/apps/web/components/proxy-top-list.tsxnew file mode 100644index 0000000..7e272eb--- /dev/null+++ b/apps/web/components/proxy-top-list.tsx@@ -0,0 +1,133 @@+"use client";++import { useMemo, useState } from "react";+import { Server, Users, ArrowUpDown } from "lucide-react";+import { OverviewCard } from "./overview-card";+import { TopListItem } from "./top-list-item";+import { Button } from "@/components/ui/button";+import { formatBytes } from "@/lib/utils";+import type { ProxyStats } from "@clashstats/shared";++interface ProxyTopListProps {+ data: ProxyStats[];+ limit?: number;+ onViewAll?: () => void;+}++type SortBy = "traffic" | "connections";++const COLORS = ["#3B82F6", "#8B5CF6", "#06B6D4", "#10B981", "#F59E0B"];++function formatProxyName(name: string): string {+ if (!name) return "DIRECT";+ return name+ .replace(/^\["?/, "")+ .replace(/"?\]$/, "")+ .replace(/^🇺🇸\s*/, "🇺🇸 ")+ .replace(/^🇯🇵\s*/, "🇯🇵 ")+ .replace(/^🇸🇬\s*/, "🇸🇬 ")+ .replace(/^🇭🇰\s*/, "🇭🇰 ")+ .trim();+}++function getProxyEmoji(name: string): string {+ if (name.includes("🇺🇸")) return "🇺🇸";+ if (name.includes("🇯🇵")) return "🇯🇵";+ if (name.includes("🇸🇬")) return "🇸🇬";+ if (name.includes("🇭🇰")) return "🇭🇰";+ if (name.includes("🇹🇼")) return "🇹🇼";+ if (name.includes("🇰🇷")) return "🇰🇷";+ if (name === "DIRECT" || name === "Direct") return "🏠";+ return "🌐";+}++export function ProxyTopList({ data, limit = 5, onViewAll }: ProxyTopListProps) {+ const [sortBy, setSortBy] = useState<SortBy>("traffic");++ const { proxies, totalTraffic, totalConnections } = useMemo(() => {+ if (!data) return { proxies: [], totalTraffic: 0, totalConnections: 0 };++ const sorted = [...data].sort((a, b) => {+ if (sortBy === "traffic") {+ const totalA = a.totalDownload + a.totalUpload;+ const totalB = b.totalDownload + b.totalUpload;+ return totalB - totalA;+ }+ return b.totalConnections - a.totalConnections;+ });++ const list = sorted.slice(0, limit).map((p, i) => ({+ ...p,+ total: p.totalDownload + p.totalUpload,+ color: COLORS[i % COLORS.length],+ displayName: formatProxyName(p.chain),+ emoji: getProxyEmoji(p.chain),+ }));++ const totalT = list.reduce((sum, p) => sum + p.total, 0);+ const totalC = list.reduce((sum, p) => sum + p.totalConnections, 0);++ return { proxies: list, totalTraffic: totalT, totalConnections: totalC };+ }, [data, limit, sortBy]);++ const toggleSort = () => {+ setSortBy(prev => prev === "traffic" ? "connections" : "traffic");+ };++ if (proxies.length === 0) {+ return (+ <OverviewCard title="Top 代理" icon={<Server className="w-4 h-4" />}>+ <div className="py-8 text-center text-sm text-muted-foreground">+ 暂无数据+ </div>+ </OverviewCard>+ );+ }++ return (+ <OverviewCard+ title="Top 代理"+ icon={<Server className="w-4 h-4" />}+ action={+ <Button+ variant="ghost"+ size="sm"+ className="h-7 px-2 text-xs"+ onClick={toggleSort}+ >+ {sortBy === "traffic" ? (+ <><ArrowUpDown className="w-3 h-3 mr-1" /> 按流量</>+ ) : (+ <><Users className="w-3 h-3 mr-1" /> 按连接</>+ )}+ </Button>+ }+ footer={+ onViewAll && (+ <Button variant="ghost" size="sm" className="w-full h-9 text-xs" onClick={onViewAll}>+ 查看全部+ </Button>+ )+ }+ >+ <div className="space-y-1 min-h-[320px]">+ {proxies.map((proxy, index) => (+ <TopListItem+ key={proxy.chain}+ rank={index + 1}+ icon={<span className="text-lg">{proxy.emoji}</span>}+ title={proxy.displayName}+ subtitle={sortBy === "traffic"+ ? `${proxy.totalConnections} 连接`+ : `${formatBytes(proxy.total)}`+ }+ value={sortBy === "traffic" ? proxy.total : proxy.totalConnections}+ total={sortBy === "traffic" ? totalTraffic : totalConnections}+ color={proxy.color}+ valueFormatter={sortBy === "connections" ? (v) => `${v}` : undefined}+ />+ ))}+ </div>+ </OverviewCard>+ );+}diff --git a/apps/web/components/rule-chain-chart.tsx b/apps/web/components/rule-chain-chart.tsxnew file mode 100644index 0000000..2e12000--- /dev/null+++ b/apps/web/components/rule-chain-chart.tsx@@ -0,0 +1,162 @@+"use client";++import { useMemo } from "react";+import { Network, ArrowRight } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { formatBytes } from "@/lib/utils";+import type { RuleStats } from "@clashstats/shared";++interface RuleChainChartProps {+ data: RuleStats[];+}++const COLORS = [+ "#3B82F6", "#8B5CF6", "#06B6D4", "#10B981", "#F59E0B",+ "#EF4444", "#EC4899", "#6366F1", "#14B8A6", "#F97316",+];++function formatRuleName(rule: string): string {+ if (!rule) return "DIRECT";+ return rule+ .replace(/^\["?/, "")+ .replace(/"?\]$/, "")+ .replace(/^✈️\s*/, "")+ .replace(/^🚀\s*/, "")+ .replace(/^📹\s*/, "")+ .replace(/^🚚\s*/, "")+ .replace(/^🏠\s*/, "")+ .replace(/^🐟\s*/, "")+ .replace(/^📲\s*/, "")+ .replace(/^🎮\s*/, "")+ .replace(/^💼\s*/, "")+ .replace(/^🌐\s*/, "")+ .replace(/^🎵\s*/, "")+ .replace(/^🍎\s*/, "")+ .trim();+}++function getRuleEmoji(rule: string): string {+ if (rule.includes("✈️")) return "✈️";+ if (rule.includes("🚀")) return "🚀";+ if (rule.includes("📹")) return "📹";+ if (rule.includes("🚚")) return "🚚";+ if (rule.includes("🏠")) return "🏠";+ if (rule.includes("🐟")) return "🐟";+ if (rule.includes("📲")) return "📲";+ if (rule.includes("🎮")) return "🎮";+ if (rule.includes("💼")) return "💼";+ if (rule.includes("🌐")) return "🌐";+ if (rule.includes("🎵")) return "🎵";+ if (rule.includes("🍎")) return "🍎";+ return "🔗";+}++function formatProxyName(proxy: string): string {+ if (!proxy) return "DIRECT";+ return proxy+ .replace(/^\["?/, "")+ .replace(/"?\]$/, "")+ .trim();+}++export function RuleChainChart({ data }: RuleChainChartProps) {+ const rules = useMemo(() => {+ if (!data) return [];+ return data.map((rule, index) => ({+ ...rule,+ color: COLORS[index % COLORS.length],+ formattedRule: formatRuleName(rule.rule),+ formattedProxy: formatProxyName(rule.finalProxy),+ emoji: getRuleEmoji(rule.rule),+ total: rule.totalUpload + rule.totalDownload,+ }));+ }, [data]);++ const totalTraffic = useMemo(() => {+ return rules.reduce((sum, r) => sum + r.total, 0);+ }, [rules]);++ return (+ <Card>+ <CardHeader className="pb-3">+ <CardTitle className="text-lg font-semibold flex items-center gap-2">+ <Network className="h-5 w-5 text-primary" />+ Rule Chain Distribution+ </CardTitle>+ <p className="text-sm text-muted-foreground mt-1">+ Traffic distribution by matching rules and their final proxy nodes+ </p>+ </CardHeader>+ <CardContent>+ <div className="space-y-3">+ {rules.map((rule) => {+ const percentage = totalTraffic > 0 ? (rule.total / totalTraffic) * 100 : 0;++ return (+ <div+ key={rule.rule}+ className="p-3 rounded-lg border border-border/50 hover:bg-secondary/20 transition-colors"+ >+ {/* Top Row: Chain Flow + Traffic */}+ <div className="flex items-center gap-3">+ {/* Rule Icon */}+ <div+ className="w-9 h-9 rounded-lg flex items-center justify-center shrink-0"+ style={{ backgroundColor: `${rule.color}15` }}+ >+ <span className="text-base">{rule.emoji}</span>+ </div>++ {/* Rule Name */}+ <div className="min-w-0 flex-1">+ <p className="font-medium text-sm truncate" title={rule.formattedRule}>+ {rule.formattedRule}+ </p>+ </div>++ {/* Arrow */}+ <ArrowRight className="w-4 h-4 text-muted-foreground shrink-0" />++ {/* Proxy */}+ <div className="min-w-0 flex-1">+ <p className="font-medium text-sm text-muted-foreground truncate" title={rule.formattedProxy}>+ {rule.formattedProxy}+ </p>+ </div>++ {/* Traffic Stats */}+ <div className="text-right shrink-0 min-w-[100px]">+ <p className="font-semibold text-sm tabular-nums">+ {formatBytes(rule.total)}+ </p>+ <p className="text-xs text-muted-foreground">+ {percentage.toFixed(1)}%+ </p>+ </div>+ </div>++ {/* Second Row: Progress Bar + Detailed Stats */}+ <div className="mt-3 flex items-center gap-4">+ {/* Progress Bar */}+ <div className="flex-1 h-1.5 bg-muted rounded-full overflow-hidden">+ <div+ className="h-full rounded-full transition-all duration-500"+ style={{ width: `${percentage}%`, backgroundColor: rule.color }}+ />+ </div>++ {/* Detailed Stats */}+ <div className="flex items-center gap-4 text-xs text-muted-foreground shrink-0">+ <span className="tabular-nums">{rule.totalConnections.toLocaleString()} conn</span>+ <span className="tabular-nums text-blue-500">↓ {formatBytes(rule.totalDownload)}</span>+ <span className="tabular-nums text-purple-500">↑ {formatBytes(rule.totalUpload)}</span>+ </div>+ </div>+ </div>+ );+ })}+ </div>+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/stats-cards.tsx b/apps/web/components/stats-cards.tsxnew file mode 100644index 0000000..5d092a5--- /dev/null+++ b/apps/web/components/stats-cards.tsx@@ -0,0 +1,211 @@+"use client";++import { Download, Upload, Globe, Activity, Server, Route } from "lucide-react";+import { useTranslations } from "next-intl";+import { formatBytes } from "@/lib/utils";+import type { StatsSummary } from "@clashstats/shared";++interface StatsCardsProps {+ data: StatsSummary | null;+ error?: string | null;+}++function StatCard({+ value,+ label,+ subvalue,+ icon: Icon,+ color,+}: {+ value: number | string;+ label: string;+ subvalue?: string;+ icon: React.ElementType;+ color: string;+}) {+ return (+ <div className="rounded-xl p-4 border bg-card flex flex-col">+ <div+ className="w-10 h-10 rounded-lg flex items-center justify-center mb-3"+ style={{ backgroundColor: `${color}15` }}+ >+ <Icon className="w-5 h-5" style={{ color }} />+ </div>+ <div className="flex-1">+ <p className="text-muted-foreground text-xs uppercase tracking-wider font-medium truncate">+ {label}+ </p>+ <p className="text-xl font-bold mt-1 tabular-nums truncate" title={String(value)}>+ {value}+ </p>+ {subvalue && (+ <p className="text-xs text-muted-foreground mt-0.5 truncate">+ {subvalue}+ </p>+ )}+ </div>+ </div>+ );+}++function CircularProgressCard({+ value,+ max,+ icon: Icon,+ label,+ color,+}: {+ value: number;+ max: number;+ icon: React.ElementType;+ label: string;+ color: string;+}) {+ const radius = 28;+ const strokeWidth = 4;+ const circumference = radius * 2 * Math.PI;+ const percentage = Math.min(100, Math.max(0, (value / max) * 100));+ const offset = circumference - (percentage / 100) * circumference;+ const size = 64;++ return (+ <div className="rounded-xl p-4 border bg-card flex flex-col">+ <div className="mb-3">+ <div className="relative" style={{ width: size, height: size }}>+ <svg width={size} height={size} className="transform -rotate-90">+ <circle+ cx={size / 2}+ cy={size / 2}+ r={radius}+ stroke="currentColor"+ strokeWidth={strokeWidth}+ fill="transparent"+ className="text-muted/15"+ />+ <circle+ cx={size / 2}+ cy={size / 2}+ r={radius}+ stroke={color}+ strokeWidth={strokeWidth}+ fill="transparent"+ strokeDasharray={circumference}+ strokeDashoffset={offset}+ strokeLinecap="round"+ />+ </svg>+ <div className="absolute inset-0 flex items-center justify-center">+ <Icon className="w-4 h-4" style={{ color }} />+ </div>+ </div>+ </div>+ <div className="flex-1">+ <p className="text-muted-foreground text-xs uppercase tracking-wider font-medium truncate">+ {label}+ </p>+ <p className="text-xl font-bold mt-1 tabular-nums truncate" title={formatBytes(value)}>+ {formatBytes(value)}+ </p>+ </div>+ </div>+ );+}++function TodayCard({+ download,+ upload,+ title,+ downloadLabel,+ uploadLabel,+}: {+ download: number;+ upload: number;+ title: string;+ downloadLabel: string;+ uploadLabel: string;+}) {+ return (+ <div className="rounded-xl p-4 border bg-card flex flex-col">+ <div+ className="w-10 h-10 rounded-lg flex items-center justify-center mb-3"+ style={{ backgroundColor: "#10B98115" }}+ >+ <Activity className="w-5 h-5 text-emerald-500" />+ </div>+ <div className="flex-1">+ <p className="text-muted-foreground text-xs uppercase tracking-wider font-medium">+ {title}+ </p>+ <div className="mt-2 space-y-1.5">+ <div className="flex items-center justify-between gap-2">+ <span className="text-xs text-muted-foreground truncate">{downloadLabel}</span>+ <span className="text-sm font-semibold tabular-nums truncate">+ {formatBytes(download)}+ </span>+ </div>+ <div className="flex items-center justify-between gap-2">+ <span className="text-xs text-muted-foreground truncate">{uploadLabel}</span>+ <span className="text-sm font-semibold tabular-nums truncate">+ {formatBytes(upload)}+ </span>+ </div>+ </div>+ </div>+ </div>+ );+}++export function StatsCards({ data }: StatsCardsProps) {+ const t = useTranslations("stats");+ const maxTraffic = Math.max(+ data?.totalDownload || 0,+ data?.totalUpload || 0,+ 1+ );++ return (+ <div className="grid gap-3 grid-cols-2 sm:grid-cols-3 lg:grid-cols-6">+ <CircularProgressCard+ value={data?.totalDownload || 0}+ max={maxTraffic * 1.2}+ icon={Download}+ label={t("totalDownload")}+ color="#3B82F6"+ />+ <CircularProgressCard+ value={data?.totalUpload || 0}+ max={maxTraffic * 1.2}+ icon={Upload}+ label={t("totalUpload")}+ color="#8B5CF6"+ />+ <TodayCard+ download={data?.todayDownload || 0}+ upload={data?.todayUpload || 0}+ title={t("today")}+ downloadLabel={t("download")}+ uploadLabel={t("upload")}+ />+ <StatCard+ value={(data?.totalDomains || 0).toLocaleString()}+ label={t("domains")}+ icon={Globe}+ color="#06B6D4"+ />+ <StatCard+ value={(data?.totalRules || 0).toLocaleString()}+ label={t("rules")}+ subvalue={t("tracked")}+ icon={Route}+ color="#F59E0B"+ />+ <StatCard+ value={formatBytes((data?.totalDownload || 0) + (data?.totalUpload || 0))}+ label={t("total")}+ subvalue={`${(data?.totalDomains || 0)} ${t("tracked")}`}+ icon={Server}+ color="#EC4899"+ />+ </div>+ );+}diff --git a/apps/web/components/theme-toggle.tsx b/apps/web/components/theme-toggle.tsxnew file mode 100644index 0000000..d260258--- /dev/null+++ b/apps/web/components/theme-toggle.tsx@@ -0,0 +1,47 @@+"use client";++import { useTheme } from "next-themes";+import { Sun, Moon, Monitor } from "lucide-react";+import { Button } from "@/components/ui/button";+import {+ DropdownMenu,+ DropdownMenuContent,+ DropdownMenuItem,+ DropdownMenuTrigger,+} from "@/components/ui/dropdown-menu";+import { useTranslations } from "next-intl";++export function ThemeToggle() {+ const { theme, setTheme } = useTheme();+ const t = useTranslations("theme");++ return (+ <DropdownMenu>+ <DropdownMenuTrigger asChild>+ <Button+ variant="ghost"+ size="icon"+ className="h-9 w-9 rounded-full hover:bg-secondary"+ >+ <Sun className="h-4 w-4 rotate-0 scale-100 transition-all dark:-rotate-90 dark:scale-0" />+ <Moon className="absolute h-4 w-4 rotate-90 scale-0 transition-all dark:rotate-0 dark:scale-100" />+ <span className="sr-only">{t("toggle")}</span>+ </Button>+ </DropdownMenuTrigger>+ <DropdownMenuContent align="end" className="glass-card">+ <DropdownMenuItem onClick={() => setTheme("light")}>+ <Sun className="mr-2 h-4 w-4 text-amber-500" />+ {t("light")}+ </DropdownMenuItem>+ <DropdownMenuItem onClick={() => setTheme("dark")}>+ <Moon className="mr-2 h-4 w-4 text-indigo-500" />+ {t("dark")}+ </DropdownMenuItem>+ <DropdownMenuItem onClick={() => setTheme("system")}>+ <Monitor className="mr-2 h-4 w-4 text-slate-500" />+ {t("system")}+ </DropdownMenuItem>+ </DropdownMenuContent>+ </DropdownMenu>+ );+}diff --git a/apps/web/components/time-range-picker.tsx b/apps/web/components/time-range-picker.tsxnew file mode 100644index 0000000..11533c1--- /dev/null+++ b/apps/web/components/time-range-picker.tsx@@ -0,0 +1,202 @@+"use client";++import { useState, useEffect } from "react";+import { Calendar, Clock, ChevronDown, X } from "lucide-react";+import { Button } from "@/components/ui/button";+import { Card } from "@/components/ui/card";+import {+ Popover,+ PopoverContent,+ PopoverTrigger,+} from "@/components/ui/popover";+import { cn } from "@/lib/utils";+import {+ formatDateTimeForInput,+ formatDateTimeDisplay,+ getPresetTimeRange,+ type TimeRange,+} from "@/lib/api";++type PresetType = '7d' | '30d' | '24h' | 'today' | 'custom';++interface TimeRangePickerProps {+ value: TimeRange;+ onChange: (range: TimeRange, preset: PresetType) => void;+ className?: string;+}++const PRESETS: { value: PresetType; label: string }[] = [+ { value: '24h', label: '最近24小时' },+ { value: '7d', label: '最近7天' },+ { value: '30d', label: '最近30天' },+ { value: 'today', label: '今天' },+ { value: 'custom', label: '自定义' },+];++export function TimeRangePicker({ value, onChange, className }: TimeRangePickerProps) {+ const [open, setOpen] = useState(false);+ const [selectedPreset, setSelectedPreset] = useState<PresetType>('24h');+ const [customStart, setCustomStart] = useState(value.start.slice(0, 16));+ const [customEnd, setCustomEnd] = useState(value.end.slice(0, 16));++ // Update custom inputs when value changes externally+ useEffect(() => {+ setCustomStart(value.start.slice(0, 16));+ setCustomEnd(value.end.slice(0, 16));+ }, [value]);++ const handlePresetClick = (preset: PresetType) => {+ setSelectedPreset(preset);+ if (preset !== 'custom') {+ const range = getPresetTimeRange(preset);+ onChange(range, preset);+ setOpen(false);+ }+ };++ const handleCustomApply = () => {+ const range: TimeRange = {+ start: new Date(customStart).toISOString(),+ end: new Date(customEnd).toISOString(),+ };+ onChange(range, 'custom');+ setOpen(false);+ };++ const handleClear = () => {+ const range = getPresetTimeRange('24h');+ setSelectedPreset('24h');+ onChange(range, '24h');+ setOpen(false);+ };++ const displayText = () => {+ if (selectedPreset === 'custom') {+ return `${formatDateTimeDisplay(value.start)} - ${formatDateTimeDisplay(value.end)}`;+ }+ const preset = PRESETS.find(p => p.value === selectedPreset);+ return preset?.label || '最近24小时';+ };++ return (+ <Popover open={open} onOpenChange={setOpen}>+ <PopoverTrigger asChild>+ <Button+ variant="outline"+ className={cn(+ "justify-between min-w-[200px] bg-background/50 backdrop-blur-sm",+ className+ )}+ >+ <span className="flex items-center gap-2">+ <Clock className="w-4 h-4 text-muted-foreground" />+ <span className="truncate">{displayText()}</span>+ </span>+ <ChevronDown className="w-4 h-4 text-muted-foreground" />+ </Button>+ </PopoverTrigger>+ <PopoverContent className="w-auto p-0" align="end">+ <Card className="border-0 shadow-none">+ <div className="p-3 space-y-3">+ {/* Preset Buttons */}+ <div className="grid grid-cols-2 gap-2">+ {PRESETS.map((preset) => (+ <Button+ key={preset.value}+ variant={selectedPreset === preset.value ? "default" : "outline"}+ size="sm"+ onClick={() => handlePresetClick(preset.value)}+ className="justify-start"+ >+ {preset.label}+ </Button>+ ))}+ </div>++ {/* Custom Range Inputs */}+ {selectedPreset === 'custom' && (+ <div className="space-y-3 pt-2 border-t border-border">+ <div className="space-y-2">+ <label className="text-xs font-medium text-muted-foreground flex items-center gap-1">+ <Calendar className="w-3 h-3" />+ 开始时间+ </label>+ <input+ type="datetime-local"+ value={customStart}+ onChange={(e) => setCustomStart(e.target.value)}+ className="w-full px-3 py-2 text-sm bg-background border border-input rounded-md focus:outline-none focus:ring-2 focus:ring-ring"+ />+ </div>+ <div className="space-y-2">+ <label className="text-xs font-medium text-muted-foreground flex items-center gap-1">+ <Calendar className="w-3 h-3" />+ 结束时间+ </label>+ <input+ type="datetime-local"+ value={customEnd}+ onChange={(e) => setCustomEnd(e.target.value)}+ className="w-full px-3 py-2 text-sm bg-background border border-input rounded-md focus:outline-none focus:ring-2 focus:ring-ring"+ />+ </div>+ <div className="flex gap-2">+ <Button+ size="sm"+ className="flex-1"+ onClick={handleCustomApply}+ >+ 应用+ </Button>+ <Button+ size="sm"+ variant="outline"+ onClick={handleClear}+ >+ <X className="w-4 h-4" />+ </Button>+ </div>+ </div>+ )}++ {/* Current Selection Info */}+ <div className="pt-2 border-t border-border text-xs text-muted-foreground">+ <div className="flex justify-between">+ <span>开始:</span>+ <span className="font-mono">{formatDateTimeDisplay(value.start)}</span>+ </div>+ <div className="flex justify-between mt-1">+ <span>结束:</span>+ <span className="font-mono">{formatDateTimeDisplay(value.end)}</span>+ </div>+ </div>+ </div>+ </Card>+ </PopoverContent>+ </Popover>+ );+}++// Quick preset buttons for common ranges+export function QuickTimePresets({ onChange }: { onChange: (range: TimeRange) => void }) {+ const presets = [+ { label: '24小时', range: getPresetTimeRange('24h') },+ { label: '7天', range: getPresetTimeRange('7d') },+ { label: '30天', range: getPresetTimeRange('30d') },+ ];++ return (+ <div className="flex gap-2">+ {presets.map((preset) => (+ <Button+ key={preset.label}+ variant="outline"+ size="sm"+ onClick={() => onChange(preset.range)}+ >+ {preset.label}+ </Button>+ ))}+ </div>+ );+}diff --git a/apps/web/components/top-domains-chart.tsx b/apps/web/components/top-domains-chart.tsxnew file mode 100644index 0000000..8b62278--- /dev/null+++ b/apps/web/components/top-domains-chart.tsx@@ -0,0 +1,157 @@+"use client";++import { useState, useMemo } from "react";+import { BarChart, Bar, XAxis, YAxis, CartesianGrid, Tooltip, ResponsiveContainer, Cell, LabelList } from "recharts";+import { useTranslations } from "next-intl";+import { BarChart3 } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { Tabs, TabsList, TabsTrigger } from "@/components/ui/tabs";+import { Favicon } from "@/components/favicon";+import { formatBytes } from "@/lib/utils";+import type { DomainStats } from "@clashstats/shared";++interface TopDomainsChartProps {+ data: DomainStats[];+}++const TOP_OPTIONS = [10, 20, 50, 100] as const;+type TopOption = (typeof TOP_OPTIONS)[number];++// Vibrant color palette for bars+const COLORS = [+ "#3B82F6", // Blue+ "#8B5CF6", // Purple+ "#06B6D4", // Cyan+ "#10B981", // Emerald+ "#F59E0B", // Amber+ "#EF4444", // Red+ "#EC4899", // Pink+ "#6366F1", // Indigo+ "#14B8A6", // Teal+ "#F97316", // Orange+];++export function TopDomainsChart({ data }: TopDomainsChartProps) {+ const t = useTranslations("domains");+ const commonT = useTranslations("stats");+ const [topN, setTopN] = useState<TopOption>(10);++ const chartData = useMemo(() => {+ if (!data) return [];+ return data+ .slice(0, topN)+ .map((domain, index) => ({+ name: domain.domain.length > 20 ? domain.domain.slice(0, 20) + "..." : domain.domain,+ fullDomain: domain.domain,+ total: domain.totalDownload + domain.totalUpload,+ download: domain.totalDownload,+ upload: domain.totalUpload,+ color: COLORS[index % COLORS.length],+ }));+ }, [data, topN]);++ const CustomTooltip = ({ active, payload }: any) => {+ if (active && payload && payload.length) {+ const item = payload[0].payload;+ return (+ <div className="bg-background border border-border p-3 rounded-lg shadow-lg">+ <div className="flex items-center gap-2 mb-2">+ <Favicon domain={item.fullDomain} size="sm" />+ <span className="font-medium text-sm text-foreground">{item.fullDomain}</span>+ </div>+ <div className="space-y-1 text-xs">+ <div className="flex justify-between gap-4">+ <span className="text-muted-foreground">{commonT("total")}:</span>+ <span className="font-medium text-foreground">{formatBytes(item.total)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-blue-500">{commonT("download")}:</span>+ <span className="text-foreground">{formatBytes(item.download)}</span>+ </div>+ <div className="flex justify-between gap-4">+ <span className="text-purple-500">{commonT("upload")}:</span>+ <span className="text-foreground">{formatBytes(item.upload)}</span>+ </div>+ </div>+ </div>+ );+ }+ return null;+ };++ return (+ <Card>+ <CardHeader className="pb-2">+ <div className="flex flex-col sm:flex-row sm:items-center sm:justify-between gap-4">+ <div>+ <CardTitle className="text-lg font-semibold flex items-center gap-2">+ <BarChart3 className="h-5 w-5 text-primary" />+ {t("topDomainsByTraffic")}+ </CardTitle>+ <p className="text-sm text-muted-foreground mt-1">+ {t("mostBandwidthConsuming")}+ </p>+ </div>+ <Tabs value={topN.toString()} onValueChange={(v) => setTopN(parseInt(v) as TopOption)}>+ <TabsList className="h-8">+ {TOP_OPTIONS.map((n) => (+ <TabsTrigger key={n} value={n.toString()} className="text-xs px-3">+ Top {n}+ </TabsTrigger>+ ))}+ </TabsList>+ </Tabs>+ </div>+ </CardHeader>+ <CardContent>+ <div className="h-[350px] w-full">+ <ResponsiveContainer width="100%" height="100%">+ <BarChart+ data={chartData}+ layout="vertical"+ margin={{ top: 10, right: 80, left: 40, bottom: 10 }}+ >+ <CartesianGrid+ strokeDasharray="3 3"+ stroke="#888888"+ opacity={0.2}+ horizontal={false}+ />+ <XAxis+ type="number"+ tickFormatter={(value) => formatBytes(value, 0)}+ tick={{ fill: "#888888", fontSize: 11 }}+ tickLine={false}+ axisLine={false}+ />+ <YAxis+ type="category"+ dataKey="name"+ width={120}+ tick={{ fontSize: 11, fill: "currentColor" }}+ tickLine={false}+ axisLine={false}+ />+ <Tooltip+ content={<CustomTooltip />}+ cursor={{ fill: "rgba(128, 128, 128, 0.1)" }}+ />+ <Bar dataKey="total" radius={[0, 4, 4, 0]} maxBarSize={32}>+ {chartData.map((entry, index) => (+ <Cell key={`cell-${index}`} fill={entry.color} />+ ))}+ <LabelList+ dataKey="total"+ position="right"+ formatter={(value: number) => formatBytes(value, 0)}+ className="fill-foreground"+ style={{ fontSize: 10, whiteSpace: 'nowrap' }}+ />+ </Bar>+ </BarChart>+ </ResponsiveContainer>+ </div>+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/components/top-list-item.tsx b/apps/web/components/top-list-item.tsxnew file mode 100644index 0000000..17fdda8--- /dev/null+++ b/apps/web/components/top-list-item.tsx@@ -0,0 +1,138 @@+"use client";++import { ReactNode } from "react";+import { formatBytes } from "@/lib/utils";+import { cn } from "@/lib/utils";++interface TopListItemProps {+ rank: number;+ icon: ReactNode;+ title: string;+ subtitle?: string;+ value: number;+ total: number;+ color?: string;+ showRank?: boolean;+ valueFormatter?: (value: number) => string;+}++const RANK_COLORS: Record<number, string> = {+ 1: "text-amber-500 bg-amber-500/10",+ 2: "text-slate-400 bg-slate-400/10",+ 3: "text-orange-600 bg-orange-600/10",+};++export function TopListItem({+ rank,+ icon,+ title,+ subtitle,+ value,+ total,+ color = "hsl(var(--primary))",+ showRank = true,+ valueFormatter,+}: TopListItemProps) {+ const percentage = total > 0 ? (value / total) * 100 : 0;+ const isTop3 = rank <= 3;++ const formatValue = (v: number) => {+ if (valueFormatter) return valueFormatter(v);+ return formatBytes(v);+ };++ return (+ <div className="group relative py-2.5 px-2 -mx-2 rounded-lg hover:bg-muted/50 transition-colors">+ <div className="flex items-center gap-3">+ {/* Rank Badge */}+ {showRank && (+ <div+ className={cn(+ "w-6 h-6 rounded-md flex items-center justify-center text-xs font-bold shrink-0",+ isTop3 ? RANK_COLORS[rank] : "text-muted-foreground bg-muted"+ )}+ >+ {rank}+ </div>+ )}++ {/* Icon */}+ <div className="w-8 h-8 rounded-lg bg-muted/50 flex items-center justify-center shrink-0 overflow-hidden">+ {icon}+ </div>++ {/* Content */}+ <div className="flex-1 min-w-0">+ <div className="flex items-center justify-between mb-1">+ <div className="flex items-center gap-2 min-w-0">+ <span className="text-sm font-medium truncate" title={title}>+ {title}+ </span>+ {subtitle && (+ <span className="text-xs text-muted-foreground hidden sm:inline">+ {subtitle}+ </span>+ )}+ </div>+ <span className="text-sm font-semibold tabular-nums shrink-0 ml-2">+ {formatValue(value)}+ </span>+ </div>++ {/* Progress Bar */}+ <div className="h-1.5 bg-muted rounded-full overflow-hidden">+ <div+ className="h-full rounded-full"+ style={{+ width: `${percentage}%`,+ backgroundColor: color,+ opacity: 0.7 + (percentage / 100) * 0.3+ }}+ />+ </div>+ </div>+ </div>+ </div>+ );+}++// Compact version for smaller spaces+interface CompactTopItemProps {+ rank: number;+ icon: ReactNode;+ title: string;+ value: number;+ color?: string;+}++export function CompactTopItem({+ rank,+ icon,+ title,+ value,+ color = "hsl(var(--primary))",+}: CompactTopItemProps) {+ const isTop3 = rank <= 3;++ return (+ <div className="flex items-center gap-3 py-2">+ <span+ className={cn(+ "w-5 text-xs font-medium",+ isTop3 ? "text-amber-500" : "text-muted-foreground"+ )}+ >+ {rank}+ </span>+ <div className="w-6 h-6 rounded bg-muted/50 flex items-center justify-center shrink-0 overflow-hidden">+ {icon}+ </div>+ <span className="flex-1 text-sm truncate" title={title}>+ {title}+ </span>+ <span className="text-xs text-muted-foreground tabular-nums">+ {formatBytes(value)}+ </span>+ </div>+ );+}diff --git a/apps/web/components/traffic-chart.tsx b/apps/web/components/traffic-chart.tsxnew file mode 100644index 0000000..4c9a129--- /dev/null+++ b/apps/web/components/traffic-chart.tsx@@ -0,0 +1,110 @@+"use client";++import { useMemo } from "react";+import {+ AreaChart,+ Area,+ XAxis,+ YAxis,+ CartesianGrid,+ Tooltip,+ ResponsiveContainer,+} from "recharts";+import { useTranslations } from "next-intl";+import type { HourlyStats } from "@clashstats/shared";+import { formatBytes } from "@/lib/utils";++interface TrafficChartProps {+ data: HourlyStats[];+}++export function TrafficChart({ data }: TrafficChartProps) {+ const t = useTranslations("chart");++ const chartData = useMemo(() => {+ if (!data) return [];+ return data.map((item) => ({+ time: new Date(item.hour).toLocaleTimeString("en-US", {+ hour: "2-digit",+ minute: "2-digit",+ hour12: false,+ }),+ download: item.download,+ upload: item.upload,+ }));+ }, [data]);++ return (+ <div className="h-[300px] w-full">+ <ResponsiveContainer width="100%" height="100%">+ <AreaChart data={chartData} margin={{ top: 10, right: 10, left: 0, bottom: 0 }}>+ <defs>+ <linearGradient id="colorDownload" x1="0" y1="0" x2="0" y2="1">+ <stop offset="5%" stopColor="#3B82F6" stopOpacity={0.3} />+ <stop offset="95%" stopColor="#3B82F6" stopOpacity={0} />+ </linearGradient>+ <linearGradient id="colorUpload" x1="0" y1="0" x2="0" y2="1">+ <stop offset="5%" stopColor="#8B5CF6" stopOpacity={0.3} />+ <stop offset="95%" stopColor="#8B5CF6" stopOpacity={0} />+ </linearGradient>+ </defs>+ <CartesianGrid+ strokeDasharray="3 3"+ stroke="hsl(var(--border))"+ opacity={0.5}+ />+ <XAxis+ dataKey="time"+ stroke="hsl(var(--muted-foreground))"+ fontSize={11}+ tickLine={false}+ axisLine={false}+ tickMargin={8}+ />+ <YAxis+ stroke="hsl(var(--muted-foreground))"+ fontSize={11}+ tickLine={false}+ axisLine={false}+ tickMargin={8}+ tickFormatter={(value) => formatBytes(value, 0)}+ />+ <Tooltip+ contentStyle={{+ backgroundColor: "hsl(var(--card))",+ border: "1px solid hsl(var(--border))",+ borderRadius: "12px",+ color: "hsl(var(--foreground))",+ boxShadow: "0 10px 30px -10px rgba(0, 0, 0, 0.3)",+ }}+ formatter={(value: number, name: string) => [+ formatBytes(value),+ name === "download" ? "Download" : "Upload",+ ]}+ labelStyle={{ color: "hsl(var(--muted-foreground))", marginBottom: "4px" }}+ />+ <Area+ type="monotone"+ dataKey="download"+ name="download"+ stroke="#3B82F6"+ strokeWidth={2}+ fillOpacity={1}+ fill="url(#colorDownload)"+ animationDuration={1000}+ />+ <Area+ type="monotone"+ dataKey="upload"+ name="upload"+ stroke="#8B5CF6"+ strokeWidth={2}+ fillOpacity={1}+ fill="url(#colorUpload)"+ animationDuration={1000}+ />+ </AreaChart>+ </ResponsiveContainer>+ </div>+ );+}diff --git a/apps/web/components/traffic-trend-chart.tsx b/apps/web/components/traffic-trend-chart.tsxnew file mode 100644index 0000000..a5de391--- /dev/null+++ b/apps/web/components/traffic-trend-chart.tsx@@ -0,0 +1,262 @@+"use client";++import React, { useMemo } from "react";+import {+ AreaChart,+ Area,+ XAxis,+ YAxis,+ Tooltip,+ ResponsiveContainer,+ CartesianGrid+} from "recharts";+import { Activity, Clock, BarChart3 } from "lucide-react";+import { useTranslations } from "next-intl";+import { Button } from "@/components/ui/button";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { cn, formatBytes } from "@/lib/utils";+import type { TrafficTrendPoint } from "@clashstats/shared";++type TimeRange = "30m" | "1h" | "24h";++interface TrafficTrendChartProps {+ data: TrafficTrendPoint[];+ timeRange: TimeRange;+ onTimeRangeChange: (range: TimeRange) => void;+ isLoading?: boolean;+}++export const TrafficTrendChart = React.memo(function TrafficTrendChart({+ data,+ timeRange,+ onTimeRangeChange,+ isLoading = false,+}: TrafficTrendChartProps) {+ const t = useTranslations("trend");+ const chartT = useTranslations("chart");++ const timeRangeOptions: { value: TimeRange; label: string }[] = [+ { value: "30m", label: t("30m") },+ { value: "1h", label: t("1h") },+ { value: "24h", label: t("24h") },+ ];++ // Calculate total traffic for the period+ const stats = useMemo(() => {+ if (!data?.length) return { totalDownload: 0, totalUpload: 0 };++ let totalDownload = 0;+ let totalUpload = 0;++ for (const point of data) {+ totalDownload += point.download;+ totalUpload += point.upload;+ }++ return { totalDownload, totalUpload };+ }, [data]);++ // Format data for chart - convert UTC to local time+ const chartData = useMemo(() => {+ return data.map(point => {+ // Append Z to indicate UTC if not present, then convert to local+ const timeStr = point.time.endsWith('Z') ? point.time : point.time + 'Z';+ const date = new Date(timeStr);+ return {+ time: point.time,+ download: point.download,+ upload: point.upload,+ timeLabel: date.toLocaleTimeString(undefined, {+ hour: '2-digit',+ minute: '2-digit',+ hour12: false+ }),+ timestamp: date.getTime(), // for sorting/debugging+ };+ });+ }, [data]);++ // Custom tooltip - show local time+ const CustomTooltip = React.useCallback(({ active, payload }: any) => {+ if (active && payload && payload.length) {+ const dataPoint = payload[0].payload;+ // Append Z to indicate UTC if not present, then convert to local+ const timeStr = dataPoint.time.endsWith('Z') ? dataPoint.time : dataPoint.time + 'Z';+ const date = new Date(timeStr);+ return (+ <div className="bg-popover border border-border rounded-lg p-3 shadow-lg">+ <p className="text-xs text-muted-foreground mb-2">+ {date.toLocaleString(undefined, {+ month: 'short',+ day: 'numeric',+ hour: '2-digit',+ minute: '2-digit',+ })}+ </p>+ <div className="space-y-1">+ <p className="text-sm flex items-center gap-2">+ <span className="w-2 h-2 rounded-full bg-blue-500" />+ <span className="text-muted-foreground">{chartT("download")}:</span>+ <span className="font-medium tabular-nums">{formatBytes(dataPoint.download)}</span>+ </p>+ <p className="text-sm flex items-center gap-2">+ <span className="w-2 h-2 rounded-full bg-purple-500" />+ <span className="text-muted-foreground">{chartT("upload")}:</span>+ <span className="font-medium tabular-nums">{formatBytes(dataPoint.upload)}</span>+ </p>+ <p className="text-sm flex items-center gap-2 pt-1 border-t border-border/50 mt-1">+ <span className="w-2 h-2 rounded-full bg-transparent" />+ <span className="text-muted-foreground">{t("total")}:</span>+ <span className="font-semibold tabular-nums">{formatBytes(dataPoint.download + dataPoint.upload)}</span>+ </p>+ </div>+ </div>+ );+ }+ return null;+ }, [chartT, t]);++ // If no data, show empty state+ if (!isLoading && chartData.length === 0) {+ return (+ <Card className="h-full">+ <CardHeader className="pb-2">+ <CardTitle className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Activity className="w-4 h-4" />+ {t("title")}+ </CardTitle>+ </CardHeader>+ <CardContent>+ <div className="h-[200px] flex items-center justify-center text-muted-foreground text-sm">+ {t("noData")}+ </div>+ </CardContent>+ </Card>+ );+ }++ return (+ <Card className="h-full">+ <CardHeader className="pb-2">+ <div className="flex items-center justify-between flex-wrap gap-3">+ <CardTitle className="text-sm font-semibold text-muted-foreground uppercase tracking-wider flex items-center gap-2">+ <Activity className="w-4 h-4" />+ {t("title")}+ </CardTitle>++ {/* Time range selector */}+ <div className="flex items-center gap-0.5 bg-muted/50 rounded-lg p-0.5">+ {timeRangeOptions.map((option) => (+ <Button+ key={option.value}+ variant="ghost"+ size="sm"+ className={cn(+ "h-7 px-3 text-xs rounded-md transition-all",+ timeRange === option.value+ ? "bg-background shadow-sm text-primary font-medium"+ : "text-muted-foreground hover:text-foreground"+ )}+ onClick={() => onTimeRangeChange(option.value)}+ >+ {option.label}+ </Button>+ ))}+ </div>+ </div>++ {/* Stats summary */}+ <div className="flex items-center gap-6 mt-3 text-xs">+ <div className="flex items-center gap-1.5">+ <Clock className="w-3.5 h-3.5 text-muted-foreground" />+ <span className="text-muted-foreground">{t("totalDownload")}:</span>+ <span className="font-semibold text-blue-500 tabular-nums">{formatBytes(stats.totalDownload)}</span>+ </div>+ <div className="flex items-center gap-1.5">+ <BarChart3 className="w-3.5 h-3.5 text-muted-foreground" />+ <span className="text-muted-foreground">{t("totalUpload")}:</span>+ <span className="font-semibold text-purple-500 tabular-nums">{formatBytes(stats.totalUpload)}</span>+ </div>+ <div className="flex items-center gap-1.5 ml-auto">+ <span className="text-muted-foreground">{t("total")}:</span>+ <span className="font-bold tabular-nums">{formatBytes(stats.totalDownload + stats.totalUpload)}</span>+ </div>+ </div>+ </CardHeader>++ <CardContent className="pt-0">+ <div className="h-[200px] w-full">+ {isLoading && chartData.length === 0 ? (+ <div className="h-full flex items-center justify-center text-muted-foreground">+ <div className="flex items-center gap-2">+ <Activity className="w-4 h-4 animate-pulse" />+ {t("loading")}+ </div>+ </div>+ ) : (+ <ResponsiveContainer width="100%" height="100%">+ <AreaChart+ data={chartData}+ margin={{ top: 10, right: 10, left: 0, bottom: 0 }}+ >+ <defs>+ <linearGradient id="colorDownload" x1="0" y1="0" x2="0" y2="1">+ <stop offset="5%" stopColor="#3b82f6" stopOpacity={0.3}/>+ <stop offset="95%" stopColor="#3b82f6" stopOpacity={0}/>+ </linearGradient>+ <linearGradient id="colorUpload" x1="0" y1="0" x2="0" y2="1">+ <stop offset="5%" stopColor="#a855f7" stopOpacity={0.3}/>+ <stop offset="95%" stopColor="#a855f7" stopOpacity={0}/>+ </linearGradient>+ </defs>+ <CartesianGrid strokeDasharray="3 3" vertical={false} stroke="#888888" strokeOpacity={0.2} />+ <XAxis+ dataKey="timeLabel"+ axisLine={false}+ tickLine={false}+ tick={{ fontSize: 10, fill: '#888888' }}+ interval="preserveStartEnd"+ minTickGap={30}+ />+ <YAxis+ axisLine={false}+ tickLine={false}+ tick={{ fontSize: 10, fill: '#888888' }}+ tickFormatter={(value) => formatBytes(value).replace(' ', '')}+ width={50}+ />+ <Tooltip content={<CustomTooltip />} />+ <Area+ type="monotone"+ dataKey="download"+ stroke="#3b82f6"+ strokeWidth={2}+ fillOpacity={1}+ fill="url(#colorDownload)"+ name={chartT("download")}+ isAnimationActive={false}+ />+ <Area+ type="monotone"+ dataKey="upload"+ stroke="#a855f7"+ strokeWidth={2}+ fillOpacity={1}+ fill="url(#colorUpload)"+ name={chartT("upload")}+ isAnimationActive={false}+ />+ </AreaChart>+ </ResponsiveContainer>+ )}+ </div>+ </CardContent>+ </Card>+ );+}, (prev, next) => {+ return (+ JSON.stringify(prev.data) === JSON.stringify(next.data) &&+ prev.timeRange === next.timeRange &&+ prev.isLoading === next.isLoading+ );+});diff --git a/apps/web/components/ui/alert-dialog.tsx b/apps/web/components/ui/alert-dialog.tsxnew file mode 100644index 0000000..7855f00--- /dev/null+++ b/apps/web/components/ui/alert-dialog.tsx@@ -0,0 +1,140 @@+"use client"++import * as React from "react"+import * as AlertDialogPrimitive from "@radix-ui/react-alert-dialog"+import { cn } from "@/lib/utils"+import { buttonVariants } from "@/components/ui/button"++const AlertDialog = AlertDialogPrimitive.Root++const AlertDialogTrigger = AlertDialogPrimitive.Trigger++const AlertDialogPortal = AlertDialogPrimitive.Portal++const AlertDialogOverlay = React.forwardRef<+ React.ElementRef<typeof AlertDialogPrimitive.Overlay>,+ React.ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Overlay>+>(({ className, ...props }, ref) => (+ <AlertDialogPrimitive.Overlay+ className={cn(+ "fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",+ className+ )}+ {...props}+ ref={ref}+ />+))+AlertDialogOverlay.displayName = AlertDialogPrimitive.Overlay.displayName++const AlertDialogContent = React.forwardRef<+ React.ElementRef<typeof AlertDialogPrimitive.Content>,+ React.ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Content>+>(({ className, ...props }, ref) => (+ <AlertDialogPortal>+ <AlertDialogOverlay />+ <AlertDialogPrimitive.Content+ ref={ref}+ className={cn(+ "fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",+ className+ )}+ {...props}+ />+ </AlertDialogPortal>+))+AlertDialogContent.displayName = AlertDialogPrimitive.Content.displayName++const AlertDialogHeader = ({+ className,+ ...props+}: React.HTMLAttributes<HTMLDivElement>) => (+ <div+ className={cn(+ "flex flex-col space-y-2 text-center sm:text-left",+ className+ )}+ {...props}+ />+)+AlertDialogHeader.displayName = "AlertDialogHeader"++const AlertDialogFooter = ({+ className,+ ...props+}: React.HTMLAttributes<HTMLDivElement>) => (+ <div+ className={cn(+ "flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",+ className+ )}+ {...props}+ />+)+AlertDialogFooter.displayName = "AlertDialogFooter"++const AlertDialogTitle = React.forwardRef<+ React.ElementRef<typeof AlertDialogPrimitive.Title>,+ React.ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Title>+>(({ className, ...props }, ref) => (+ <AlertDialogPrimitive.Title+ ref={ref}+ className={cn("text-lg font-semibold", className)}+ {...props}+ />+))+AlertDialogTitle.displayName = AlertDialogPrimitive.Title.displayName++const AlertDialogDescription = React.forwardRef<+ React.ElementRef<typeof AlertDialogPrimitive.Description>,+ React.ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Description>+>(({ className, ...props }, ref) => (+ <AlertDialogPrimitive.Description+ ref={ref}+ className={cn("text-sm text-muted-foreground", className)}+ {...props}+ />+))+AlertDialogDescription.displayName =+ AlertDialogPrimitive.Description.displayName++const AlertDialogAction = React.forwardRef<+ React.ElementRef<typeof AlertDialogPrimitive.Action>,+ React.ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Action>+>(({ className, ...props }, ref) => (+ <AlertDialogPrimitive.Action+ ref={ref}+ className={cn(buttonVariants(), className)}+ {...props}+ />+))+AlertDialogAction.displayName = AlertDialogPrimitive.Action.displayName++const AlertDialogCancel = React.forwardRef<+ React.ElementRef<typeof AlertDialogPrimitive.Cancel>,+ React.ComponentPropsWithoutRef<typeof AlertDialogPrimitive.Cancel>+>(({ className, ...props }, ref) => (+ <AlertDialogPrimitive.Cancel+ ref={ref}+ className={cn(+ buttonVariants({ variant: "outline" }),+ "mt-2 sm:mt-0",+ className+ )}+ {...props}+ />+))+AlertDialogCancel.displayName = AlertDialogPrimitive.Cancel.displayName++export {+ AlertDialog,+ AlertDialogPortal,+ AlertDialogOverlay,+ AlertDialogTrigger,+ AlertDialogContent,+ AlertDialogHeader,+ AlertDialogFooter,+ AlertDialogTitle,+ AlertDialogDescription,+ AlertDialogAction,+ AlertDialogCancel,+}diff --git a/apps/web/components/ui/badge.tsx b/apps/web/components/ui/badge.tsxnew file mode 100644index 0000000..5a1660a--- /dev/null+++ b/apps/web/components/ui/badge.tsx@@ -0,0 +1,40 @@+import * as React from "react"+import { cva, type VariantProps } from "class-variance-authority"++import { cn } from "@/lib/utils"++const badgeVariants = cva(+ "inline-flex items-center justify-center rounded-full border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 gap-1 transition-[color,box-shadow] focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",+ {+ variants: {+ variant: {+ default:+ "border-transparent bg-primary text-primary-foreground hover:bg-primary/80",+ secondary:+ "border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",+ destructive:+ "border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",+ outline: "text-foreground",+ },+ },+ defaultVariants: {+ variant: "default",+ },+ }+)++function Badge({+ className,+ variant,+ ...props+}: React.ComponentProps<"div"> & VariantProps<typeof badgeVariants>) {+ return (+ <div+ data-slot="badge"+ className={cn(badgeVariants({ variant }), className)}+ {...props}+ />+ )+}++export { Badge, badgeVariants }diff --git a/apps/web/components/ui/button.tsx b/apps/web/components/ui/button.tsxnew file mode 100644index 0000000..21409a0--- /dev/null+++ b/apps/web/components/ui/button.tsx@@ -0,0 +1,60 @@+import * as React from "react"+import { Slot } from "@radix-ui/react-slot"+import { cva, type VariantProps } from "class-variance-authority"++import { cn } from "@/lib/utils"++const buttonVariants = cva(+ "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",+ {+ variants: {+ variant: {+ default: "bg-primary text-primary-foreground hover:bg-primary/90",+ destructive:+ "bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",+ outline:+ "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",+ secondary:+ "bg-secondary text-secondary-foreground hover:bg-secondary/80",+ ghost:+ "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",+ link: "text-primary underline-offset-4 hover:underline",+ },+ size: {+ default: "h-9 px-4 py-2 has-[>svg]:px-3",+ sm: "h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",+ lg: "h-10 rounded-md px-6 has-[>svg]:px-4",+ icon: "size-9",+ "icon-sm": "size-8",+ "icon-lg": "size-10",+ },+ },+ defaultVariants: {+ variant: "default",+ size: "default",+ },+ }+)++function Button({+ className,+ variant,+ size,+ asChild = false,+ ...props+}: React.ComponentProps<"button"> &+ VariantProps<typeof buttonVariants> & {+ asChild?: boolean+ }) {+ const Comp = asChild ? Slot : "button"++ return (+ <Comp+ data-slot="button"+ className={cn(buttonVariants({ variant, size, className }))}+ {...props}+ />+ )+}++export { Button, buttonVariants }diff --git a/apps/web/components/ui/card.tsx b/apps/web/components/ui/card.tsxnew file mode 100644index 0000000..019e9c8--- /dev/null+++ b/apps/web/components/ui/card.tsx@@ -0,0 +1,71 @@+import * as React from "react"++import { cn } from "@/lib/utils"++function Card({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="card"+ className={cn(+ "bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",+ className+ )}+ {...props}+ />+ )+}++function CardHeader({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="card-header"+ className={cn(+ "flex flex-col gap-1.5 px-6",+ className+ )}+ {...props}+ />+ )+}++function CardTitle({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="card-title"+ className={cn("leading-none font-semibold", className)}+ {...props}+ />+ )+}++function CardDescription({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="card-description"+ className={cn("text-muted-foreground text-sm", className)}+ {...props}+ />+ )+}++function CardContent({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="card-content"+ className={cn("px-6", className)}+ {...props}+ />+ )+}++function CardFooter({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="card-footer"+ className={cn("flex items-center px-6", className)}+ {...props}+ />+ )+}++export { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent }diff --git a/apps/web/components/ui/dialog.tsx b/apps/web/components/ui/dialog.tsxnew file mode 100644index 0000000..80d7ad6--- /dev/null+++ b/apps/web/components/ui/dialog.tsx@@ -0,0 +1,158 @@+"use client"++import * as React from "react"+import { XIcon } from "lucide-react"+import { Dialog as DialogPrimitive } from "radix-ui"++import { cn } from "@/lib/utils"+import { Button } from "@/components/ui/button"++function Dialog({+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Root>) {+ return <DialogPrimitive.Root data-slot="dialog" {...props} />+}++function DialogTrigger({+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Trigger>) {+ return <DialogPrimitive.Trigger data-slot="dialog-trigger" {...props} />+}++function DialogPortal({+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Portal>) {+ return <DialogPrimitive.Portal data-slot="dialog-portal" {...props} />+}++function DialogClose({+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Close>) {+ return <DialogPrimitive.Close data-slot="dialog-close" {...props} />+}++function DialogOverlay({+ className,+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Overlay>) {+ return (+ <DialogPrimitive.Overlay+ data-slot="dialog-overlay"+ className={cn(+ "data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",+ className+ )}+ {...props}+ />+ )+}++function DialogContent({+ className,+ children,+ showCloseButton = true,+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Content> & {+ showCloseButton?: boolean+}) {+ return (+ <DialogPortal data-slot="dialog-portal">+ <DialogOverlay />+ <DialogPrimitive.Content+ data-slot="dialog-content"+ className={cn(+ "bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 outline-none sm:max-w-lg",+ className+ )}+ {...props}+ >+ {children}+ {showCloseButton && (+ <DialogPrimitive.Close+ data-slot="dialog-close"+ className="ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4"+ >+ <XIcon />+ <span className="sr-only">Close</span>+ </DialogPrimitive.Close>+ )}+ </DialogPrimitive.Content>+ </DialogPortal>+ )+}++function DialogHeader({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="dialog-header"+ className={cn("flex flex-col gap-2 text-center sm:text-left", className)}+ {...props}+ />+ )+}++function DialogFooter({+ className,+ showCloseButton = false,+ children,+ ...props+}: React.ComponentProps<"div"> & {+ showCloseButton?: boolean+}) {+ return (+ <div+ data-slot="dialog-footer"+ className={cn(+ "flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",+ className+ )}+ {...props}+ >+ {children}+ {showCloseButton && (+ <DialogPrimitive.Close asChild>+ <Button variant="outline">Close</Button>+ </DialogPrimitive.Close>+ )}+ </div>+ )+}++function DialogTitle({+ className,+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Title>) {+ return (+ <DialogPrimitive.Title+ data-slot="dialog-title"+ className={cn("text-lg leading-none font-semibold", className)}+ {...props}+ />+ )+}++function DialogDescription({+ className,+ ...props+}: React.ComponentProps<typeof DialogPrimitive.Description>) {+ return (+ <DialogPrimitive.Description+ data-slot="dialog-description"+ className={cn("text-muted-foreground text-sm", className)}+ {...props}+ />+ )+}++export {+ Dialog,+ DialogClose,+ DialogContent,+ DialogDescription,+ DialogFooter,+ DialogHeader,+ DialogOverlay,+ DialogPortal,+ DialogTitle,+ DialogTrigger,+}diff --git a/apps/web/components/ui/dropdown-menu.tsx b/apps/web/components/ui/dropdown-menu.tsxnew file mode 100644index 0000000..bc51a37--- /dev/null+++ b/apps/web/components/ui/dropdown-menu.tsx@@ -0,0 +1,257 @@+"use client"++import * as React from "react"+import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu"+import { CheckIcon, ChevronRightIcon, CircleIcon } from "lucide-react"++import { cn } from "@/lib/utils"++function DropdownMenu({+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Root>) {+ return <DropdownMenuPrimitive.Root data-slot="dropdown-menu" {...props} />+}++function DropdownMenuPortal({+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Portal>) {+ return (+ <DropdownMenuPrimitive.Portal data-slot="dropdown-menu-portal" {...props} />+ )+}++function DropdownMenuTrigger({+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Trigger>) {+ return (+ <DropdownMenuPrimitive.Trigger+ data-slot="dropdown-menu-trigger"+ {...props}+ />+ )+}++function DropdownMenuContent({+ className,+ sideOffset = 4,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Content>) {+ return (+ <DropdownMenuPrimitive.Portal>+ <DropdownMenuPrimitive.Content+ data-slot="dropdown-menu-content"+ sideOffset={sideOffset}+ className={cn(+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[8rem] overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",+ className+ )}+ {...props}+ />+ </DropdownMenuPrimitive.Portal>+ )+}++function DropdownMenuGroup({+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Group>) {+ return (+ <DropdownMenuPrimitive.Group data-slot="dropdown-menu-group" {...props} />+ )+}++function DropdownMenuItem({+ className,+ inset,+ variant = "default",+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Item> & {+ inset?: boolean+ variant?: "default" | "destructive"+}) {+ return (+ <DropdownMenuPrimitive.Item+ data-slot="dropdown-menu-item"+ data-inset={inset}+ data-variant={variant}+ className={cn(+ "focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ {...props}+ />+ )+}++function DropdownMenuCheckboxItem({+ className,+ children,+ checked,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.CheckboxItem>) {+ return (+ <DropdownMenuPrimitive.CheckboxItem+ data-slot="dropdown-menu-checkbox-item"+ className={cn(+ "focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ checked={checked}+ {...props}+ >+ <span className="pointer-events-none absolute left-2 flex size-3.5 items-center justify-center">+ <DropdownMenuPrimitive.ItemIndicator>+ <CheckIcon className="size-4" />+ </DropdownMenuPrimitive.ItemIndicator>+ </span>+ {children}+ </DropdownMenuPrimitive.CheckboxItem>+ )+}++function DropdownMenuRadioGroup({+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.RadioGroup>) {+ return (+ <DropdownMenuPrimitive.RadioGroup+ data-slot="dropdown-menu-radio-group"+ {...props}+ />+ )+}++function DropdownMenuRadioItem({+ className,+ children,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.RadioItem>) {+ return (+ <DropdownMenuPrimitive.RadioItem+ data-slot="dropdown-menu-radio-item"+ className={cn(+ "focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ {...props}+ >+ <span className="pointer-events-none absolute left-2 flex size-3.5 items-center justify-center">+ <DropdownMenuPrimitive.ItemIndicator>+ <CircleIcon className="size-2 fill-current" />+ </DropdownMenuPrimitive.ItemIndicator>+ </span>+ {children}+ </DropdownMenuPrimitive.RadioItem>+ )+}++function DropdownMenuLabel({+ className,+ inset,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Label> & {+ inset?: boolean+}) {+ return (+ <DropdownMenuPrimitive.Label+ data-slot="dropdown-menu-label"+ data-inset={inset}+ className={cn(+ "px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",+ className+ )}+ {...props}+ />+ )+}++function DropdownMenuSeparator({+ className,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Separator>) {+ return (+ <DropdownMenuPrimitive.Separator+ data-slot="dropdown-menu-separator"+ className={cn("bg-border -mx-1 my-1 h-px", className)}+ {...props}+ />+ )+}++function DropdownMenuShortcut({+ className,+ ...props+}: React.ComponentProps<"span">) {+ return (+ <span+ data-slot="dropdown-menu-shortcut"+ className={cn(+ "text-muted-foreground ml-auto text-xs tracking-widest",+ className+ )}+ {...props}+ />+ )+}++function DropdownMenuSub({+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.Sub>) {+ return <DropdownMenuPrimitive.Sub data-slot="dropdown-menu-sub" {...props} />+}++function DropdownMenuSubTrigger({+ className,+ inset,+ children,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.SubTrigger> & {+ inset?: boolean+}) {+ return (+ <DropdownMenuPrimitive.SubTrigger+ data-slot="dropdown-menu-sub-trigger"+ data-inset={inset}+ className={cn(+ "focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8",+ className+ )}+ {...props}+ >+ {children}+ <ChevronRightIcon className="ml-auto size-4" />+ </DropdownMenuPrimitive.SubTrigger>+ )+}++function DropdownMenuSubContent({+ className,+ ...props+}: React.ComponentProps<typeof DropdownMenuPrimitive.SubContent>) {+ return (+ <DropdownMenuPrimitive.SubContent+ data-slot="dropdown-menu-sub-content"+ className={cn(+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] overflow-hidden rounded-md border p-1 shadow-lg",+ className+ )}+ {...props}+ />+ )+}++export {+ DropdownMenu,+ DropdownMenuPortal,+ DropdownMenuTrigger,+ DropdownMenuContent,+ DropdownMenuGroup,+ DropdownMenuLabel,+ DropdownMenuItem,+ DropdownMenuCheckboxItem,+ DropdownMenuRadioGroup,+ DropdownMenuRadioItem,+ DropdownMenuSeparator,+ DropdownMenuShortcut,+ DropdownMenuSub,+ DropdownMenuSubTrigger,+ DropdownMenuSubContent,+}diff --git a/apps/web/components/ui/input.tsx b/apps/web/components/ui/input.tsxnew file mode 100644index 0000000..d90e4c6--- /dev/null+++ b/apps/web/components/ui/input.tsx@@ -0,0 +1,19 @@+import * as React from "react"++import { cn } from "@/lib/utils"++function Input({ className, type, ...props }: React.ComponentProps<"input">) {+ return (+ <input+ type={type}+ data-slot="input"+ className={cn(+ "border-input file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground aria-invalid:outline-destructive/60 aria-invalid:ring-destructive/20 dark:aria-invalid:outline-destructive dark:aria-invalid:ring-destructive/50 flex h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50",+ className+ )}+ {...props}+ />+ )+}++export { Input }diff --git a/apps/web/components/ui/label.tsx b/apps/web/components/ui/label.tsxnew file mode 100644index 0000000..c19ed5c--- /dev/null+++ b/apps/web/components/ui/label.tsx@@ -0,0 +1,24 @@+"use client"++import * as React from "react"+import { cva, type VariantProps } from "class-variance-authority"+import { cn } from "@/lib/utils"++const labelVariants = cva(+ "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"+)++const Label = React.forwardRef<+ HTMLLabelElement,+ React.LabelHTMLAttributes<HTMLLabelElement> &+ VariantProps<typeof labelVariants>+>(({ className, ...props }, ref) => (+ <label+ ref={ref}+ className={cn(labelVariants(), className)}+ {...props}+ />+))+Label.displayName = "Label"++export { Label }diff --git a/apps/web/components/ui/pagination.tsx b/apps/web/components/ui/pagination.tsxnew file mode 100644index 0000000..e46d9ab--- /dev/null+++ b/apps/web/components/ui/pagination.tsx@@ -0,0 +1,118 @@+import * as React from "react"+import { ChevronLeft, ChevronRight, MoreHorizontal } from "lucide-react"++import { cn } from "@/lib/utils"+import { buttonVariants } from "@/components/ui/button"++const Pagination = ({ className, ...props }: React.ComponentProps<"nav">) => (+ <nav+ role="navigation"+ aria-label="pagination"+ className={cn("mx-auto flex w-full justify-center", className)}+ {...props}+ />+)+Pagination.displayName = "Pagination"++const PaginationContent = React.forwardRef<+ HTMLUListElement,+ React.ComponentProps<"ul">+>(({ className, ...props }, ref) => (+ <ul+ ref={ref}+ className={cn("flex flex-row items-center gap-1", className)}+ {...props}+ />+))+PaginationContent.displayName = "PaginationContent"++const PaginationItem = React.forwardRef<+ HTMLLIElement,+ React.ComponentProps<"li">+>(({ className, ...props }, ref) => (+ <li ref={ref} className={cn("", className)} {...props} />+))+PaginationItem.displayName = "PaginationItem"++type PaginationLinkProps = {+ isActive?: boolean+ size?: "default" | "sm" | "lg" | "icon"+} & React.ComponentProps<"a">++const PaginationLink = ({+ className,+ isActive,+ size = "icon",+ ...props+}: PaginationLinkProps) => (+ <a+ aria-current={isActive ? "page" : undefined}+ className={cn(+ buttonVariants({+ variant: isActive ? "outline" : "ghost",+ size,+ }),+ isActive && "bg-primary text-primary-foreground hover:bg-primary/90",+ className+ )}+ {...props}+ />+)+PaginationLink.displayName = "PaginationLink"++const PaginationPrevious = ({+ className,+ ...props+}: React.ComponentProps<typeof PaginationLink>) => (+ <PaginationLink+ aria-label="Go to previous page"+ size="default"+ className={cn("gap-1 pl-2.5", className)}+ {...props}+ >+ <ChevronLeft className="h-4 w-4" />+ <span>Previous</span>+ </PaginationLink>+)+PaginationPrevious.displayName = "PaginationPrevious"++const PaginationNext = ({+ className,+ ...props+}: React.ComponentProps<typeof PaginationLink>) => (+ <PaginationLink+ aria-label="Go to next page"+ size="default"+ className={cn("gap-1 pr-2.5", className)}+ {...props}+ >+ <span>Next</span>+ <ChevronRight className="h-4 w-4" />+ </PaginationLink>+)+PaginationNext.displayName = "PaginationNext"++const PaginationEllipsis = ({+ className,+ ...props+}: React.ComponentProps<"span">) => (+ <span+ aria-hidden+ className={cn("flex h-9 w-9 items-center justify-center", className)}+ {...props}+ >+ <MoreHorizontal className="h-4 w-4" />+ <span className="sr-only">More pages</span>+ </span>+)+PaginationEllipsis.displayName = "PaginationEllipsis"++export {+ Pagination,+ PaginationContent,+ PaginationEllipsis,+ PaginationItem,+ PaginationLink,+ PaginationNext,+ PaginationPrevious,+}diff --git a/apps/web/components/ui/popover.tsx b/apps/web/components/ui/popover.tsxnew file mode 100644index 0000000..a0ec48b--- /dev/null+++ b/apps/web/components/ui/popover.tsx@@ -0,0 +1,31 @@+"use client"++import * as React from "react"+import * as PopoverPrimitive from "@radix-ui/react-popover"++import { cn } from "@/lib/utils"++const Popover = PopoverPrimitive.Root++const PopoverTrigger = PopoverPrimitive.Trigger++const PopoverContent = React.forwardRef<+ React.ElementRef<typeof PopoverPrimitive.Content>,+ React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content>+>(({ className, align = "center", sideOffset = 4, ...props }, ref) => (+ <PopoverPrimitive.Portal>+ <PopoverPrimitive.Content+ ref={ref}+ align={align}+ sideOffset={sideOffset}+ className={cn(+ "z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",+ className+ )}+ {...props}+ />+ </PopoverPrimitive.Portal>+))+PopoverContent.displayName = PopoverPrimitive.Content.displayName++export { Popover, PopoverTrigger, PopoverContent }diff --git a/apps/web/components/ui/select.tsx b/apps/web/components/ui/select.tsxnew file mode 100644index 0000000..d62eca4--- /dev/null+++ b/apps/web/components/ui/select.tsx@@ -0,0 +1,181 @@+"use client"++import * as React from "react"+import * as SelectPrimitive from "@radix-ui/react-select"+import { CheckIcon, ChevronDownIcon, ChevronUpIcon } from "lucide-react"++import { cn } from "@/lib/utils"++function Select({+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Root>) {+ return <SelectPrimitive.Root data-slot="select" {...props} />+}++function SelectGroup({+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Group>) {+ return <SelectPrimitive.Group data-slot="select-group" {...props} />+}++function SelectValue({+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Value>) {+ return <SelectPrimitive.Value data-slot="select-value" {...props} />+}++function SelectTrigger({+ className,+ children,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Trigger>) {+ return (+ <SelectPrimitive.Trigger+ data-slot="select-trigger"+ className={cn(+ "border-input data-[placeholder]:text-muted-foreground aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive flex h-9 w-full items-center justify-between rounded-md border bg-transparent px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",+ className+ )}+ {...props}+ >+ {children}+ <SelectPrimitive.Icon asChild>+ <ChevronDownIcon className="size-4 opacity-50" />+ </SelectPrimitive.Icon>+ </SelectPrimitive.Trigger>+ )+}++function SelectContent({+ className,+ children,+ position = "popper",+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Content>) {+ return (+ <SelectPrimitive.Portal>+ <SelectPrimitive.Content+ data-slot="select-content"+ className={cn(+ "bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-[var(--radix-select-content-available-height)] min-w-[8rem] overflow-x-hidden overflow-y-auto rounded-md border shadow-md",+ position === "popper" &&+ "data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",+ className+ )}+ position={position}+ {...props}+ >+ <SelectScrollUpButton />+ <SelectPrimitive.Viewport+ className={cn(+ "p-1",+ position === "popper" &&+ "h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"+ )}+ >+ {children}+ </SelectPrimitive.Viewport>+ <SelectScrollDownButton />+ </SelectPrimitive.Content>+ </SelectPrimitive.Portal>+ )+}++function SelectLabel({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Label>) {+ return (+ <SelectPrimitive.Label+ data-slot="select-label"+ className={cn("px-2 py-1.5 text-sm font-medium", className)}+ {...props}+ />+ )+}++function SelectItem({+ className,+ children,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Item>) {+ return (+ <SelectPrimitive.Item+ data-slot="select-item"+ className={cn(+ "focus:bg-accent focus:text-accent-foreground relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",+ className+ )}+ {...props}+ >+ <span className="absolute right-2 flex size-3.5 items-center justify-center">+ <SelectPrimitive.ItemIndicator>+ <CheckIcon className="size-4" />+ </SelectPrimitive.ItemIndicator>+ </span>+ <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>+ </SelectPrimitive.Item>+ )+}++function SelectSeparator({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.Separator>) {+ return (+ <SelectPrimitive.Separator+ data-slot="select-separator"+ className={cn("bg-border pointer-events-none -mx-1 my-1 h-px", className)}+ {...props}+ />+ )+}++function SelectScrollUpButton({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {+ return (+ <SelectPrimitive.ScrollUpButton+ data-slot="select-scroll-up-button"+ className={cn(+ "flex cursor-default items-center justify-center py-1",+ className+ )}+ {...props}+ >+ <ChevronUpIcon className="size-4" />+ </SelectPrimitive.ScrollUpButton>+ )+}++function SelectScrollDownButton({+ className,+ ...props+}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {+ return (+ <SelectPrimitive.ScrollDownButton+ data-slot="select-scroll-down-button"+ className={cn(+ "flex cursor-default items-center justify-center py-1",+ className+ )}+ {...props}+ >+ <ChevronDownIcon className="size-4" />+ </SelectPrimitive.ScrollDownButton>+ )+}++export {+ Select,+ SelectContent,+ SelectGroup,+ SelectItem,+ SelectLabel,+ SelectScrollDownButton,+ SelectScrollUpButton,+ SelectSeparator,+ SelectTrigger,+ SelectValue,+}diff --git a/apps/web/components/ui/separator.tsx b/apps/web/components/ui/separator.tsxnew file mode 100644index 0000000..67c73e5--- /dev/null+++ b/apps/web/components/ui/separator.tsx@@ -0,0 +1,28 @@+"use client"++import * as React from "react"+import * as SeparatorPrimitive from "@radix-ui/react-separator"++import { cn } from "@/lib/utils"++function Separator({+ className,+ orientation = "horizontal",+ decorative = true,+ ...props+}: React.ComponentProps<typeof SeparatorPrimitive.Root>) {+ return (+ <SeparatorPrimitive.Root+ data-slot="separator-root"+ decorative={decorative}+ orientation={orientation}+ className={cn(+ "bg-border shrink-0 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px",+ className+ )}+ {...props}+ />+ )+}++export { Separator }diff --git a/apps/web/components/ui/switch.tsx b/apps/web/components/ui/switch.tsxnew file mode 100644index 0000000..48e0210--- /dev/null+++ b/apps/web/components/ui/switch.tsx@@ -0,0 +1,31 @@+"use client"++import * as React from "react"+import * as SwitchPrimitive from "@radix-ui/react-switch"++import { cn } from "@/lib/utils"++function Switch({+ className,+ ...props+}: React.ComponentProps<typeof SwitchPrimitive.Root>) {+ return (+ <SwitchPrimitive.Root+ data-slot="switch"+ className={cn(+ "peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/50 inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",+ className+ )}+ {...props}+ >+ <SwitchPrimitive.Thumb+ data-slot="switch-thumb"+ className={cn(+ "bg-background pointer-events-none block size-4 rounded-full ring-0 shadow-lg transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0"+ )}+ />+ </SwitchPrimitive.Root>+ )+}++export { Switch }diff --git a/apps/web/components/ui/table.tsx b/apps/web/components/ui/table.tsxnew file mode 100644index 0000000..9c76552--- /dev/null+++ b/apps/web/components/ui/table.tsx@@ -0,0 +1,111 @@+import * as React from "react"++import { cn } from "@/lib/utils"++function Table({ className, ...props }: React.ComponentProps<"table">) {+ return (+ <div+ data-slot="table-container"+ className="relative w-full overflow-x-auto"+ >+ <table+ data-slot="table"+ className={cn("w-full caption-bottom text-sm", className)}+ {...props}+ />+ </div>+ )+}++function TableHeader({ className, ...props }: React.ComponentProps<"thead">) {+ return (+ <thead+ data-slot="table-header"+ className={cn("[&_tr]:border-b", className)}+ {...props}+ />+ )+}++function TableBody({ className, ...props }: React.ComponentProps<"tbody">) {+ return (+ <tbody+ data-slot="table-body"+ className={cn("[&_tr:last-child]:border-0", className)}+ {...props}+ />+ )+}++function TableFooter({ className, ...props }: React.ComponentProps<"tfoot">) {+ return (+ <tfoot+ data-slot="table-footer"+ className={cn(+ "bg-muted/50 border-t font-medium [&>tr]:last:border-b-0",+ className+ )}+ {...props}+ />+ )+}++function TableRow({ className, ...props }: React.ComponentProps<"tr">) {+ return (+ <tr+ data-slot="table-row"+ className={cn(+ "hover:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors",+ className+ )}+ {...props}+ />+ )+}++function TableHead({ className, ...props }: React.ComponentProps<"th">) {+ return (+ <th+ data-slot="table-head"+ className={cn(+ "text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap",+ className+ )}+ {...props}+ />+ )+}++function TableCell({ className, ...props }: React.ComponentProps<"td">) {+ return (+ <td+ data-slot="table-cell"+ className={cn("p-2 align-middle whitespace-nowrap", className)}+ {...props}+ />+ )+}++function TableCaption({+ className,+ ...props+}: React.ComponentProps<"caption">) {+ return (+ <caption+ data-slot="table-caption"+ className={cn("text-muted-foreground mt-4 text-sm", className)}+ {...props}+ />+ )+}++export {+ Table,+ TableHeader,+ TableBody,+ TableFooter,+ TableHead,+ TableRow,+ TableCell,+ TableCaption,+}diff --git a/apps/web/components/ui/tabs.tsx b/apps/web/components/ui/tabs.tsxnew file mode 100644index 0000000..2554d01--- /dev/null+++ b/apps/web/components/ui/tabs.tsx@@ -0,0 +1,66 @@+"use client"++import * as React from "react"+import * as TabsPrimitive from "@radix-ui/react-tabs"++import { cn } from "@/lib/utils"++function Tabs({+ className,+ ...props+}: React.ComponentProps<typeof TabsPrimitive.Root>) {+ return (+ <TabsPrimitive.Root+ data-slot="tabs"+ className={cn("flex flex-col gap-2", className)}+ {...props}+ />+ )+}++function TabsList({+ className,+ ...props+}: React.ComponentProps<typeof TabsPrimitive.List>) {+ return (+ <TabsPrimitive.List+ data-slot="tabs-list"+ className={cn(+ "bg-muted text-muted-foreground inline-flex h-9 w-fit items-center justify-center rounded-lg p-1",+ className+ )}+ {...props}+ />+ )+}++function TabsTrigger({+ className,+ ...props+}: React.ComponentProps<typeof TabsPrimitive.Trigger>) {+ return (+ <TabsPrimitive.Trigger+ data-slot="tabs-trigger"+ className={cn(+ "data-[state=active]:bg-background data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring inline-flex flex-1 items-center justify-center gap-1.5 rounded-md px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm",+ className+ )}+ {...props}+ />+ )+}++function TabsContent({+ className,+ ...props+}: React.ComponentProps<typeof TabsPrimitive.Content>) {+ return (+ <TabsPrimitive.Content+ data-slot="tabs-content"+ className={cn("flex-1 outline-none", className)}+ {...props}+ />+ )+}++export { Tabs, TabsList, TabsTrigger, TabsContent }diff --git a/apps/web/components/world-traffic-map.tsx b/apps/web/components/world-traffic-map.tsxnew file mode 100644index 0000000..e02e1be--- /dev/null+++ b/apps/web/components/world-traffic-map.tsx@@ -0,0 +1,309 @@+"use client";++import { useMemo, useState } from "react";+import {+ ComposableMap,+ Geographies,+ Geography,+ ZoomableGroup,+} from "react-simple-maps";+import { scaleLinear } from "d3-scale";+import { Globe, Info } from "lucide-react";+import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card";+import { formatBytes } from "@/lib/utils";+import type { CountryStats } from "@clashstats/shared";++interface WorldTrafficMapProps {+ data: CountryStats[];+}++// World map GeoJSON URL (lightweight topojson)+const GEO_URL =+ "https://cdn.jsdelivr.net/npm/world-atlas@2/countries-110m.json";++// Country name mappings (ISO code -> GeoJSON name)+const COUNTRY_NAME_MAPPING: Record<string, string> = {+ US: "United States of America",+ CN: "China",+ JP: "Japan",+ SG: "Singapore",+ HK: "Hong Kong",+ TW: "Taiwan",+ KR: "South Korea",+ GB: "United Kingdom",+ DE: "Germany",+ FR: "France",+ NL: "Netherlands",+ CA: "Canada",+ AU: "Australia",+ IN: "India",+ BR: "Brazil",+ RU: "Russia",+ SE: "Sweden",+ CH: "Switzerland",+ IL: "Israel",+ // Add more mappings as needed+};++export function WorldTrafficMap({ data }: WorldTrafficMapProps) {+ const [hoveredCountry, setHoveredCountry] = useState<string | null>(null);+ const [tooltipData, setTooltipData] = useState<{+ country: string;+ traffic: number;+ download: number;+ upload: number;+ connections: number;+ x: number;+ y: number;+ } | null>(null);++ // Calculate total traffic for scaling+ const maxTraffic = useMemo(() => {+ if (!data || data.length === 0) return 1;+ return Math.max(...data.map((d) => d.totalDownload + d.totalUpload));+ }, [data]);++ // Create color scale (light blue to deep purple)+ const colorScale = useMemo(() => {+ return scaleLinear<string>()+ .domain([0, maxTraffic * 0.1, maxTraffic * 0.5, maxTraffic])+ .range(["#e0e7ff", "#818cf8", "#6366f1", "#4f46e5"]);+ }, [maxTraffic]);++ // Create country lookup map+ const countryMap = useMemo(() => {+ const map = new Map<string, CountryStats>();+ if (!data) return map;+ data.forEach((country) => {+ map.set(country.country, country);+ // Also map by full name+ const fullName = COUNTRY_NAME_MAPPING[country.country];+ if (fullName) {+ map.set(fullName, country);+ }+ });+ return map;+ }, [data]);++ // Get color for a geography+ const getFillColor = (geo: any) => {+ const geoName = geo.properties.name;+ const isoCode = geo.properties.ISO_A2 || geo.properties.iso_a2;++ // Try to find country by ISO code first, then by name+ let countryData = countryMap.get(isoCode);+ if (!countryData) {+ countryData = countryMap.get(geoName);+ }++ if (+ countryData &&+ countryData.country !== "LOCAL" &&+ countryData.country !== "Unknown"+ ) {+ const traffic = countryData.totalDownload + countryData.totalUpload;+ return colorScale(traffic);+ }++ // Default color for countries with no data+ return "#f1f5f9";+ };++ // Handle mouse enter+ const handleMouseEnter = (geo: any, event: any) => {+ const geoName = geo.properties.name;+ const isoCode = geo.properties.ISO_A2 || geo.properties.iso_a2;++ let countryData = countryMap.get(isoCode);+ if (!countryData) {+ countryData = countryMap.get(geoName);+ }++ if (countryData && countryData.country !== "LOCAL") {+ const rect = event.target.getBoundingClientRect();+ setTooltipData({+ country: countryData.countryName || countryData.country,+ traffic: countryData.totalDownload + countryData.totalUpload,+ download: countryData.totalDownload,+ upload: countryData.totalUpload,+ connections: countryData.totalConnections,+ x: rect.left + rect.width / 2,+ y: rect.top,+ });+ setHoveredCountry(geoName);+ }+ };++ // Handle mouse leave+ const handleMouseLeave = () => {+ setHoveredCountry(null);+ setTooltipData(null);+ };++ // Get top countries for legend+ const topCountries = useMemo(() => {+ if (!data || data.length === 0) return [];+ return [...data]+ .filter((c) => c.country !== "LOCAL" && c.country !== "Unknown")+ .sort(+ (a, b) =>+ b.totalDownload + b.totalUpload - (a.totalDownload + a.totalUpload),+ )+ .slice(0, 5);+ }, [data]);++ return (+ <Card>+ <CardHeader className="pb-2">+ <CardTitle className="text-lg font-semibold flex items-center gap-2">+ <Globe className="h-5 w-5 text-primary" />+ Global Traffic Distribution+ </CardTitle>+ </CardHeader>+ <CardContent className="space-y-4">+ {/* World Map */}+ <div className="relative aspect-[2/1] w-full bg-slate-50 dark:bg-slate-900/50 rounded-lg overflow-hidden">+ <ComposableMap+ projection="geoMercator"+ projectionConfig={{+ scale: 150,+ center: [0, 40],+ }}+ style={{+ width: "100%",+ height: "100%",+ }}>+ <ZoomableGroup>+ <Geographies geography={GEO_URL}>+ {({ geographies }) =>+ geographies.map((geo) => (+ <Geography+ key={geo.rsmKey}+ geography={geo}+ fill={getFillColor(geo)}+ stroke="#cbd5e1"+ strokeWidth={0.5}+ style={{+ default: {+ outline: "none",+ transition: "all 250ms",+ },+ hover: {+ fill:+ hoveredCountry === geo.properties.name+ ? "#f59e0b"+ : undefined,+ outline: "none",+ cursor: "pointer",+ },+ pressed: {+ outline: "none",+ },+ }}+ onMouseEnter={(event) => handleMouseEnter(geo, event)}+ onMouseLeave={handleMouseLeave}+ />+ ))+ }+ </Geographies>+ </ZoomableGroup>+ </ComposableMap>++ {/* Tooltip */}+ {tooltipData && (+ <div+ className="absolute z-50 pointer-events-none"+ style={{+ left: "50%",+ top: "20px",+ transform: "translateX(-50%)",+ }}>+ <div className="glass-card px-4 py-3 rounded-lg border shadow-lg min-w-[200px]">+ <p className="font-semibold text-sm mb-2">+ {tooltipData.country}+ </p>+ <div className="space-y-1 text-xs">+ <div className="flex justify-between">+ <span className="text-muted-foreground">Total:</span>+ <span className="font-medium">+ {formatBytes(tooltipData.traffic)}+ </span>+ </div>+ <div className="flex justify-between">+ <span className="text-blue-500">↓ Download:</span>+ <span>{formatBytes(tooltipData.download)}</span>+ </div>+ <div className="flex justify-between">+ <span className="text-purple-500">↑ Upload:</span>+ <span>{formatBytes(tooltipData.upload)}</span>+ </div>+ <div className="flex justify-between">+ <span className="text-emerald-500">Connections:</span>+ <span>{tooltipData.connections.toLocaleString()}</span>+ </div>+ </div>+ </div>+ </div>+ )}++ {/* Info hint */}+ <div className="absolute bottom-2 left-2 flex items-center gap-1 text-xs text-muted-foreground bg-background/80 px-2 py-1 rounded">+ <Info className="w-3 h-3" />+ <span>Hover over countries for details</span>+ </div>+ </div>++ {/* Legend */}+ <div className="flex flex-wrap items-center justify-between gap-4">+ {/* Color scale legend */}+ <div className="flex items-center gap-2">+ <span className="text-xs text-muted-foreground">Traffic:</span>+ <div className="flex items-center gap-1">+ <span className="text-xs">Low</span>+ <div className="flex">+ <div+ className="w-6 h-3"+ style={{ backgroundColor: "#e0e7ff" }}+ />+ <div+ className="w-6 h-3"+ style={{ backgroundColor: "#818cf8" }}+ />+ <div+ className="w-6 h-3"+ style={{ backgroundColor: "#6366f1" }}+ />+ <div+ className="w-6 h-3"+ style={{ backgroundColor: "#4f46e5" }}+ />+ </div>+ <span className="text-xs">High</span>+ </div>+ </div>++ {/* Top countries list */}+ <div className="flex flex-wrap gap-3">+ {topCountries.map((country) => {+ const traffic = country.totalDownload + country.totalUpload;+ return (+ <div+ key={country.country}+ className="flex items-center gap-1.5 text-xs">+ <div+ className="w-2 h-2 rounded-full"+ style={{ backgroundColor: colorScale(traffic) }}+ />+ <span className="text-muted-foreground">+ {country.countryName || country.country}+ </span>+ <span className="font-medium">{formatBytes(traffic)}</span>+ </div>+ );+ })}+ </div>+ </div>+ </CardContent>+ </Card>+ );+}diff --git a/apps/web/eslint.config.mjs b/apps/web/eslint.config.mjsnew file mode 100644index 0000000..ffb2243--- /dev/null+++ b/apps/web/eslint.config.mjs@@ -0,0 +1,18 @@+import { defineConfig, globalIgnores } from "eslint/config";+import { default as nextVitals } from "eslint-config-next/core-web-vitals";+import { default as nextTs } from "eslint-config-next/typescript";++const eslintConfig = defineConfig([+ ...nextVitals,+ ...nextTs,+ // Override default ignores of eslint-config-next.+ globalIgnores([+ // Default ignores of eslint-config-next:+ ".next/**",+ "out/**",+ "build/**",+ "next-env.d.ts",+ ]),+]);++export default eslintConfig;diff --git a/apps/web/i18n/request.ts b/apps/web/i18n/request.tsnew file mode 100644index 0000000..4c38fd1--- /dev/null+++ b/apps/web/i18n/request.ts@@ -0,0 +1,15 @@+import { getRequestConfig } from "next-intl/server";+import { routing } from "./routing";++export default getRequestConfig(async ({ requestLocale }) => {+ let locale = await requestLocale;++ if (!locale || !routing.locales.includes(locale as any)) {+ locale = routing.defaultLocale;+ }++ return {+ locale,+ messages: (await import(`../messages/${locale}.json`)).default,+ };+});diff --git a/apps/web/i18n/routing.ts b/apps/web/i18n/routing.tsnew file mode 100644index 0000000..c75e092--- /dev/null+++ b/apps/web/i18n/routing.ts@@ -0,0 +1,9 @@+import { defineRouting } from "next-intl/routing";+import { createNavigation } from "next-intl/navigation";++export const routing = defineRouting({+ locales: ["en", "zh"],+ defaultLocale: "zh",+});++export const { Link, redirect, usePathname, useRouter } = createNavigation(routing);diff --git a/apps/web/lib/api.ts b/apps/web/lib/api.tsnew file mode 100644index 0000000..e42eb71--- /dev/null+++ b/apps/web/lib/api.ts@@ -0,0 +1,250 @@+import type {+ StatsSummary,+ DomainStats,+ IPStats,+ ProxyStats,+ RuleStats,+ CountryStats,+ HourlyStats,+ DailyStats,+ TrafficTrendPoint,+} from "@clashstats/shared";++const API_BASE = "/api";++async function fetchJson<T>(url: string, method: 'GET' | 'POST' | 'PUT' | 'DELETE' = 'GET', body?: any): Promise<T> {+ const options: RequestInit = {+ method,+ headers: {},+ };++ // Only set Content-Type when there's a body+ if (body && method !== 'GET') {+ options.headers = {+ 'Content-Type': 'application/json',+ };+ options.body = JSON.stringify(body);+ }++ console.log(`[API] ${method} ${url}`);+ const res = await fetch(url, options);+ if (!res.ok) {+ console.error(`[API] Error ${res.status}: ${url}`);+ throw new Error(`API error: ${res.status}`);+ }+ return res.json();+}++export interface TimeRange {+ start: string;+ end: string;+}++export interface Backend {+ id: number;+ name: string;+ url: string;+ token: string;+ enabled: boolean;+ is_active: boolean;+ listening: boolean;+ hasToken?: boolean;+ created_at: string;+ updated_at: string;+}++function buildUrl(base: string, params: Record<string, string | number | undefined>): string {+ // Use simple URL construction for client-side relative URLs+ const searchParams = new URLSearchParams();+ Object.entries(params).forEach(([key, value]) => {+ if (value !== undefined && value !== '') {+ searchParams.set(key, String(value));+ }+ });+ const query = searchParams.toString();+ return query ? `${base}?${query}` : base;+}++export const api = {+ // Stats APIs with optional backendId parameter+ getSummary: (backendId?: number, range?: TimeRange) =>+ fetchJson<StatsSummary & { backend: { id: number; name: string; isActive: boolean; listening: boolean } }>(+ buildUrl(`${API_BASE}/stats/summary`, {+ backendId,+ start: range?.start,+ end: range?.end,+ })+ ),++ getGlobalSummary: () =>+ fetchJson<{+ totalConnections: number;+ totalUpload: number;+ totalDownload: number;+ uniqueDomains: number;+ uniqueIPs: number;+ backendCount: number;+ }>(`${API_BASE}/stats/global`),++ getDomains: (backendId?: number, limit = 50, range?: TimeRange) =>+ fetchJson<DomainStats[]>(buildUrl(`${API_BASE}/stats/domains`, {+ backendId,+ limit,+ start: range?.start,+ end: range?.end,+ })),++ getIPs: (backendId?: number, limit = 50, range?: TimeRange) =>+ fetchJson<IPStats[]>(buildUrl(`${API_BASE}/stats/ips`, {+ backendId,+ limit,+ start: range?.start,+ end: range?.end,+ })),++ getProxies: (backendId?: number, limit = 50, range?: TimeRange) =>+ fetchJson<ProxyStats[]>(buildUrl(`${API_BASE}/stats/proxies`, {+ backendId,+ limit,+ start: range?.start,+ end: range?.end,+ })),++ getRules: (backendId?: number, limit = 50, range?: TimeRange) =>+ fetchJson<RuleStats[]>(buildUrl(`${API_BASE}/stats/rules`, {+ backendId,+ limit,+ start: range?.start,+ end: range?.end,+ })),++ getCountries: (backendId?: number, limit = 50, range?: TimeRange) =>+ fetchJson<CountryStats[]>(buildUrl(`${API_BASE}/stats/countries`, {+ backendId,+ limit,+ start: range?.start,+ end: range?.end,+ })),++ getRuleProxies: (backendId?: number) =>+ fetchJson<{ rule: string; proxies: string[] }[]>(+ buildUrl(`${API_BASE}/stats/rule-proxy-map`, { backendId })+ ),++ getHourly: (backendId?: number, hours = 24, range?: TimeRange) =>+ fetchJson<HourlyStats[]>(buildUrl(`${API_BASE}/stats/hourly`, {+ backendId,+ hours,+ start: range?.start,+ end: range?.end,+ })),++ getDaily: (backendId?: number, days = 7) =>+ fetchJson<DailyStats[]>(buildUrl(`${API_BASE}/stats/daily`, { backendId, days })),++ getTrafficTrend: (backendId?: number, minutes = 30) =>+ fetchJson<TrafficTrendPoint[]>(buildUrl(`${API_BASE}/stats/trend`, {+ backendId,+ minutes,+ })),++ getTrafficTrendAggregated: (backendId?: number, minutes = 30, bucketMinutes = 1) =>+ fetchJson<TrafficTrendPoint[]>(+ buildUrl(`${API_BASE}/stats/trend/aggregated`, {+ backendId,+ minutes,+ bucketMinutes,+ })+ ),++ getConnections: (backendId?: number, limit = 100) =>+ fetchJson<Array<{ id: number; domain: string; ip: string; chain: string; upload: number; download: number; timestamp: string }>>(+ buildUrl(`${API_BASE}/stats/connections`, { backendId, limit })+ ),++ search: (q: string) =>+ fetchJson<DomainStats[]>(+ `${API_BASE}/search?q=${encodeURIComponent(q)}`+ ),++ // Backend management+ getBackends: () =>+ fetchJson<Backend[]>(`${API_BASE}/backends`),++ getActiveBackend: () =>+ fetchJson<Backend | { error: string }>(`${API_BASE}/backends/active`),++ getListeningBackends: () =>+ fetchJson<Backend[]>(`${API_BASE}/backends/listening`),++ createBackend: (backend: { name: string; url: string; token?: string }) =>+ fetchJson<{ id: number; isActive?: boolean; message: string }>(`${API_BASE}/backends`, 'POST', backend),++ updateBackend: (id: number, backend: { name?: string; url?: string; token?: string; enabled?: boolean; listening?: boolean }) =>+ fetchJson<{ message: string }>(`${API_BASE}/backends/${id}`, 'PUT', backend),++ deleteBackend: (id: number) =>+ fetchJson<{ message: string }>(`${API_BASE}/backends/${id}`, 'DELETE'),++ setActiveBackend: (id: number) =>+ fetchJson<{ message: string }>(`${API_BASE}/backends/${id}/activate`, 'POST'),++ setBackendListening: (id: number, listening: boolean) =>+ fetchJson<{ message: string }>(`${API_BASE}/backends/${id}/listening`, 'POST', { listening }),++ clearBackendData: (id: number) =>+ fetchJson<{ message: string }>(`${API_BASE}/backends/${id}/clear-data`, 'POST'),++ testBackend: (url: string, token?: string) =>+ fetchJson<{ success: boolean; message: string }>(`${API_BASE}/backends/test`, 'POST', { url, token }),++ // Database management+ getDbStats: () =>+ fetchJson<{ size: number; totalConnectionsCount: number }>(`${API_BASE}/db/stats`),++ clearLogs: (days: number, backendId?: number) =>+ fetchJson<{ message: string; deleted: number }>(`${API_BASE}/db/cleanup`, 'POST', { days, backendId }),++ vacuumDatabase: () =>+ fetchJson<{ message: string }>(`${API_BASE}/db/vacuum`, 'POST'),+};++// Helper functions for time range+export function getPresetTimeRange(preset: '7d' | '30d' | '24h' | 'today'): TimeRange {+ const end = new Date();+ const start = new Date();++ switch (preset) {+ case '7d':+ start.setDate(start.getDate() - 7);+ break;+ case '30d':+ start.setDate(start.getDate() - 30);+ break;+ case '24h':+ start.setHours(start.getHours() - 24);+ break;+ case 'today':+ start.setHours(0, 0, 0, 0);+ break;+ }++ return {+ start: start.toISOString(),+ end: end.toISOString(),+ };+}++export function formatDateTimeForInput(date: Date): string {+ return date.toISOString().slice(0, 16); // YYYY-MM-DDTHH:mm+}++export function formatDateTimeDisplay(isoString: string): string {+ const date = new Date(isoString);+ return date.toLocaleString('zh-CN', {+ month: 'short',+ day: 'numeric',+ hour: '2-digit',+ minute: '2-digit',+ });+}diff --git a/apps/web/lib/utils.ts b/apps/web/lib/utils.tsnew file mode 100644index 0000000..ea6b5bf--- /dev/null+++ b/apps/web/lib/utils.ts@@ -0,0 +1,60 @@+import { clsx, type ClassValue } from "clsx";+import { twMerge } from "tailwind-merge";++export function cn(...inputs: ClassValue[]) {+ return twMerge(clsx(inputs));+}++export function formatBytes(bytes: number, decimals = 2): string {+ if (bytes === 0) return "0 B";++ const k = 1024;+ const dm = decimals < 0 ? 0 : decimals;+ const sizes = ["B", "KB", "MB", "GB", "TB", "PB"];++ const i = Math.floor(Math.log(bytes) / Math.log(k));++ return `${parseFloat((bytes / Math.pow(k, i)).toFixed(dm))} ${sizes[i]}`;+}++export function formatNumber(num: number): string {+ if (num >= 1000000) return (num / 1000000).toFixed(1) + "M";+ if (num >= 1000) return (num / 1000).toFixed(1) + "K";+ return num.toString();+}++export function formatDuration(dateString: string): string {+ const date = new Date(dateString);+ const now = new Date();+ const diff = now.getTime() - date.getTime();++ const seconds = Math.floor(diff / 1000);+ const minutes = Math.floor(seconds / 60);+ const hours = Math.floor(minutes / 60);+ const days = Math.floor(hours / 24);++ if (days > 0) return `${days}d ago`;+ if (hours > 0) return `${hours}h ago`;+ if (minutes > 0) return `${minutes}m ago`;+ return `${seconds}s ago`;+}++export function getDomainColor(domain: string): string {+ const colors = [+ "#18181b",+ "#27272a",+ "#3f3f46",+ "#52525b",+ "#71717a",+ "#a1a1aa",+ "#d4d4d8",+ "#e4e4e7",+ ];++ let hash = 0;+ for (let i = 0; i < domain.length; i++) {+ hash = domain.charCodeAt(i) + ((hash << 5) - hash);+ }++ return colors[Math.abs(hash) % colors.length];+}diff --git a/apps/web/lib/websocket.ts b/apps/web/lib/websocket.tsnew file mode 100644index 0000000..905be46--- /dev/null+++ b/apps/web/lib/websocket.ts@@ -0,0 +1,143 @@+import { useEffect, useRef, useState, useCallback } from 'react';+import type { StatsSummary } from '@clashstats/shared';++export type ConnectionStatus = 'connecting' | 'connected' | 'disconnected' | 'error';++interface WebSocketMessage {+ type: 'stats' | 'ping' | 'pong';+ data?: StatsSummary;+ timestamp: string;+}++interface UseWebSocketOptions {+ onMessage?: (data: StatsSummary) => void;+ onConnect?: () => void;+ onDisconnect?: () => void;+ onError?: (error: Event) => void;+}++export function useStatsWebSocket(options: UseWebSocketOptions = {}) {+ const [status, setStatus] = useState<ConnectionStatus>('disconnected');+ const [lastMessage, setLastMessage] = useState<StatsSummary | null>(null);+ const [latency, setLatency] = useState<number | null>(null);+ const wsRef = useRef<WebSocket | null>(null);+ const reconnectTimerRef = useRef<NodeJS.Timeout | null>(null);+ const pingIntervalRef = useRef<NodeJS.Timeout | null>(null);+ const lastPingTimeRef = useRef<number>(0);+ const reconnectAttemptsRef = useRef<number>(0);+ const maxReconnectAttempts = 5;++ const connect = useCallback(() => {+ if (wsRef.current?.readyState === WebSocket.OPEN) return;+ if (typeof window === 'undefined') return;++ setStatus('connecting');++ // Try multiple possible WebSocket URLs+ const wsUrl = 'ws://localhost:3002';++ console.log('[WebSocket] Connecting to:', wsUrl);++ try {+ const ws = new WebSocket(wsUrl);+ wsRef.current = ws;++ ws.onopen = () => {+ console.log('[WebSocket] Connected successfully');+ setStatus('connected');+ reconnectAttemptsRef.current = 0;+ options.onConnect?.();++ // Start ping interval+ pingIntervalRef.current = setInterval(() => {+ if (ws.readyState === WebSocket.OPEN) {+ lastPingTimeRef.current = Date.now();+ ws.send(JSON.stringify({ type: 'ping', timestamp: new Date().toISOString() }));+ }+ }, 30000);+ };++ ws.onmessage = (event) => {+ try {+ const message = JSON.parse(event.data) as WebSocketMessage;++ if (message.type === 'stats' && message.data) {+ setLastMessage(message.data);+ options.onMessage?.(message.data);+ } else if (message.type === 'pong') {+ if (lastPingTimeRef.current > 0) {+ setLatency(Date.now() - lastPingTimeRef.current);+ }+ }+ } catch (err) {+ console.error('[WebSocket] Failed to parse message:', err);+ }+ };++ ws.onclose = (event) => {+ console.log(`[WebSocket] Disconnected. Code: ${event.code}, Reason: ${event.reason}`);+ setStatus('disconnected');+ options.onDisconnect?.();++ // Clear intervals+ if (pingIntervalRef.current) {+ clearInterval(pingIntervalRef.current);+ pingIntervalRef.current = null;+ }++ // Auto reconnect with exponential backoff+ if (reconnectAttemptsRef.current < maxReconnectAttempts) {+ const delay = Math.min(3000 * Math.pow(2, reconnectAttemptsRef.current), 30000);+ reconnectAttemptsRef.current++;+ console.log(`[WebSocket] Reconnecting in ${delay}ms (attempt ${reconnectAttemptsRef.current})`);++ reconnectTimerRef.current = setTimeout(() => {+ connect();+ }, delay);+ } else {+ console.log('[WebSocket] Max reconnection attempts reached, giving up');+ setStatus('error');+ }+ };++ ws.onerror = (error) => {+ console.error('[WebSocket] Connection error. URL:', wsUrl);+ setStatus('error');+ options.onError?.(error);+ };+ } catch (err) {+ console.error('[WebSocket] Failed to create connection:', err);+ setStatus('error');+ }+ }, [options]);++ const disconnect = useCallback(() => {+ reconnectAttemptsRef.current = maxReconnectAttempts; // Prevent auto reconnect+ if (reconnectTimerRef.current) {+ clearTimeout(reconnectTimerRef.current);+ reconnectTimerRef.current = null;+ }+ if (pingIntervalRef.current) {+ clearInterval(pingIntervalRef.current);+ pingIntervalRef.current = null;+ }+ if (wsRef.current) {+ wsRef.current.close();+ wsRef.current = null;+ }+ setStatus('disconnected');+ }, []);++ useEffect(() => {+ connect();+ return () => disconnect();+ }, [connect, disconnect]);++ return {+ status,+ lastMessage,+ latency,+ connect,+ disconnect,+ };+}diff --git a/apps/web/messages/en.json b/apps/web/messages/en.jsonnew file mode 100644index 0000000..4201c71--- /dev/null+++ b/apps/web/messages/en.json@@ -0,0 +1,230 @@+{+ "metadata": {+ "title": "Clash Master - Traffic Analytics",+ "description": "Real-time traffic statistics and analytics for OpenClash"+ },+ "nav": {+ "overview": "Overview",+ "domains": "Domains",+ "countries": "Countries",+ "proxies": "Proxies",+ "rules": "Rules",+ "network": "Network",+ "settings": "Settings"+ },+ "header": {+ "title": "Clash Master",+ "subtitle": "Modern and beautiful traffic analysis tool for Clash"+ },+ "dashboard": {+ "title": "Dashboard",+ "subtitle": "Real-time traffic monitoring and analytics",+ "refresh": "Refresh",+ "loading": "Loading statistics...",+ "error": "Failed to load statistics",+ "errorHint": "Make sure the collector service is running on port 3001",+ "trafficTrend": "Traffic Trend",+ "topDomainsChart": "Top Domains Chart",+ "proxyDistribution": "Proxy Distribution",+ "domains": "Domains",+ "ips": "IP Addresses",+ "updated": "Updated",+ "justNow": "just now",+ "secondsAgo": "{seconds}s ago",+ "minutesAgo": "{minutes}m ago",+ "hoursAgo": "{hours}h ago",+ "daysAgo": "{days}d ago",+ "autoRefresh": "Auto Refresh",+ "paused": "Paused"+ },+ "stats": {+ "totalDownload": "Total Download",+ "totalUpload": "Total Upload",+ "totalConnections": "Total Connections",+ "uniqueDomains": "Unique Domains",+ "todayDownload": "Today's Download",+ "todayUpload": "Today's Upload",+ "activeConnections": "Active Connections",+ "uniqueIPs": "Unique IPs",+ "total": "Total Traffic",+ "domains": "Domains",+ "rules": "Rules",+ "today": "Today",+ "download": "Download",+ "upload": "Upload",+ "tracked": "tracked"+ },+ "chart": {+ "trafficHistory": "Traffic History (24h)",+ "download": "Download",+ "upload": "Upload"+ },+ "trend": {+ "title": "Traffic Trend",+ "30m": "30 min",+ "1h": "1 hour",+ "24h": "24 hours",+ "totalDownload": "Total DL",+ "totalUpload": "Total UL",+ "total": "Total",+ "noData": "No data",+ "loading": "Loading..."+ },+ "topDomains": {+ "title": "Top Domains",+ "sortByTraffic": "Sort by traffic",+ "sortByConnections": "Sort by connections",+ "viewAll": "View all",+ "connections": "connections"+ },+ "topProxies": {+ "title": "Top Proxies",+ "sortByTraffic": "Sort by traffic",+ "sortByConnections": "Sort by connections",+ "viewAll": "View all"+ },+ "topCountries": {+ "title": "Top Countries",+ "viewAll": "View all"+ },+ "domains": {+ "title": "Top Domains",+ "domainList": "Domain List",+ "ipList": "IP Addresses",+ "search": "Search domains...",+ "noResults": "No domains found",+ "connections": "connections",+ "lastSeen": "Last seen",+ "topDomainsByTraffic": "Top Domains by Traffic",+ "mostBandwidthConsuming": "Most bandwidth-consuming domains",+ "domain": "Domain",+ "download": "Download",+ "upload": "Upload",+ "conn": "Conn",+ "last": "Last",+ "unknown": "Unknown",+ "ips": "IPs",+ "ipCount": "IPs",+ "associatedIPs": "Associated IP Addresses",+ "domainsCount": "domains",+ "showing": "Showing",+ "of": "of",+ "page": "page",+ "total": "Total"+ },+ "ips": {+ "title": "Top IP Addresses",+ "topIPsByTraffic": "Top IP Addresses by Traffic",+ "search": "Search IPs...",+ "noResults": "No IPs found",+ "ip": "IP Address",+ "ipAddress": "IP Address",+ "location": "Location",+ "domains": "Domains",+ "domainCount": "Domains",+ "associatedDomains": "Associated Domains",+ "download": "Download",+ "upload": "Upload",+ "connections": "Connections",+ "ipsCount": "IPs",+ "showing": "Showing",+ "of": "of",+ "page": "page",+ "total": "Total"+ },+ "countries": {+ "title": "Countries",+ "details": "Country Details"+ },+ "proxies": {+ "title": "Proxies"+ },+ "rules": {+ "title": "Rules"+ },+ "network": {+ "title": "Network",+ "comingSoon": "Real-time connection monitoring coming soon..."+ },+ "common": {+ "search": "Search",+ "cancel": "Cancel",+ "close": "Close",+ "save": "Save",+ "loading": "Loading...",+ "error": "Error",+ "retry": "Retry",+ "back": "Back",+ "confirm": "Confirm",+ "edit": "Edit",+ "delete": "Delete"+ },+ "settings": {+ "title": "Settings",+ "appearance": "Appearance",+ "theme": "Theme",+ "language": "Language",+ "darkMode": "Dark Mode",+ "lightMode": "Light Mode",+ "system": "System"+ },+ "theme": {+ "toggle": "Toggle theme",+ "light": "Light",+ "dark": "Dark",+ "system": "System"+ },+ "language": {+ "select": "Select language",+ "en": "English",+ "zh": "中文"+ },+ "backend": {+ "title": "Settings",+ "firstTimeTitle": "Configure OpenClash Backend",+ "firstTimeDescription": "Enter your OpenClash connection information to start monitoring traffic",+ "description": "Manage backend connections and database",+ "backendsTab": "Backends",+ "databaseTab": "Database",+ "name": "Name",+ "host": "Host",+ "port": "Port",+ "token": "Auth Token",+ "useSsl": "Use HTTPS",+ "namePlaceholder": "e.g., Router",+ "tokenPlaceholder": "Optional, if set please fill in",+ "active": "Active",+ "disabled": "Disabled",+ "setActive": "Set Active",+ "testConnection": "Test Connection",+ "addNew": "Add New Backend",+ "addBackend": "Add Backend",+ "saveAndContinue": "Save & Continue",+ "confirmDelete": "Confirm Delete",+ "deleteDescription": "Are you sure you want to delete this backend configuration? This action cannot be undone.",+ "noBackends": "No backend configurations",+ "testSuccess": "Connection successful",+ "testFailed": "Connection failed",+ "databaseStats": "Database Statistics",+ "dbSize": "Database Size",+ "connectionsCount": "Connections Count",+ "clearLogs": "Clear Logs",+ "clearLogsDescription": "Clear old connection logs to free up disk space. This action cannot be undone.",+ "clear1Day": "Clear 1 day ago",+ "clear7Days": "Clear 7 days ago",+ "clear30Days": "Clear 30 days ago",+ "clearAll": "Clear All",+ "confirmClearLogs": "Are you sure you want to clear logs older than {days} days?",+ "confirmClearAllLogs": "Are you sure you want to clear ALL logs? This will delete all historical connection records and cannot be undone.",+ "logsCleared": "Logs cleared successfully",+ "switchSuccess": "Backend switched successfully",+ "switchFailed": "Failed to switch backend",+ "displaying": "Displaying",+ "collecting": "Collecting",+ "collect": "Collect",+ "setDisplay": "Set Display",+ "selectBackend": "Select Backend",+ "manageBackends": "Manage Backends",+ "firstBackendAutoActive": "First backend automatically set as active"+ }+}diff --git a/apps/web/messages/zh.json b/apps/web/messages/zh.jsonnew file mode 100644index 0000000..0999295--- /dev/null+++ b/apps/web/messages/zh.json@@ -0,0 +1,230 @@+{+ "metadata": {+ "title": "Clash Master - 流量分析",+ "description": "OpenClash 实时流量统计与分析"+ },+ "nav": {+ "overview": "概览",+ "domains": "域名",+ "countries": "国家",+ "proxies": "代理",+ "rules": "规则",+ "network": "网络",+ "settings": "设置"+ },+ "header": {+ "title": "Clash Master",+ "subtitle": "现代美观的流量分析工具"+ },+ "dashboard": {+ "title": "仪表盘",+ "subtitle": "实时监控流量使用情况",+ "refresh": "刷新",+ "loading": "加载统计数据...",+ "error": "加载统计数据失败",+ "errorHint": "请确保数据收集服务在 3001 端口运行",+ "trafficTrend": "流量趋势",+ "topDomainsChart": "热门域名图表",+ "proxyDistribution": "代理节点分布",+ "domains": "域名",+ "ips": "IP 地址",+ "updated": "更新",+ "justNow": "刚刚",+ "secondsAgo": "{seconds}秒前",+ "minutesAgo": "{minutes}分钟前",+ "hoursAgo": "{hours}小时前",+ "daysAgo": "{days}天前",+ "autoRefresh": "自动刷新",+ "paused": "已暂停"+ },+ "stats": {+ "totalDownload": "总下载量",+ "totalUpload": "总上传量",+ "totalConnections": "总连接数",+ "uniqueDomains": "独立域名",+ "todayDownload": "今日下载",+ "todayUpload": "今日上传",+ "activeConnections": "活跃连接",+ "uniqueIPs": "独立 IP",+ "total": "总计流量",+ "domains": "域名数",+ "rules": "规则数",+ "today": "今日流量",+ "download": "下载",+ "upload": "上传",+ "tracked": "已追踪"+ },+ "chart": {+ "trafficHistory": "流量趋势 (24小时)",+ "download": "下载",+ "upload": "上传"+ },+ "trend": {+ "title": "流量趋势",+ "30m": "30分钟",+ "1h": "1小时",+ "24h": "24小时",+ "totalDownload": "总下载",+ "totalUpload": "总上传",+ "total": "总计",+ "noData": "暂无数据",+ "loading": "加载中..."+ },+ "topDomains": {+ "title": "Top 域名",+ "sortByTraffic": "按流量排序",+ "sortByConnections": "按连接数排序",+ "viewAll": "查看全部",+ "connections": "连接"+ },+ "topProxies": {+ "title": "Top 代理",+ "sortByTraffic": "按流量排序",+ "sortByConnections": "按连接数排序",+ "viewAll": "查看全部"+ },+ "topCountries": {+ "title": "Top 国家",+ "viewAll": "查看全部"+ },+ "domains": {+ "title": "热门域名",+ "domainList": "域名列表",+ "ipList": "IP 地址",+ "search": "搜索域名...",+ "noResults": "未找到域名",+ "connections": "连接",+ "lastSeen": "最后访问",+ "topDomainsByTraffic": "按流量排序的热门域名",+ "mostBandwidthConsuming": "最消耗带宽的域名",+ "domain": "域名",+ "download": "下载",+ "upload": "上传",+ "conn": "连接",+ "last": "最后",+ "unknown": "未知",+ "ips": "IP数",+ "ipCount": "IP数",+ "associatedIPs": "关联 IP 地址",+ "domainsCount": "个域名",+ "showing": "显示",+ "of": "共",+ "page": "页",+ "total": "总计"+ },+ "ips": {+ "title": "热门 IP 地址",+ "topIPsByTraffic": "按流量排序的热门 IP",+ "search": "搜索 IP...",+ "noResults": "未找到 IP",+ "ip": "IP 地址",+ "ipAddress": "IP 地址",+ "location": "位置",+ "domains": "域名",+ "domainCount": "域名数",+ "associatedDomains": "关联域名",+ "download": "下载",+ "upload": "上传",+ "connections": "连接",+ "ipsCount": "个 IP",+ "showing": "显示",+ "of": "共",+ "page": "页",+ "total": "总计"+ },+ "countries": {+ "title": "国家/地区",+ "details": "国家/地区详情"+ },+ "proxies": {+ "title": "代理节点"+ },+ "rules": {+ "title": "规则"+ },+ "network": {+ "title": "网络",+ "comingSoon": "实时连接监控功能开发中..."+ },+ "common": {+ "search": "搜索",+ "cancel": "取消",+ "close": "关闭",+ "save": "保存",+ "loading": "加载中...",+ "error": "错误",+ "retry": "重试",+ "back": "返回",+ "confirm": "确认",+ "edit": "编辑",+ "delete": "删除"+ },+ "settings": {+ "title": "设置",+ "appearance": "外观",+ "theme": "主题",+ "language": "语言",+ "darkMode": "深色模式",+ "lightMode": "浅色模式",+ "system": "跟随系统"+ },+ "theme": {+ "toggle": "切换主题",+ "light": "浅色",+ "dark": "深色",+ "system": "跟随系统"+ },+ "language": {+ "select": "选择语言",+ "en": "English",+ "zh": "中文"+ },+ "backend": {+ "title": "设置",+ "firstTimeTitle": "配置 OpenClash 后端",+ "firstTimeDescription": "请输入您的 OpenClash 连接信息以开始监控流量",+ "description": "管理后端连接和数据库",+ "backendsTab": "后端管理",+ "databaseTab": "数据库",+ "name": "名称",+ "host": "主机地址",+ "port": "端口",+ "token": "认证令牌",+ "useSsl": "使用 HTTPS",+ "namePlaceholder": "例如:路由器",+ "tokenPlaceholder": "可选,如有设置请填写",+ "active": "当前活跃",+ "disabled": "已禁用",+ "setActive": "设为活跃",+ "testConnection": "测试连接",+ "addNew": "添加新后端",+ "addBackend": "添加后端",+ "saveAndContinue": "保存并继续",+ "confirmDelete": "确认删除",+ "deleteDescription": "确定要删除这个后端配置吗?此操作不可撤销。",+ "noBackends": "暂无后端配置",+ "testSuccess": "连接成功",+ "testFailed": "连接失败",+ "databaseStats": "数据库统计",+ "dbSize": "数据库大小",+ "connectionsCount": "连接记录数",+ "clearLogs": "清理日志",+ "clearLogsDescription": "清理旧的连接日志以释放磁盘空间。此操作不可撤销。",+ "clear1Day": "清理1天前",+ "clear7Days": "清理7天前",+ "clear30Days": "清理30天前",+ "clearAll": "清理全部",+ "confirmClearLogs": "确定要清理{days}天前的日志吗?",+ "confirmClearAllLogs": "确定要清理所有日志吗?此操作将删除所有历史连接记录,不可撤销。",+ "logsCleared": "日志清理成功",+ "switchSuccess": "后端切换成功",+ "switchFailed": "后端切换失败",+ "displaying": "显示中",+ "collecting": "收集中",+ "collect": "收集",+ "setDisplay": "设为显示",+ "selectBackend": "选择后端",+ "manageBackends": "管理后端",+ "firstBackendAutoActive": "第一个后端已自动设为显示"+ }+}diff --git a/apps/web/middleware.ts b/apps/web/middleware.tsnew file mode 100644index 0000000..3dbbd3d--- /dev/null+++ b/apps/web/middleware.ts@@ -0,0 +1,8 @@+import createMiddleware from "next-intl/middleware";+import { routing } from "./i18n/routing";++export default createMiddleware(routing);++export const config = {+ matcher: ["/((?!api|_next|static|.*\\..*).*)"],+};diff --git a/apps/web/next.config.ts b/apps/web/next.config.tsnew file mode 100644index 0000000..c9d81a4--- /dev/null+++ b/apps/web/next.config.ts@@ -0,0 +1,19 @@+import type { NextConfig } from "next";+import createNextIntlPlugin from "next-intl/plugin";++const withNextIntl = createNextIntlPlugin();++const nextConfig: NextConfig = {+ reactStrictMode: true,+ output: 'standalone',+ async rewrites() {+ return [+ {+ source: "/api/:path*",+ destination: "http://localhost:3001/api/:path*",+ },+ ];+ },+};++export default withNextIntl(nextConfig);diff --git a/apps/web/package.json b/apps/web/package.jsonnew file mode 100644index 0000000..cf75a91--- /dev/null+++ b/apps/web/package.json@@ -0,0 +1,45 @@+{+ "name": "@clashstats/web",+ "version": "1.0.0",+ "private": true,+ "scripts": {+ "dev": "next dev -p 3000",+ "build": "next build",+ "start": "next start -p 3000",+ "lint": "eslint"+ },+ "dependencies": {+ "@clashstats/shared": "workspace:*",+ "@radix-ui/react-alert-dialog": "^1.1.15",+ "@radix-ui/react-popover": "^1.1.15",+ "class-variance-authority": "^0.7.1",+ "clsx": "^2.1.1",+ "d3-scale": "^4.0.2",+ "lucide-react": "^0.474.0",+ "next": "15.1.6",+ "next-intl": "^3.26.3",+ "next-themes": "^0.4.4",+ "radix-ui": "^1.4.3",+ "react": "19.0.0",+ "react-dom": "19.0.0",+ "react-simple-maps": "^3.0.0",+ "recharts": "^2.15.1",+ "tailwind-merge": "^2.6.0"+ },+ "devDependencies": {+ "@radix-ui/react-dropdown-menu": "^2.1.5",+ "@radix-ui/react-select": "^2.1.5",+ "@radix-ui/react-separator": "^1.1.1",+ "@radix-ui/react-slot": "^1.1.1",+ "@radix-ui/react-switch": "^1.1.2",+ "@radix-ui/react-tabs": "^1.1.2",+ "@tailwindcss/postcss": "^4.0.3",+ "@types/node": "^20",+ "@types/react": "^19",+ "@types/react-dom": "^19",+ "eslint": "^9",+ "eslint-config-next": "15.1.6",+ "tailwindcss": "^4.0.3",+ "typescript": "^5"+ }+}diff --git a/apps/web/postcss.config.mjs b/apps/web/postcss.config.mjsnew file mode 100644index 0000000..61e3684--- /dev/null+++ b/apps/web/postcss.config.mjs@@ -0,0 +1,7 @@+const config = {+ plugins: {+ "@tailwindcss/postcss": {},+ },+};++export default config;diff --git a/apps/web/public/clash-master.png b/apps/web/public/clash-master.pngnew file mode 100644index 0000000..bb76e37Binary files /dev/null and b/apps/web/public/clash-master.png differdiff --git a/apps/web/tsconfig.json b/apps/web/tsconfig.jsonnew file mode 100644index 0000000..2627c60--- /dev/null+++ b/apps/web/tsconfig.json@@ -0,0 +1,42 @@+{+ "compilerOptions": {+ "target": "ES2017",+ "lib": [+ "dom",+ "dom.iterable",+ "esnext"+ ],+ "allowJs": true,+ "skipLibCheck": true,+ "strict": true,+ "noEmit": true,+ "esModuleInterop": true,+ "module": "esnext",+ "moduleResolution": "bundler",+ "resolveJsonModule": true,+ "isolatedModules": true,+ "jsx": "preserve",+ "incremental": true,+ "plugins": [+ {+ "name": "next"+ }+ ],+ "paths": {+ "@/*": [+ "./*"+ ]+ }+ },+ "include": [+ "next-env.d.ts",+ "**/*.ts",+ "**/*.tsx",+ ".next/types/**/*.ts",+ ".next/dev/types/**/*.ts",+ "**/*.mts"+ ],+ "exclude": [+ "node_modules"+ ]+}diff --git a/apps/web/types/modules.d.ts b/apps/web/types/modules.d.tsnew file mode 100644index 0000000..c14c7d9--- /dev/null+++ b/apps/web/types/modules.d.ts@@ -0,0 +1,56 @@+declare module 'react-simple-maps' {+ import * as React from 'react';++ interface ComposableMapProps {+ projection?: string;+ projectionConfig?: object;+ width?: number;+ height?: number;+ style?: React.CSSProperties;+ children?: React.ReactNode;+ }++ interface ZoomableGroupProps {+ center?: [number, number];+ zoom?: number;+ minZoom?: number;+ maxZoom?: number;+ onMoveEnd?: (event: { coordinates: [number, number]; zoom: number }) => void;+ children?: React.ReactNode;+ }++ interface GeographiesProps {+ geography: string | object;+ children: (props: { geographies: any[] }) => React.ReactNode;+ }++ interface GeographyProps {+ geography: any;+ fill?: string;+ stroke?: string;+ strokeWidth?: number;+ style?: {+ default?: React.CSSProperties;+ hover?: React.CSSProperties;+ pressed?: React.CSSProperties;+ };+ onClick?: (event: any) => void;+ onMouseEnter?: (event: any) => void;+ onMouseLeave?: (event: any) => void;+ }++ export const ComposableMap: React.FC<ComposableMapProps>;+ export const ZoomableGroup: React.FC<ZoomableGroupProps>;+ export const Geographies: React.FC<GeographiesProps>;+ export const Geography: React.FC<GeographyProps>;+}++declare module 'd3-scale' {+ interface ScaleLinear<Output> {+ domain(domain: number[]): ScaleLinear<Output>;+ range(range: Output[]): ScaleLinear<Output>;+ (value: number): Output;+ }++ export function scaleLinear<Output = number>(): ScaleLinear<Output>;+}diff --git a/assets/clash-master-overview.png b/assets/clash-master-overview.pngnew file mode 100644index 0000000..43914fcBinary files /dev/null and b/assets/clash-master-overview.png differdiff --git a/assets/icon-clash-master.png b/assets/icon-clash-master.pngnew file mode 100644index 0000000..bb76e37Binary files /dev/null and b/assets/icon-clash-master.png differdiff --git a/docker-compose.yml b/docker-compose.ymlnew file mode 100644index 0000000..42b2f0f--- /dev/null+++ b/docker-compose.yml@@ -0,0 +1,25 @@+services:+ clash-master:+ build:+ context: .+ dockerfile: Dockerfile+ image: clash-master:latest+ container_name: clash-master+ restart: unless-stopped+ ports:+ - "3000:3000" # Web UI+ - "3001:3001" # API+ - "3002:3002" # WebSocket+ volumes:+ - ./data:/app/data+ environment:+ - NODE_ENV=production+ - API_PORT=3001+ - WS_PORT=3002+ - DB_PATH=/app/data/stats.db+ healthcheck:+ test: ["CMD", "wget", "-q", "--spider", "http://localhost:3001/health"]+ interval: 30s+ timeout: 10s+ retries: 3+ start_period: 40sdiff --git a/docker-start.sh b/docker-start.shnew file mode 100755index 0000000..263aa8f--- /dev/null+++ b/docker-start.sh@@ -0,0 +1,54 @@+#!/bin/sh++set -e++echo "╔════════════════════════════════════════════════════════╗"+echo "║ Clash Master - Starting... ║"+echo "╚════════════════════════════════════════════════════════╝"+echo++# Ensure data directory exists+mkdir -p /app/data++echo "📊 Web UI: http://localhost:3000"+echo "🔌 API: http://localhost:3001"+echo "📡 WebSocket: ws://localhost:3002"+echo++# Start collector in background+echo "🚀 Starting data collector..."+cd /app/apps/collector && node dist/index.js &+COLLECTOR_PID=$!++# Wait for collector to be ready+echo "⏳ Waiting for collector to be ready..."+sleep 3++# Start web frontend (standalone mode)+echo "🌐 Starting web frontend..."+cd /app/apps/web/.next/standalone/apps/web && NODE_ENV=production PORT=3000 node server.js &+WEB_PID=$!++# Wait for web to be ready+echo "⏳ Waiting for web frontend to be ready..."+sleep 3++echo+echo "✅ All services started successfully!"+echo+echo "📝 Access the dashboard at: http://localhost:3000"+echo "🔧 Configure your OpenClash backend in the web UI"+echo++# Handle shutdown+cleanup() {+ echo+ echo "🛑 Shutting down services..."+ kill $WEB_PID $COLLECTOR_PID 2>/dev/null || true+ exit 0+}++trap cleanup SIGTERM SIGINT++# Keep container running+waitdiff --git a/package.json b/package.jsonnew file mode 100644index 0000000..f951f6c--- /dev/null+++ b/package.json@@ -0,0 +1 @@+{"name":"openclash-stats","private":true,"workspaces":["apps/*","packages/*"],"packageManager":"[email protected]","scripts":{"build":"turbo build","dev":"turbo dev","lint":"turbo lint"},"devDependencies":{"turbo":"^2.3.0"}}diff --git a/packages/shared/package.json b/packages/shared/package.jsonnew file mode 100644index 0000000..9f84d59--- /dev/null+++ b/packages/shared/package.json@@ -0,0 +1,20 @@+{+ "name": "@clashstats/shared",+ "version": "1.0.0",+ "type": "module",+ "main": "./dist/index.js",+ "types": "./dist/index.d.ts",+ "exports": {+ ".": {+ "types": "./dist/index.d.ts",+ "default": "./dist/index.js"+ }+ },+ "scripts": {+ "build": "tsc",+ "dev": "tsc --watch"+ },+ "devDependencies": {+ "typescript": "^5.4.0"+ }+}diff --git a/packages/shared/src/index.ts b/packages/shared/src/index.tsnew file mode 100644index 0000000..a0952ed--- /dev/null+++ b/packages/shared/src/index.ts@@ -0,0 +1,168 @@+// OpenClash Connection Metadata+export interface ConnectionMetadata {+ network: string;+ type: string;+ sourceIP: string;+ destinationIP: string;+ sourceGeoIP: string[] | null;+ destinationGeoIP: string[] | null;+ sourceIPASN: string;+ destinationIPASN: string;+ sourcePort: string;+ destinationPort: string;+ inboundIP: string;+ inboundPort: string;+ inboundName: string;+ inboundUser: string;+ host: string;+ dnsMode: string;+ uid: number;+ process: string;+ processPath: string;+ specialProxy: string;+ specialRules: string;+ remoteDestination: string;+ dscp: number;+ sniffHost: string;+}++export interface Connection {+ id: string;+ metadata: ConnectionMetadata;+ upload: number;+ download: number;+ start: string;+ chains: string[];+ providerChains: string[];+ rule: string;+ rulePayload: string;+}++export interface ConnectionsData {+ downloadTotal: number;+ uploadTotal: number;+ connections: Connection[];+ memory?: number;+}++// Aggregated Statistics+export interface DomainStats {+ domain: string;+ ips: string[];+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen: string;+ rules: string[];+ chains: string[];+}++export interface IPStats {+ ip: string;+ domains: string[];+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen: string;+ asn?: string;+ geoIP?: string[];+}++export interface HourlyStats {+ hour: string;+ upload: number;+ download: number;+ connections: number;+}++export interface TrafficTrendPoint {+ time: string;+ upload: number;+ download: number;+}++export interface DailyStats {+ date: string;+ upload: number;+ download: number;+ connections: number;+}++export interface ProxyStats {+ chain: string;+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen: string;+}++export interface RuleStats {+ rule: string;+ finalProxy: string;+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen: string;+}++export interface RuleProxyMapping {+ rule: string;+ proxy: string;+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+}++export interface CountryStats {+ country: string;+ countryName: string;+ continent: string;+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ lastSeen?: string;+}++// API Response Types+export interface StatsSummary {+ totalUpload: number;+ totalDownload: number;+ totalConnections: number;+ totalDomains: number;+ totalIPs: number;+ totalProxies: number;+ totalRules?: number;+ todayUpload?: number;+ todayDownload?: number;+ activeConnections?: number;+ topDomains: DomainStats[];+ topIPs: IPStats[];+ proxyStats: ProxyStats[];+ ruleStats?: RuleStats[];+ hourlyStats: HourlyStats[];+}++export interface TimeRangeQuery {+ start?: string;+ end?: string;+ limit?: number;+}++// WebSocket Events+export interface StatsUpdateEvent {+ type: 'stats_update';+ data: ConnectionsData;+ timestamp: string;+}++export interface AggregatedUpdateEvent {+ type: 'aggregated_update';+ domains: DomainStats[];+ totalStats: {+ upload: number;+ download: number;+ };+ timestamp: string;+}++export type WebSocketEvent = StatsUpdateEvent | AggregatedUpdateEvent;diff --git a/packages/shared/tsconfig.json b/packages/shared/tsconfig.jsonnew file mode 100644index 0000000..4c41d16--- /dev/null+++ b/packages/shared/tsconfig.json@@ -0,0 +1,19 @@+{+ "compilerOptions": {+ "target": "ES2022",+ "module": "NodeNext",+ "moduleResolution": "NodeNext",+ "lib": ["ES2022"],+ "declaration": true,+ "declarationMap": true,+ "sourceMap": true,+ "outDir": "./dist",+ "rootDir": "./src",+ "strict": true,+ "esModuleInterop": true,+ "skipLibCheck": true,+ "forceConsistentCasingInFileNames": true+ },+ "include": ["src/**/*"],+ "exclude": ["node_modules", "dist"]+}diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlnew file mode 100644index 0000000..a6ae2f4--- /dev/null+++ b/pnpm-lock.yaml@@ -0,0 +1,7020 @@+lockfileVersion: '9.0'++settings:+ autoInstallPeers: true+ excludeLinksFromLockfile: false++importers:++ .:+ devDependencies:+ turbo:+ specifier: ^2.3.0+ version: 2.8.3++ apps/collector:+ dependencies:+ '@clashstats/shared':+ specifier: workspace:*+ version: link:../../packages/shared+ '@fastify/cors':+ specifier: ^9.0.0+ version: 9.0.1+ better-sqlite3:+ specifier: ^9.4.0+ version: 9.6.0+ dotenv:+ specifier: ^16.4.0+ version: 16.6.1+ fastify:+ specifier: ^4.26.0+ version: 4.29.1+ ws:+ specifier: ^8.19.0+ version: 8.19.0+ devDependencies:+ '@types/better-sqlite3':+ specifier: ^7.6.9+ version: 7.6.13+ '@types/node':+ specifier: ^20.11.0+ version: 20.19.31+ '@types/ws':+ specifier: ^8.18.1+ version: 8.18.1+ tsx:+ specifier: ^4.7.0+ version: 4.21.0+ typescript:+ specifier: ^5.4.0+ version: 5.9.3++ apps/web:+ dependencies:+ '@clashstats/shared':+ specifier: workspace:*+ version: link:../../packages/shared+ '@radix-ui/react-alert-dialog':+ specifier: ^1.1.15+ version: 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popover':+ specifier: ^1.1.15+ version: 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ class-variance-authority:+ specifier: ^0.7.1+ version: 0.7.1+ clsx:+ specifier: ^2.1.1+ version: 2.1.1+ d3-scale:+ specifier: ^4.0.2+ version: 4.0.2+ lucide-react:+ specifier: ^0.474.0+ version: 0.474.0([email protected])+ next:+ specifier: 15.1.6+ next-intl:+ specifier: ^3.26.3+ version: 3.26.5([email protected]([email protected]([email protected]))([email protected]))([email protected])+ next-themes:+ specifier: ^0.4.4+ radix-ui:+ specifier: ^1.4.3+ version: 1.4.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react:+ specifier: 19.0.0+ version: 19.0.0+ react-dom:+ specifier: 19.0.0+ version: 19.0.0([email protected])+ react-simple-maps:+ specifier: ^3.0.0+ recharts:+ specifier: ^2.15.1+ tailwind-merge:+ specifier: ^2.6.0+ version: 2.6.1+ devDependencies:+ '@radix-ui/react-dropdown-menu':+ specifier: ^2.1.5+ version: 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-select':+ specifier: ^2.1.5+ version: 2.2.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-separator':+ specifier: ^1.1.1+ version: 1.1.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot':+ specifier: ^1.1.1+ version: 1.2.4(@types/[email protected])([email protected])+ '@radix-ui/react-switch':+ specifier: ^1.1.2+ version: 1.2.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-tabs':+ specifier: ^1.1.2+ version: 1.1.13(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@tailwindcss/postcss':+ specifier: ^4.0.3+ version: 4.1.18+ '@types/node':+ specifier: ^20+ version: 20.19.31+ '@types/react':+ specifier: ^19+ version: 19.2.11+ '@types/react-dom':+ specifier: ^19+ version: 19.2.3(@types/[email protected])+ eslint:+ specifier: ^9+ version: 9.39.2([email protected])+ eslint-config-next:+ specifier: 15.1.6+ tailwindcss:+ specifier: ^4.0.3+ version: 4.1.18+ typescript:+ specifier: ^5+ version: 5.9.3++ packages/shared:+ devDependencies:+ typescript:+ specifier: ^5.4.0+ version: 5.9.3++packages:++ '@alloc/[email protected]':+ resolution: {integrity: sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw==}+ engines: {node: '>=10'}++ '@babel/[email protected]':+ resolution: {integrity: sha512-05WQkdpL9COIMz4LjTxGpPNCdlpyimKppYNoJ5Di5EUObifl8t4tuLuUBBZEpoLYOmfvIWrsp9fCl0HoPRVTdA==}+ engines: {node: '>=6.9.0'}++ '@emnapi/[email protected]':+ resolution: {integrity: sha512-AvT9QFpxK0Zd8J0jopedNm+w/2fIzvtPKPjqyw9jwvBaReTTqPBk9Hixaz7KbjimP+QNz605/XnjFcDAL2pqBg==}++ '@emnapi/[email protected]':+ resolution: {integrity: sha512-mehfKSMWjjNol8659Z8KxEMrdSJDDot5SXMq00dM8BN4o+CLNXQ0xH2V7EchNHV4RmbZLmmPdEaXZc5H2FXmDg==}++ '@emnapi/[email protected]':+ resolution: {integrity: sha512-WI0DdZ8xFSbgMjR1sFsKABJ/C5OnRrjT06JXbZKexJGrDuPTzZdDYfFlsgcCXCyf+suG5QU2e/y1Wo2V/OapLQ==}++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-GZMB+a0mOMZs4MpDbj8RJp4cw+w1WV5NYD6xzgvzUJ5Ek2jerwfO2eADyI6ExDSUED+1X8aMbegahsJi+8mgpw==}+ engines: {node: '>=18'}+ cpu: [ppc64]+ os: [aix]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-pvz8ZZ7ot/RBphf8fv60ljmaoydPU12VuXHImtAs0XhLLw+EXBi2BLe3OYSBslR4rryHvweW5gmkKFwTiFy6KA==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [android]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-DVNI8jlPa7Ujbr1yjU2PfUSRtAUZPG9I1RwW4F4xFB1Imiu2on0ADiI/c3td+KmDtVKNbi+nffGDQMfcIMkwIA==}+ engines: {node: '>=18'}+ cpu: [arm]+ os: [android]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-z8Ank4Byh4TJJOh4wpz8g2vDy75zFL0TlZlkUkEwYXuPSgX8yzep596n6mT7905kA9uHZsf/o2OJZubl2l3M7A==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [android]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-davCD2Zc80nzDVRwXTcQP/28fiJbcOwvdolL0sOiOsbwBa72kegmVU0Wrh1MYrbuCL98Omp5dVhQFWRKR2ZAlg==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [darwin]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-ZxtijOmlQCBWGwbVmwOF/UCzuGIbUkqB1faQRf5akQmxRJ1ujusWsb3CVfk/9iZKr2L5SMU5wPBi1UWbvL+VQA==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [darwin]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-lS/9CN+rgqQ9czogxlMcBMGd+l8Q3Nj1MFQwBZJyoEKI50XGxwuzznYdwcav6lpOGv5BqaZXqvBSiB/kJ5op+g==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [freebsd]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-tAfqtNYb4YgPnJlEFu4c212HYjQWSO/w/h/lQaBK7RbwGIkBOuNKQI9tqWzx7Wtp7bTPaGC6MJvWI608P3wXYA==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [freebsd]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-hYxN8pr66NsCCiRFkHUAsxylNOcAQaxSSkHMMjcpx0si13t1LHFphxJZUiGwojB1a/Hd5OiPIqDdXONia6bhTw==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-vWfq4GaIMP9AIe4yj1ZUW18RDhx6EPQKjwe7n8BbIecFtCQG4CfHGaHuh7fdfq+y3LIA2vGS/o9ZBGVxIDi9hw==}+ engines: {node: '>=18'}+ cpu: [arm]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-MJt5BRRSScPDwG2hLelYhAAKh9imjHK5+NE/tvnRLbIqUWa+0E9N4WNMjmp/kXXPHZGqPLxggwVhz7QP8CTR8w==}+ engines: {node: '>=18'}+ cpu: [ia32]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-lugyF1atnAT463aO6KPshVCJK5NgRnU4yb3FUumyVz+cGvZbontBgzeGFO1nF+dPueHD367a2ZXe1NtUkAjOtg==}+ engines: {node: '>=18'}+ cpu: [loong64]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-nlP2I6ArEBewvJ2gjrrkESEZkB5mIoaTswuqNFRv/WYd+ATtUpe9Y09RnJvgvdag7he0OWgEZWhviS1OTOKixw==}+ engines: {node: '>=18'}+ cpu: [mips64el]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-C92gnpey7tUQONqg1n6dKVbx3vphKtTHJaNG2Ok9lGwbZil6DrfyecMsp9CrmXGQJmZ7iiVXvvZH6Ml5hL6XdQ==}+ engines: {node: '>=18'}+ cpu: [ppc64]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-B5BOmojNtUyN8AXlK0QJyvjEZkWwy/FKvakkTDCziX95AowLZKR6aCDhG7LeF7uMCXEJqwa8Bejz5LTPYm8AvA==}+ engines: {node: '>=18'}+ cpu: [riscv64]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-p4bm9+wsPwup5Z8f4EpfN63qNagQ47Ua2znaqGH6bqLlmJ4bx97Y9JdqxgGZ6Y8xVTixUnEkoKSHcpRlDnNr5w==}+ engines: {node: '>=18'}+ cpu: [s390x]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-uwp2Tip5aPmH+NRUwTcfLb+W32WXjpFejTIOWZFw/v7/KnpCDKG66u4DLcurQpiYTiYwQ9B7KOeMJvLCu/OvbA==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [linux]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-Kj6DiBlwXrPsCRDeRvGAUb/LNrBASrfqAIok+xB0LxK8CHqxZ037viF13ugfsIpePH93mX7xfJp97cyDuTZ3cw==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [netbsd]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-HwGDZ0VLVBY3Y+Nw0JexZy9o/nUAWq9MlV7cahpaXKW6TOzfVno3y3/M8Ga8u8Yr7GldLOov27xiCnqRZf0tCA==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [netbsd]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-DNIHH2BPQ5551A7oSHD0CKbwIA/Ox7+78/AWkbS5QoRzaqlev2uFayfSxq68EkonB+IKjiuxBFoV8ESJy8bOHA==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [openbsd]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-/it7w9Nb7+0KFIzjalNJVR5bOzA9Vay+yIPLVHfIQYG/j+j9VTH84aNB8ExGKPU4AzfaEvN9/V4HV+F+vo8OEg==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [openbsd]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-LRBbCmiU51IXfeXk59csuX/aSaToeG7w48nMwA6049Y4J4+VbWALAuXcs+qcD04rHDuSCSRKdmY63sruDS5qag==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [openharmony]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-kMtx1yqJHTmqaqHPAzKCAkDaKsffmXkPHThSfRwZGyuqyIeBvf08KSsYXl+abf5HDAPMJIPnbBfXvP2ZC2TfHg==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [sunos]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-Yaf78O/B3Kkh+nKABUF++bvJv5Ijoy9AN1ww904rOXZFLWVc5OLOfL56W+C8F9xn5JQZa3UX6m+IktJnIb1Jjg==}+ engines: {node: '>=18'}+ cpu: [arm64]+ os: [win32]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-Iuws0kxo4yusk7sw70Xa2E2imZU5HoixzxfGCdxwBdhiDgt9vX9VUCBhqcwY7/uh//78A1hMkkROMJq9l27oLQ==}+ engines: {node: '>=18'}+ cpu: [ia32]+ os: [win32]++ '@esbuild/[email protected]':+ resolution: {integrity: sha512-sRdU18mcKf7F+YgheI/zGf5alZatMUTKj/jNS6l744f9u3WFu4v7twcUI9vu4mknF4Y9aDlblIie0IM+5xxaqQ==}+ engines: {node: '>=18'}+ cpu: [x64]+ os: [win32]++ '@eslint-community/[email protected]':+ resolution: {integrity: sha512-phrYmNiYppR7znFEdqgfWHXR6NCkZEK7hwWDHZUjit/2/U0r6XvkDl0SYnoM51Hq7FhCGdLDT6zxCCOY1hexsQ==}+ engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}+ peerDependencies:+ eslint: ^6.0.0 || ^7.0.0 || >=8.0.0++ '@eslint-community/[email protected]':+ resolution: {integrity: sha512-EriSTlt5OC9/7SXkRSCAhfSxxoSUgBm33OH+IkwbdpgoqsSsUg7y3uh+IICI/Qg4BBWr3U2i39RpmycbxMq4ew==}+ engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-aw1gNayWpdI/jSYVgzN5pL0cfzU02GT3NBpeT/DXbx1/1x7ZKxFPd9bwrzygx/qiwIQiJ1sw/zD8qY/kRvlGHA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-Kr+LPIUVKz2qkx1HAMH8q1q6azbqBAsXJUxBl/ODDuVPX45Z9DfwB8tPjTi6nNZ8BuM3nbJxC5zCAg5elnBUTQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-q1mjIoW1VX4IvSocvM/vbTiveKC4k9eLrajNEuSsmjymSDEbpGddtpfOoN7YGAqBK3NG+uqo8ia4PDTt8buCYA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-VtAOaymWVfZcmZbp6E2mympDIHvyjXs/12LqWYjVw6qjrfF+VK+fyG33kChz3nnK+SU5/NeHOqrTEHS8sXO3OA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@eslint/[email protected]':+ resolution: {integrity: sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@fastify/[email protected]':+ resolution: {integrity: sha512-LwdXQJjmMD+GwLOkP7TVC68qa+pSSogeWWmznRJ/coyTcfe9qA05AHFSe1eZFwK6q+xVRpChnvFUkf1iYaSZsQ==}++ '@fastify/[email protected]':+ resolution: {integrity: sha512-YY9Ho3ovI+QHIL2hW+9X4XqQjXLjJqsU+sMV/xFsxZkE8p3GNnYVFpoOxF7SsP5ZL76gwvbo3V9L+FIekBGU4Q==}++ '@fastify/[email protected]':+ resolution: {integrity: sha512-wWSvph+29GR783IhmvdwWnN4bUxTD01Vm5Xad4i7i1VuAOItLvbPAb69sb0IQ2N57yprvhNIwAP5B6xfKTmjmQ==}++ '@fastify/[email protected]':+ resolution: {integrity: sha512-aZAXGYo6m22Fk1zZzEUKBvut/CIIQe/BapEORnxiD5Qr0kPHqqI69NtEMCme74h+at72sPhbkb4ZrLd1W3KRLA==}++ '@fastify/[email protected]':+ resolution: {integrity: sha512-fERDVz7topgNjtXsJTTW1JKLy0rhuLRcquYqNR9rF7OcVpCa2OVW49ZPDIhaRRCaUuvVxI+N416xUoF76HNSXA==}++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-C3HlIdsBxszvm5McXlB8PeOEWfBhcGBTZGkGlWc2U0KFY5IwG5OQEuQ8rq52DZmcHDlPLd+YFBK+cZcytwIFWg==}++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-N0bD2kIPInNHUHehXhMke1rBGs1dwqvC9O9KYMyyjK7iXt7GAhnro7UlcuYcGdS/yYOlq0MAVgrow8IbWJwyqg==}++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-0tLRojf/1Go2JgEVm+3Frg9A3IW8bJgKgdO0BN5RkF//ufuz2joZM63Npau2ff3J6lUVYgDSNzNkR+aH3IVfjg==}+ peerDependencies:+ react: '>=16.8.0'+ react-dom: '>=16.8.0'++ '@floating-ui/[email protected]':+ resolution: {integrity: sha512-aGTxbpbg8/b5JfU1HXSrbH3wXZuLPJcNEcZQFMxLs3oSzgtVu6nFPkbbGGUvBcUjKV2YyB9Wxxabo+HEH9tcRQ==}++ '@formatjs/[email protected]':+ resolution: {integrity: sha512-HJnTFeRM2kVFVr5gr5kH1XP6K0JcJtE7Lzvtr3FS/so5f1kpsqqqxy5JF+FRaO6H2qmcMfAUIox7AJteieRtVw==}++ '@formatjs/[email protected]':+ resolution: {integrity: sha512-Yabmi9nSvyOMrlSeGGWDiH7rf3a7sIwplbvo/dlz9WCIjzIQAfy1RMf4S0X3yG724n5Ghu2GmEl5NJIV6O9sZQ==}++ '@formatjs/[email protected]':+ resolution: {integrity: sha512-7kR78cRrPNB4fjGFZg3Rmj5aah8rQj9KPzuLsmcSn4ipLXQvC04keycTI1F7kJYDwIXtT2+7IDEto842CfZBtw==}++ '@formatjs/[email protected]':+ resolution: {integrity: sha512-H13E9Xl+PxBd8D5/6TVUluSpxGNvFSlN/b3coUp0e0JpuWXXnQDiavIpY3NnvSp4xhEMoXyyBvVfdFX8jglOHQ==}++ '@formatjs/[email protected]':+ resolution: {integrity: sha512-af3qATX+m4Rnd9+wHcjJ4w2ijq+rAVP3CCinJQvFv1kgSu1W6jypUmvleJxcewdxmutM8dmIRZFxO/IQBZmP2Q==}++ '@formatjs/[email protected]':+ resolution: {integrity: sha512-XOMO2Hupl0wdd172Y06h6kLpBz6Dv+J4okPLl4LPtzbr8f66WbIoy4ev98EBuZ6ZK4h5ydTN6XneT4QVpD7cdA==}++ '@humanfs/[email protected]':+ resolution: {integrity: sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA==}+ engines: {node: '>=18.18.0'}++ '@humanfs/[email protected]':+ resolution: {integrity: sha512-/zUx+yOsIrG4Y43Eh2peDeKCxlRt/gET6aHfaKpuq267qXdYDFViVHfMaLyygZOnl0kGWxFIgsBy8QFuTLUXEQ==}+ engines: {node: '>=18.18.0'}++ '@humanwhocodes/[email protected]':+ resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==}+ engines: {node: '>=12.22'}++ '@humanwhocodes/[email protected]':+ resolution: {integrity: sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==}+ engines: {node: '>=18.18'}++ '@img/[email protected]':+ resolution: {integrity: sha512-UT4p+iz/2H4twwAoLCqfA9UH5pI6DggwKEGuaPy7nCVQ8ZsiY5PIcrRvD1DzuY3qYL07NtIQcWnBSY/heikIFQ==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-fyHac4jIc1ANYGRDxtiqelIbdWkIuQaI84Mv45KvGRRxSAa7o7d1ZKAOBaYbnepLC1WqxfpimdeWfvqqSGwR2Q==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-XblONe153h0O2zuFfTAbQYAX2JhYmDHeWikp1LM9Hul9gVPjFY427k6dFEcOL72O01QxQsWi761svJ/ev9xEDg==}+ cpu: [arm64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-xnGR8YuZYfJGmWPvmlunFaWJsb9T/AO2ykoP3Fz/0X5XV2aoYBPkX6xqCQvUTKKiLddarLaxpzNe+b1hjeWHAQ==}+ cpu: [x64]+ os: [darwin]++ '@img/[email protected]':+ resolution: {integrity: sha512-9B+taZ8DlyyqzZQnoeIvDVR/2F4EbMepXMc/NdVbkzsJbzkUjhXv/70GQJ7tdLA4YJgNP25zukcxpX2/SueNrA==}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-gvcC4ACAOPRNATg/ov8/MnbxFDJqf/pDePbBnuBDcjsI8PssmjoKMAz4LtLaVi+OnSb5FK/yIOamqDwGmXW32g==}+ cpu: [arm]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-u7Wz6ntiSSgGSGcjZ55im6uvTrOxSIS8/dgoVMoiGE9I6JAfU50yH5BoDlYA1tcuGS7g/QNtetJnxA6QEsCVTA==}+ cpu: [s390x]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-MmWmQ3iPFZr0Iev+BAgVMb3ZyC4KeFc3jFxnNbEPas60e1cIfevbtuyf9nDGIzOaW9PdnDciJm+wFFaTlj5xYw==}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-9Ti+BbTYDcsbp4wfYib8Ctm1ilkugkA/uscUn6UXK1ldpC1JjiXbLfFZtRlBhjPZ5o1NCLiDbg8fhUPKStHoTA==}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-viYN1KX9m+/hGkJtvYYp+CCLgnJXwiQB39damAO7WMdKWlIhmYTfHjwSbQeUK/20vY154mwezd9HflVFM1wVSw==}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-JMVv+AMRyGOHtO1RFBiJy/MBsgz0x4AWrT6QoEVVTyh1E39TrCUpTRI7mx9VksGX4awWASxqCYLCV4wBZHAYxA==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-JTS1eldqZbJxjvKaAkxhZmBqPRGmxgu+qFKSInv8moZ2AmT5Yib3EQ1c6gp493HvrvV8QgdOXdyaIBrhvFhBMQ==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-y/5PCd+mP4CA/sPDKl2961b+C9d+vPAveS33s6Z3zfASk2j5upL6fXVPZi7ztePZ5CuH+1kW8JtvxgbuXHRa4Q==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [s390x]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-opC+Ok5pRNAzuvq1AG0ar+1owsu842/Ab+4qvU879ippJBHvyY5n2mxF1izXqkPYlGuP/M556uh53jRLJmzTWA==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-XrHMZwGQGvJg2V/oRSUfSAfjfPxO+4DkiRh6p2AFjLQztWUuY/o8Mq0eMQVIY7HJ1CDQUJlxGGZRw1a5bqmd1g==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [arm64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-WT+d/cgqKkkKySYmqoZ8y3pxx7lx9vVejxW/W4DOFMYVSkErR+w7mf2u8m/y4+xHe7yY9DAXQMWQhpnMuFfScw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [linux]++ '@img/[email protected]':+ resolution: {integrity: sha512-ykUW4LVGaMcU9lu9thv85CbRMAwfeadCJHRsg2GmeRa/cJxsVY9Rbd57JcMxBkKHag5U/x7TSBpScF4U8ElVzg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [wasm32]++ '@img/[email protected]':+ resolution: {integrity: sha512-T36PblLaTwuVJ/zw/LaH0PdZkRz5rd3SmMHX8GSmR7vtNSP5Z6bQkExdSK7xGWyxLw4sUknBuugTelgw2faBbQ==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [ia32]+ os: [win32]++ '@img/[email protected]':+ resolution: {integrity: sha512-MpY/o8/8kj+EcnxwvrP4aTJSWw/aZ7JIGR4aBeZkZw5B7/Jn+tY9/VNwtcoGmdT7GfggGIU4kygOMSbYnOrAbg==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}+ cpu: [x64]+ os: [win32]++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-2kkt/7niJ6MgEPxF0bYdQ6etZaA+fQvDcLKckhy1yIQOzaoKjBBjSj63/aLVjYE3qhRt5dvM+uUyfCg6UKCBbA==}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-LI9u/+laYG4Ds1TDKSJW2YPrIlcVYOwi2fUC6xB43lueCjgxV4lffOCZCtYFiH6TNOX+tQKXx97T4IKHbhyHEQ==}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==}+ engines: {node: '>=6.0.0'}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==}++ '@jridgewell/[email protected]':+ resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==}++ '@napi-rs/[email protected]':+ resolution: {integrity: sha512-ZVWUcfwY4E/yPitQJl481FjFo3K22D6qF0DuFH6Y/nbnE11GY5uguDxZMGXPQ8WQ0128MXQD7TnfHyK4oWoIJQ==}++ '@next/[email protected]':+ resolution: {integrity: sha512-d9AFQVPEYNr+aqokIiPLNK/MTyt3DWa/dpKveiAaVccUadFbhFEvY6FXYX2LJO2Hv7PHnLBu2oWwB4uBuHjr/w==}++ '@next/[email protected]':+ resolution: {integrity: sha512-+slMxhTgILUntZDGNgsKEYHUvpn72WP1YTlkmEhS51vnVd7S9jEEy0n9YAMcI21vUG4akTw9voWH02lrClt/yw==}++ '@next/[email protected]':+ resolution: {integrity: sha512-u7lg4Mpl9qWpKgy6NzEkz/w0/keEHtOybmIl0ykgItBxEM5mYotS5PmqTpo+Rhg8FiOiWgwr8USxmKQkqLBCrw==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [darwin]++ '@next/[email protected]':+ resolution: {integrity: sha512-x1jGpbHbZoZ69nRuogGL2MYPLqohlhnT9OCU6E6QFewwup+z+M6r8oU47BTeJcWsF2sdBahp5cKiAcDbwwK/lg==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [darwin]++ '@next/[email protected]':+ resolution: {integrity: sha512-jar9sFw0XewXsBzPf9runGzoivajeWJUc/JkfbLTC4it9EhU8v7tCRLH7l5Y1ReTMN6zKJO0kKAGqDk8YSO2bg==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-+n3u//bfsrIaZch4cgOJ3tXCTbSxz0s6brJtU3SzLOvkJlPQMJ+eHVRi6qM2kKKKLuMY+tcau8XD9CJ1OjeSQQ==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-SpuDEXixM3PycniL4iVCLyUyvcl6Lt0mtv3am08sucskpG0tYkW1KlRhTgj4LI5ehyxriVVcfdoxuuP8csi3kQ==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-L4druWmdFSZIIRhF+G60API5sFB7suTbDRhYWSjiw0RbE+15igQvE2g2+S973pMGvwN3guw7cJUjA/TmbPWTHQ==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [linux]++ '@next/[email protected]':+ resolution: {integrity: sha512-s8w6EeqNmi6gdvM19tqKKWbCyOBvXFbndkGHl+c9YrzsLARRdCHsD9S1fMj8gsXm9v8vhC8s3N8rjuC/XrtkEg==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [win32]++ '@next/[email protected]':+ resolution: {integrity: sha512-6xomMuu54FAFxttYr5PJbEfu96godcxBTRk1OhAvJq0/EnmFU/Ybiax30Snis4vdWZ9LGpf7Roy5fSs7v/5ROQ==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [win32]++ '@nodelib/[email protected]':+ resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==}+ engines: {node: '>= 8'}++ '@nodelib/[email protected]':+ resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==}+ engines: {node: '>= 8'}++ '@nodelib/[email protected]':+ resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==}+ engines: {node: '>= 8'}++ '@nolyfill/[email protected]':+ resolution: {integrity: sha512-nn5ozdjYQpUCZlWGuxcJY/KpxkWQs4DcbMCmKojjyrYDEAGy4Ce19NN4v5MduafTwJlbKc99UA8YhSVqq9yPZA==}+ engines: {node: '>=12.4.0'}++ '@pinojs/[email protected]':+ resolution: {integrity: sha512-k2ENnmBugE/rzQfEcdWHcCY+/FM3VLzH9cYEsbdsoqrvzAKRhUZeRNhAZvB8OitQJ1TBed3yqWtdjzS6wJKBwg==}++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-MkKCwxlXTgz6CFoJx3pCwn07GKp36+aZyu/u2Ln2VrA5DcdyCZkASEDBTd8x5whTQQL5CiYf4prXKLcgQdv29g==}++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg==}++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-XM+E4WXl0OqUJFovy6GjmxxFyx9opfCAIUku4dlKRd5YEPqt4kALOkQOp0Of6reHuUkJuiPBEc5k0o4z4lTC8A==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-T4nygeh9YE9dLRPhAHSeOZi7HBXo+0kYIPJXayZfvWOWA0+n3dESrZbjfDPUABkUNym6Hd+f2IR113To8D2GPA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-oTVLkEw5GpdRe29BqJ0LSDFWI3qu0vR1M0mUkOQWDIUnY/QIkLpgDMWuKxP94c2NAC2LGcgVhG1ImF3jkZ5wXw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-F+M1tLhO+mlQaOWspE8Wstg+z6PwxwRd8oQ8IXceWz92kfAmalTRf0EjrouQeo7QssEPfCn05B4Ihs1K9WQ/7w==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Yq6lvO9HQyPwev1onK1daHCHqXVLzPhSVjmsNjCa2Zcxy2f7uJD2itDtxknv6FzAKCwD1qQkeVDmX/cev13n/g==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-V8piFfWapM5OmNCXTzVQY+E1rDa53zY+MQ4Y7356v4fFz6vqCyUtIz2rUD44ZEdwg78/jKmMJHj07+C/Z/rcog==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-wBbpv+NQftHDdG86Qc0pIyXk5IR3tM8Vd0nWLKDcX8nNn4nXFOFwsKuqw2okA/1D/mpaAkmuyndrPJTYDNZtFw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Uu+mSh4agx2ib1uIGPP4/CKNULyajb3p92LsVXmH2EHVMTfZWpll88XJ0j4W0z3f8NK1eYl1+Mf/szHPmcHzyA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Fh9rGN0MoI4ZFUNyfFVNU4y9LUz93u9/0K+yLgA2bwRojxM8JU1DyvvMBabnZPBgMWREAJvU2jjVzq+LrFUglw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-O8morBEW+HsVG28gYDZPTrT9UUovQUlJue5YO836tiTJhuIWBm/zQHc7j388sHWtdH/xUZurK9olD2+pcqx5ww==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-TCglVRtzlffRNxRMEyR36DGBLJpeusFcgMVD9PZEzAKnUs1lKCgX5u9BmC2Yg+LL9MgZDugFFs1Vl+Jp4t/PGw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-1UEWRX6jnOA2y4H5WczZ44gOOjTEmlqv1uNW4GAJEO5+bauCBhv8snY65Iw5/VOS/ghKN9gr2KjnLKxrsvoMVw==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Nqcp+t5cTB8BinFkZgXiMJniQH0PsUt2k51FUhbdfeKvc4ACcG2uQniY/8+h1Yv6Kza4Q7lD7PQV0z0oicE0Mg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-1PLGQEynI/3OX/ftV54COn+3Sud/Mn8vALg2rWnBLnRaGtJDduNW/22XjlGgPdpcIbiQxjKtb7BkcjP00nqfJw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-0rFg/Rj2Q62NCm62jZw0QX7a3sz6QCQU0LpZdNrJX8byRGaGVTqbrW9jAoIAHyMQqsNpeZ81YgSizOt5WXq0Pw==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-t2ODlkXBQyn7jkl6TNaw/MtVEVvIGelJDCG41Okq/KwUsJBwQ4XVZsHAVUkK4mBv3ewiAS3PGuUWuY2BoK4ZUw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-QM70k4Zwjttifr5a4sZFts9fn8FzHYvQ5PiB19O2HsYibaHSVt9fH9rzB0XZo/YcM+b7t/p7lYCT/F5eOeF5yQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-qgTkjNT1CfKMoP0rcasmlH2r1DAiYicWsDsufxl940sT2wHNEWWv6FMWIQXWhVdmC1d/HYfbhQx60KYyAtKxjg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-kGkGegYIdQsOb4XjsfM97rXsiHaBwco+hFI66oO4s9LU+PLAC5oJ7khdOVFxkhsmlbpUqDAvXw11CluXP+jkHg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-YT1GqPSL8kJn20djelMX7/cTRp/Y9w5IZHvfxQTVHrOqa2yMl7i/UfMqKRU5V7mEyKTrUVgJXhNQPVCG8PBLoQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-72F2T+PLlphrqLcAotYPp0uJMr5SjP5SL01wfEspJbru5Zs5vQaSHb4VB3ZMJPimgHHCHG7gMOeOB9H3Hdmtxg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-EB1FktTz5xRRi2Er974AUQZWg2yVBb1yjip38/lgwtCVRd3a+maUoGHN/xs9Yv8SY8QwbSEb+YrxGadVWbEutA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-YB9mTFQvCOAQMHU+C/jVl96WmuWeltyUEpRJJky51huhds5W2FQr1J8D/16sQlf0ozxkPK8uF3niQMdUwZPv5w==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-ycS4rbwURavDPVjCb5iS3aG4lURFDILi6sKI/WITUMZ13gMmn/xGjpLoqBAalhJaDk8I3UbCM5GzKHrnzwHbvg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-/UuCrDBWravcaMix4TdT+qlNdVwOM1Nck9kWx/vafXsdfj1ChfhOdfi3cy9SGBpWgTXwYCuboT/oYpJy3clqfw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-kr0X2+6Yy/vJzLYJUPCZEc8SfQcf+1COFoAqauJm74umQhta9M7lNJHP7QQS3vkvcGLQUbWpMzwrXYwrYztHKA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-0NJQ4LFFUuWkE7Oxf0htBKS6zLkkjBH+hM1uk7Ng705ReR8m/uelduy1DBo0PyBXPKVnBA6YBlU94MBGXrSBCw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-bpIxvq03if6UNwXZ+HTK71JLh4APvnXntDc6XOX8UVq4XQOVl7lwok0AvIl+b8zgCw3fSaVTZMpAPPagXbKmHQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-/jfEwNDdQVBCNvjkGit4h6pMOzq8bHkopq458dPt2lMjx+eBQUohZNG9A7DtO/O5ukSbxuaNGXMjHicgwy6rQQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-9hQc4+GNVtJAIEPEqlYqW5RiYdrr8ea5XQ0ZOnD6fgru+83kqT15mq2OCcbe8KnjRZl5vF3ks69AKz3kh1jrhg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-vPdg/tF6YC/ynuBIJlk1mm7Le0VgW6ub6J2UWnTQ7/D23KXcPI1qy+0vBkgKgd38RCMJavBXpB83HPNFMTb0Fg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-VBKYIYImA5zsxACdisNQ3BjCBfmbGH3kQlnFVqlWU4tXwjy7cGX8ta80BcrO+WJXIn5iBylEH3K6ZTlee//lgQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-7A6S9jSgm/S+7MdtNDSb+IU859vQqJ/QAtcYQcfFC6W8RS4IxIZDldLR0xqCFZ6DCyrQLjLPsxtTNch5jVA4lA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-tAXIa1g3sM5CGpVT0uIbUx/U3Gs5N8T52IICuCtObaos1S8fzsrPXG5WObkQN3S6NVl6wKgPhAIiBGbWnvc97A==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-I30RydO+bnn2PQztvo25tswPH+wFBjehVGtmagkU78yMdwTwVf12wnAOF+AeP8S2N8xD+5UPbGhkUfPyvT+mwQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-0HEb8R9E8A+jZjvmFCy/J4xhbXy3TV+9XSnGJ3KvTtjlIUy/YQ/p6UYZvi7YbeoeXdyU9+Y3scizK6hkY37baA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-sDvqVY4itsKwwSMEe0jtKgfTh+72Sy3gPmQpjqcQneqQ4PFmr/1I0YA+2/puilhggCe2gJcx5EBAYFkWkdpa5g==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-JPYb1GuM1bxfjMRlNLE+BcmBC8onfCi60Blk7OBqi2MLTFdS+8401U4uFjnwkOr49BLmXxLC6JHkvAsx5OJvHw==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Jl+bCv8HxKnlTLVrcDE8zTMJ09R9/ukw4qBs/oZClOfoQk/cOTbDn+NceXfV7j09YPVQUryJPHurafcSg6EVKA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-bByzr1+ep1zk4VubeEVViV592vu2lHE2BZY5OnzehZqOOgogN80+mNtCqPkhn2gklJqOpxWgPoYTSnhBCqpOXQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-7xdcatg7/U+7+Udyoj2zodtI9H/IIopqo+YOIcZOq1nJwXWBZ9p8xiu5llXlekDbZkca79a/fozEYQXIA4sW6A==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-3OSz3TacUWy4WtOXV38DggwxoqJK4+eDkNMl5Z/MJZaoUPaP4/9lf81xXMe1I2ReTAptverZUpbPY4wWwWyL5g==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-5umnS0T8JQzQT6HbPyO7Hh9dgd82NmS36DQr+X/YJ9ctFNCiiQd6IJAYYZ33LUwm8M+taCz5t2ui29fHZc4Y6Q==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-lS1odchhFTeZv3xwHH31YPObmJn8gOg7Lq12inrr0+BH/l3Tsq32VfjqH1oh80ARM3mlkfMic15n0kg4sD1poQ==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-4ol06/1bLoFu1nwUqzdD4Y5RZ9oDdKeiHIsntug54Hcr1pgaHiPqHFEaXI1IFP/EsOfROQZ8Mig9VTIRza6Tjg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-tY7sVt1yL9ozIxvmbtN5qtmH2krXcBCfjEiCgKGLqunJHvgvZG2Pcl2oQ3kbcZARb1BGEHdkLzcYGO8ynVlieg==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-BjasUjixPFdS+NKkypcyyN5Pmg83Olst0+c6vGov0diwTEo6mgdqVR6hxcEgFuh4QrAs7Rc+9KuGJ9TVCj0Zzg==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Qp8WbZOBe+blgpuUT+lw2xheLP8q0oatc9UpmiemEICxGvFLYmHm9QowVZGHtJlGbS6A6yJ3iViad/2cVjnOiA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-Il0+boE7w/XebUHyBjroE+DbByORGR9KKmITzbR7MyQ4akpORYP/ZmbhAr0DG7RmmBqoOnZdy2QlvajJ2QA59g==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-U+UORVEq+cTnRIaostJv9AGdV3G6Y+zbVd+12e18jQ5A3c0xL03IhnHuiU4UV69wolOQp5GfR58NW/EgdQhwOA==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-2dHfToCj/pzca2Ck724OZ5L0EVrr3eHRNsG/b3xQJLA2hZpVCS99bLAX+hm1IHXDEnzU6by5z/5MIY794/a8NQ==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-QTYuDesS0VtuHNNvMh+CjlKJ4LJickCMUAqjlE3+j8w+RlRpwyX3apEQKGFzbZGdo7XNG1tXa+bQqIE7HIXT2w==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-ewrXRDTAqAXlkl6t/fkXWNAhFX9I+CkKlw6zjEwk86RSPKwZr3xpBRso655aqYafwtnbpHLj6toFzmd6xdVptQ==}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-pzJq12tEaaIhqjbzpCuv/OypJY/BPavOofm+dbab+MHLajy277+1lLm6JFcGgF5eskJ6mquGirhXY2GD/8u8Ug==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ '@radix-ui/[email protected]':+ resolution: {integrity: sha512-HPwpGIzkl28mWyZqG52jiqDJ12waP11Pa1lGoiyUkIEuMLBP0oeK/C89esbXrxsky5we7dfd8U58nm0SgAWpVw==}++ '@rtsao/[email protected]':+ resolution: {integrity: sha512-zt6OdqaDoOnJ1ZYsCYGt9YmWzDXl4vQdKTyJev62gFhRGKdx7mcT54V9KIjg+d2wi9EXsPvAPKe7i7WjfVWB8g==}++ '@rushstack/[email protected]':+ resolution: {integrity: sha512-ojSshQPKwVvSMR8yT2L/QtUkV5SXi/IfDiJ4/8d6UbTPjiHVmxZzUAzGD8Tzks1b9+qQkZa0isUOvYObedITaw==}++ '@swc/[email protected]':+ resolution: {integrity: sha512-e2BR4lsJkkRlKZ/qCHPw9ZaSxc0MVUd7gtbtaB7aMvHeJVYe8sOB8DBZkP2DtISHGSku9sCK6T6cnY0CtXrOCQ==}++ '@swc/[email protected]':+ resolution: {integrity: sha512-JQ5TuMi45Owi4/BIMAJBoSQoOJu12oOk/gADqlcUL9JEdHB8vyjUSsxqeNXnmXHjYKMi2WcYtezGEEhqUI/E2g==}++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-DoR7U1P7iYhw16qJ49fgXUlry1t4CpXeErJHnQ44JgTSKMaZUdf17cfn5mHchfJ4KRBZRFA/Coo+MUF5+gOaCQ==}++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-dJHz7+Ugr9U/diKJA0W6N/6/cjI+ZTAoxPf9Iz9BFRF2GzEX8IvXxFIi/dZBloVJX/MZGvRuFA9rqwdiIEZQ0Q==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [android]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-Gc2q4Qhs660bhjyBSKgq6BYvwDz4G+BuyJ5H1xfhmDR3D8HnHCmT/BSkvSL0vQLy/nkMLY20PQ2OoYMO15Jd0A==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [darwin]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-FL5oxr2xQsFrc3X9o1fjHKBYBMD1QZNyc1Xzw/h5Qu4XnEBi3dZn96HcHm41c/euGV+GRiXFfh2hUCyKi/e+yw==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [darwin]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-Fj+RHgu5bDodmV1dM9yAxlfJwkkWvLiRjbhuO2LEtwtlYlBgiAT4x/j5wQr1tC3SANAgD+0YcmWVrj8R9trVMA==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [freebsd]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-Fp+Wzk/Ws4dZn+LV2Nqx3IilnhH51YZoRaYHQsVq3RQvEl+71VGKFpkfHrLM/Li+kt5c0DJe/bHXK1eHgDmdiA==}+ engines: {node: '>= 10'}+ cpu: [arm]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-S0n3jboLysNbh55Vrt7pk9wgpyTTPD0fdQeh7wQfMqLPM/Hrxi+dVsLsPrycQjGKEQk85Kgbx+6+QnYNiHalnw==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-1px92582HkPQlaaCkdRcio71p8bc8i/ap5807tPRDK/uw953cauQBT8c5tVGkOwrHMfc2Yh6UuxaH4vtTjGvHg==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-v3gyT0ivkfBLoZGF9LyHmts0Isc8jHZyVcbzio6Wpzifg/+5ZJpDiRiUhDLkcr7f/r38SWNe7ucxmGW3j3Kb/g==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-bhJ2y2OQNlcRwwgOAGMY0xTFStt4/wyU6pvI6LSuZpRgKQwxTec0/3Scu91O8ir7qCR3AuepQKLU/kX99FouqQ==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [linux]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-LffYTvPjODiP6PT16oNeUQJzNVyJl1cjIebq/rWWBF+3eDst5JGEFSc5cWxyRCJ0Mxl+KyIkqRxk1XPEs9x8TA==}+ engines: {node: '>=14.0.0'}+ cpu: [wasm32]+ bundledDependencies:+ - '@napi-rs/wasm-runtime'+ - '@emnapi/core'+ - '@emnapi/runtime'+ - '@tybys/wasm-util'+ - '@emnapi/wasi-threads'+ - tslib++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-HjSA7mr9HmC8fu6bdsZvZ+dhjyGCLdotjVOgLA2vEqxEBZaQo9YTX4kwgEvPCpRh8o4uWc4J/wEoFzhEmjvPbA==}+ engines: {node: '>= 10'}+ cpu: [arm64]+ os: [win32]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-bJWbyYpUlqamC8dpR7pfjA0I7vdF6t5VpUGMWRkXVE3AXgIZjYUYAK7II1GNaxR8J1SSrSrppRar8G++JekE3Q==}+ engines: {node: '>= 10'}+ cpu: [x64]+ os: [win32]++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-EgCR5tTS5bUSKQgzeMClT6iCY3ToqE1y+ZB0AKldj809QXk1Y+3jB0upOYZrn9aGIzPtUsP7sX4QQ4XtjBB95A==}+ engines: {node: '>= 10'}++ '@tailwindcss/[email protected]':+ resolution: {integrity: sha512-Ce0GFnzAOuPyfV5SxjXGn0CubwGcuDB0zcdaPuCSzAa/2vII24JTkH+I6jcbXLb1ctjZMZZI6OjDaLPJQL1S0g==}++ '@tybys/[email protected]':+ resolution: {integrity: sha512-9tTaPJLSiejZKx+Bmog4uSubteqTvFrVrURwkmHixBo0G4seD0zUxp98E1DzUBJxLQ3NPwXrGKDiVjwx/DpPsg==}++ '@types/[email protected]':+ resolution: {integrity: sha512-NMv9ASNARoKksWtsq/SHakpYAYnhBrQgGD8zkLYk/jaK8jUGn08CfEdTRgYhMypUQAfzSP8W6gNLe0q19/t4VA==}++ '@types/[email protected]':+ resolution: {integrity: sha512-hOLWVbm7uRza0BYXpIIW5pxfrKe0W+D5lrFiAEYR+pb6w3N2SwSMaJbXdUfSEv+dT4MfHBLtn5js0LAWaO6otw==}++ '@types/[email protected]':+ resolution: {integrity: sha512-iO90scth9WAbmgv7ogoq57O9YpKmFBbmoEoCHDB2xMBY0+/KVrqAaCDyCE16dUspeOvIxFFRI+0sEtqDqy2b4A==}++ '@types/[email protected]':+ resolution: {integrity: sha512-NcV1JjO5oDzoK26oMzbILE6HW7uVXOHLQvHshBUW4UMdZGfiY6v5BeQwh9a9tCzv+CeefZQHJt5SRgK154RtiA==}++ '@types/[email protected]':+ resolution: {integrity: sha512-mgLPETlrpVV1YRJIglr4Ez47g7Yxjl1lj7YKsiMCb27VJH9W8NVM6Bb9d8kkpG/uAQS5AmbA48q2IAolKKo1MA==}++ '@types/[email protected]':+ resolution: {integrity: sha512-VMZBYyQvbGmWyWVea0EHs/BwLgxc+MKi1zLDCONksozI4YJMcTt8ZEuIR4Sb1MMTE8MMW49v0IwI5+b7RmfWlg==}++ '@types/[email protected]':+ resolution: {integrity: sha512-dLmtwB8zkAeO/juAMfnV+sItKjlsw2lKdZVVy6LRr0cBmegxSABiLEpGVmSJJ8O08i4+sGR6qQtb6WtuwJdvVw==}++ '@types/[email protected]':+ resolution: {integrity: sha512-lae0iWfcDeR7qt7rA88BNiqdvPS5pFVPpo5OfjElwNaT2yyekbM0C9vK+yqBqEmHr6lDkRnYNoTBYlAgJa7a4w==}++ '@types/[email protected]':+ resolution: {integrity: sha512-yuzZug1nkAAaBlBBikKZTgzCeA+k1uy4ZFwWANOfKw5z5LRhV0gNA7gNkKm7HoK+HRN0wX3EkxGk0fpbWhmB7g==}++ '@types/[email protected]':+ resolution: {integrity: sha512-Ps3T8E8dZDam6fUyNiMkekK3XUsaUEik+idO9/YjPtfj2qruF8tFBXS7XhtE4iIXBLxhmLjP3SXpLhVf21I9Lw==}++ '@types/[email protected]':+ resolution: {integrity: sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==}++ '@types/[email protected]':+ resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==}++ '@types/[email protected]':+ resolution: {integrity: sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ==}++ '@types/[email protected]':+ resolution: {integrity: sha512-5jsi0wpncvTD33Sh1UCgacK37FFwDn+EG7wCmEvs62fCvBL+n8/76cAYDok21NF6+jaVWIqKwCZyX7Vbu8eB3A==}++ '@types/[email protected]':+ resolution: {integrity: sha512-jp2L/eY6fn+KgVVQAOqYItbF0VY/YApe5Mz2F0aykSO8gx31bYCZyvSeYxCHKvzHG5eZjc+zyaS5BrBWya2+kQ==}+ peerDependencies:+ '@types/react': ^19.2.0++ '@types/[email protected]':+ resolution: {integrity: sha512-tORuanb01iEzWvMGVGv2ZDhYZVeRMrw453DCSAIn/5yvcSVnMoUMTyf33nQJLahYEnv9xqrTNbgz4qY5EfSh0g==}++ '@types/[email protected]':+ resolution: {integrity: sha512-ThVF6DCVhA8kUGy+aazFQ4kXQ7E1Ty7A3ypFOe0IcJV8O/M511G99AW24irKrW56Wt44yG9+ij8FaqoBGkuBXg==}++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-hAAP5io/7csFStuOmR782YmTthKBJ9ND3WVL60hcOjvtGFb+HJxH4O5huAcmcZ9v9G8P+JETiZ/G1B8MALnWZQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ '@typescript-eslint/parser': ^8.54.0+ eslint: ^8.57.0 || ^9.0.0+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-BtE0k6cjwjLZoZixN0t5AKP0kSzlGu7FctRXYuPAm//aaiZhmfq1JwdYpYr1brzEspYyFeF+8XF5j2VK6oalrA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-YPf+rvJ1s7MyiWM4uTRhE4DvBXrEV+d8oC3P9Y2eT7S+HBS0clybdMIPnhiATi9vZOYDc7OQ1L/i6ga6NFYK/g==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-27rYVQku26j/PbHYcVfRPonmOlVI6gihHtXFbTdB5sb6qA0wdAQAbyXFVarQ5t4HRojIz64IV90YtsjQSSGlQg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-dRgOyT2hPk/JwxNMZDsIXDgyl9axdJI3ogZ2XWhBPsnZUv+hPesa5iuhdYt2gzwA9t8RE5ytOJ6xB0moV0Ujvw==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-hiLguxJWHjjwL6xMBwD903ciAwd7DmK30Y9Axs/etOkftC3ZNN9K44IuRD/EB08amu+Zw6W37x9RecLkOo3pMA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-PDUI9R1BVjqu7AUDsRBbKMtwmjWcn4J3le+5LpcFgWULN3LvHC5rkc9gCVxbrsrGmO1jfPybN5s6h4Jy+OnkAA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-BUwcskRaPvTk6fzVWgDPdUndLjB87KYDrN5EYGetnktoeAvPtO4ONHlAZDnj5VFnUANg0Sjm7j4usBlnoVMHwA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-9Cnda8GS57AQakvRyG0PTejJNlA2xhvyNtEVIMlDWOOeEyBkYWhGPnfrIAnqxLMTSTo6q8g12XVjjev5l1NvMA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ peerDependencies:+ eslint: ^8.57.0 || ^9.0.0+ typescript: '>=4.8.4 <6.0.0'++ '@typescript-eslint/[email protected]':+ resolution: {integrity: sha512-VFlhGSl4opC0bprJiItPQ1RfUhGDIBokcPwaFH4yiBCaNPeld/9VeXbiPO1cLyorQi1G1vL+ecBk1x8o1axORA==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ '@unrs/[email protected]':+ resolution: {integrity: sha512-ppLRUgHVaGRWUx0R0Ut06Mjo9gBaBkg3v/8AxusGLhsIotbBLuRk51rAzqLC8gq6NyyAojEXglNjzf6R948DNw==}+ cpu: [arm]+ os: [android]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-lCxkVtb4wp1v+EoN+HjIG9cIIzPkX5OtM03pQYkG+U5O/wL53LC4QbIeazgiKqluGeVEeBlZahHalCaBvU1a2g==}+ cpu: [arm64]+ os: [android]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-gPVA1UjRu1Y/IsB/dQEsp2V1pm44Of6+LWvbLc9SDk1c2KhhDRDBUkQCYVWe6f26uJb3fOK8saWMgtX8IrMk3g==}+ cpu: [arm64]+ os: [darwin]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-cFzP7rWKd3lZaCsDze07QX1SC24lO8mPty9vdP+YVa3MGdVgPmFc59317b2ioXtgCMKGiCLxJ4HQs62oz6GfRQ==}+ cpu: [x64]+ os: [darwin]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-fqtGgak3zX4DCB6PFpsH5+Kmt/8CIi4Bry4rb1ho6Av2QHTREM+47y282Uqiu3ZRF5IQioJQ5qWRV6jduA+iGw==}+ cpu: [x64]+ os: [freebsd]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-u92mvlcYtp9MRKmP+ZvMmtPN34+/3lMHlyMj7wXJDeXxuM0Vgzz0+PPJNsro1m3IZPYChIkn944wW8TYgGKFHw==}+ cpu: [arm]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-cINaoY2z7LVCrfHkIcmvj7osTOtm6VVT16b5oQdS4beibX2SYBwgYLmqhBjA1t51CarSaBuX5YNsWLjsqfW5Cw==}+ cpu: [arm]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-34gw7PjDGB9JgePJEmhEqBhWvCiiWCuXsL9hYphDF7crW7UgI05gyBAi6MF58uGcMOiOqSJ2ybEeCvHcq0BCmQ==}+ cpu: [arm64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-RyMIx6Uf53hhOtJDIamSbTskA99sPHS96wxVE/bJtePJJtpdKGXO1wY90oRdXuYOGOTuqjT8ACccMc4K6QmT3w==}+ cpu: [arm64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-D8Vae74A4/a+mZH0FbOkFJL9DSK2R6TFPC9M+jCWYia/q2einCubX10pecpDiTmkJVUH+y8K3BZClycD8nCShA==}+ cpu: [ppc64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-frxL4OrzOWVVsOc96+V3aqTIQl1O2TjgExV4EKgRY09AJ9leZpEg8Ak9phadbuX0BA4k8U5qtvMSQQGGmaJqcQ==}+ cpu: [riscv64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-mJ5vuDaIZ+l/acv01sHoXfpnyrNKOk/3aDoEdLO/Xtn9HuZlDD6jKxHlkN8ZhWyLJsRBxfv9GYM2utQ1SChKew==}+ cpu: [riscv64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-kELo8ebBVtb9sA7rMe1Cph4QHreByhaZ2QEADd9NzIQsYNQpt9UkM9iqr2lhGr5afh885d/cB5QeTXSbZHTYPg==}+ cpu: [s390x]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-C3ZAHugKgovV5YvAMsxhq0gtXuwESUKc5MhEtjBpLoHPLYM+iuwSj3lflFwK3DPm68660rZ7G8BMcwSro7hD5w==}+ cpu: [x64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-rV0YSoyhK2nZ4vEswT/QwqzqQXw5I6CjoaYMOX0TqBlWhojUf8P94mvI7nuJTeaCkkds3QE4+zS8Ko+GdXuZtA==}+ cpu: [x64]+ os: [linux]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-5u4RkfxJm+Ng7IWgkzi3qrFOvLvQYnPBmjmZQ8+szTK/b31fQCnleNl1GgEt7nIsZRIf5PLhPwT0WM+q45x/UQ==}+ engines: {node: '>=14.0.0'}+ cpu: [wasm32]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-nRcz5Il4ln0kMhfL8S3hLkxI85BXs3o8EYoattsJNdsX4YUU89iOkVn7g0VHSRxFuVMdM4Q1jEpIId1Ihim/Uw==}+ cpu: [arm64]+ os: [win32]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-DCEI6t5i1NmAZp6pFonpD5m7i6aFrpofcp4LA2i8IIq60Jyo28hamKBxNrZcyOwVOZkgsRp9O2sXWBWP8MnvIQ==}+ cpu: [ia32]+ os: [win32]++ '@unrs/[email protected]':+ resolution: {integrity: sha512-lrW200hZdbfRtztbygyaq/6jP6AKE8qQN2KvPcJ+x7wiD038YtnYtZ82IMNJ69GJibV7bwL3y9FgK+5w/pYt6g==}+ cpu: [x64]+ os: [win32]++ resolution: {integrity: sha512-2BjRTZxTPvheOvGbBslFSYOUkr+SjPtOnrLP33f+VIWLzezQpZcqVg7ja3L4dBXmzzgwT+a029jRx5PCi3JuiA==}++ resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}+ peerDependencies:+ acorn: ^6.0.0 || ^7.0.0 || ^8.0.0++ resolution: {integrity: sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg==}+ engines: {node: '>=0.4.0'}+ hasBin: true++ resolution: {integrity: sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==}+ peerDependencies:+ ajv: ^8.0.0+ peerDependenciesMeta:+ ajv:+ optional: true++ resolution: {integrity: sha512-8iUql50EUR+uUcdRQ3HDqa6EVyo3docL8g5WJ3FNcWmu62IbkGUue/pEyLBW8VGKKucTPgqeks4fIU1DA4yowQ==}+ peerDependencies:+ ajv: ^8.0.0+ peerDependenciesMeta:+ ajv:+ optional: true++ resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==}++ resolution: {integrity: sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==}++ resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==}++ resolution: {integrity: sha512-ik3ZgC9dY/lYVVM++OISsaYDeg1tb0VtP5uL3ouh1koGOaUMDPpbFIei4JkFimWUFPn90sbMNMXQAIVOlnYKJA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-COROpnaoap1E2F000S62r6A60uHZnmlvomhfyT2DlTcrY1OrBKn2UhH7qn5wTC9zMvD0AY7csdPSNwKP+7WiQw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-LHE+8BuR7RYGDKvnrmcuSq3tDcKv9OFEXQt/HpbZhY7V6h0zlUXutnAD82GiFx9rdieCMjkvtcsPqBwgUl1Iiw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-FmeCCAenzH0KH381SPT5FZmiA/TmpndpcaShhfgEN9eCVjnFBqq3l1xrI42y8+PPLI6hypzou4GXw00WHmPBLQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-CVvd6FHg1Z3POpBLxO6E6zr+rSKEQ9L6rZHAaY7lLfhKsWYUBBOuMs0e9o24oopj6H+geRCX0YJ+TJLBK2eHyQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-F/TKATkzseUExPlfvmwQKGITM3DGTK+vkAsCZoDc5daVygbJBnjEUCbgkAvVFsgfXfX4YIqZ/27G3k3tdXrTxQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-rwG/ja1neyLqCuGZ5YYrznA62D4mZXg0i1cIskIUKSiqF3Cje9/wXAls9B9s1Wa2fomMsIv8czB8jZcPmxCXFg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-Y7Wt51eKJSyi80hFrJCePGGNo5ktJCslFuboqJsbf57CCPcm5zztluPlc4/aD8sWsKvlwatezpV4U1efk8kpjg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-p6Fx8B7b7ZhL/gmUsAy0D15WhvDccw3mnGNbZpi3pmeJdxtWsj2jEaI4Y6oo3XiHfzuSgPwKc04MYt6KgvC/wA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-BNoCY6SXXPQ7gF2opIP4GBE+Xw7U+pHMYKuzjgCN3GwiaIR09UUeKfheyIry77QtrCBlC0KK0q5/TER/tYh3PQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-OH/2E5Fg20h2aPrbe+QL8JZQFko0YZaF+j4mnQ7BGhfavO7OpSLa8a0y9sBwomHdSbkhTS8TQNayBfnW5DwbvQ==}++ resolution: {integrity: sha512-hsU18Ae8CDTR6Kgu9DYf0EbCr/a5iGL0rytQDobUcdpYOKokk8LEjVphnXkDkgpi0wYVsqrXuP0bZxJaTqdgoA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ==}+ engines: {node: '>=8.0.0'}++ resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-CDSwaxINFy59iNwhYnkvALBwZiTydGkOecZyPkqBpABYR1KqGEsET0VOOYDwtleZSUIdeY36DC2bSZ24CO1igA==}++ resolution: {integrity: sha512-BASOg+YwO2C+346x3LZOeoovTIoTrRqEsqMa6fmfAV0P+U9mFr9NsyOEpiYvFjbc64NMrSswhV50WdXzdb/Z5A==}+ engines: {node: '>=4'}++ resolution: {integrity: sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==}++ resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==}++ resolution: {integrity: sha512-yR5HATnqeYNVnkaUTf4bOP2dJSnyhP4puJN/QPRyx4YkBEEUxib422n2XzPqDEHjQQqazoYoADdAm5vE15+dAQ==}++ resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==}++ resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==}++ resolution: {integrity: sha512-9T9UjW3r0UW5c1Q7GTwllptXwhvYmEzFhzMfZ9H7FQWt+uZePjZPjBP/W1ZEyZ1twGWom5/56TF4lPcqjnDHcg==}++ resolution: {integrity: sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ==}++ resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==}++ resolution: {integrity: sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==}+ engines: {node: '>=10.16.0'}++ resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-oKlSFMcMwpUg2ednkhQ454wfWiU/ul3CkJe/PEHcTKuiX6RpbehUiFMXu13HalGZxfUwCQzZG747YXBn1im9ww==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-34+zUAMhSH+r+9eKmYG+k2Rpt8XttfE4yXAjoZvkAPs15xcYQhyBYdalJ65BzivAvGRMViEjy6oKr/S91loekQ==}++ resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==}++ resolution: {integrity: sha512-Ka+9Trutv7G8M6WT6SeiRWz792K5qEqIGEGzXKhAE6xOWAY6pPH8U+9IY3oCMv6kqTmLsv7Xh/2w2RigkePMsg==}++ resolution: {integrity: sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA==}++ resolution: {integrity: sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==}+ engines: {node: '>=7.0.0'}++ resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==}++ resolution: {integrity: sha512-shrVawQFojnZv6xM40anx4CkoDP+fZsw/ZerEMsW/pyzsRbElpsL/DBVW7q3ExxwusdNXI3lXpuhEZkzs8p5Eg==}++ resolution: {integrity: sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A==}+ engines: {node: '>=12.5.0'}++ resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==}++ resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==}++ resolution: {integrity: sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==}+ engines: {node: '>= 0.6'}++ resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==}+ engines: {node: '>= 8'}++ resolution: {integrity: sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==}++ resolution: {integrity: sha512-B0ErZK/66mHtEsR1TkPEEkwdy+WDesimkM5gpZr5Dsg54BiTA5RXtYW5qTLIAcekaS9xfZrzBLF/OAkB3Qn1YQ==}++ resolution: {integrity: sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-SPXi0TSKPD4g9tw0NMZFnR95XVgUZiBH+uUTqQuDu1OsE2zomHU7ho0FISciaPvosimixwHFl3WHLGabv6dDgQ==}++ resolution: {integrity: sha512-zg/chbXyeBtMQ1LbD/WSoW2DpC3I0mpmPdW+ynRTj/x2DAWYrIY7qeZIHidozwV24m4iavr15lNwIwLxRmOxhA==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-S/m2VsXI7gAti2pBoLClFFTMOO1HTtT0j99AuXLoGFKO6deHDdnv6ZGTxSTTUTgO1zVcv82fCOtDjYK4EECmWA==}++ resolution: {integrity: sha512-g9y9WbMnF5uqB9qKqwIIa/921RYWzlUDv9Jl1/yONQwxbOfszAWTCm8u7HOTgJgRDXiRZN56cHT9pd24dmXs8w==}++ resolution: {integrity: sha512-68/n9JWarxXkOWMshcT5IcjbB+agblQUaIsbnXmrzejn2O82n3p2A9R2zEB9HIEFWKFwPAEDDN8gR0VdSAyyAQ==}++ resolution: {integrity: sha512-wR/XK3D3XcLIZwpbvQwQ5fK+8Ykds1ip7A2Txe0yxncXSdq1L9skcG7blcedkOX+ZcgxGAmLX1FrRGbADwzi0w==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-AJDdYOdnyRDV5b6ArilzCPPwc1ejkHcoyFarqlPqT7zRYjhavcT3uSrqcMvsgh2CgoPbK3RCwyHaVyxYcP2Arg==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-8pM1WGMLGFuhq9S+FpPURxic+gKzjluCD/CHTuUF3mXMeiCo0i6R0tO1s4+GArRFde96SLcW/kOFRjoAosPsFA==}++ resolution: {integrity: sha512-c5UhwwTs/yybcmTpAVqwSFl6vrQ8JZJoT5F7xNFK9pymv5C0Ymcc9/LIJHtYIggg/yS9YHw8i8O8tgb9pupjeQ==}++ resolution: {integrity: sha512-3bYs1rOD33uo8aqJfKP3JWPAibgw8Zm2+L9vBKEHJ2Rg+viTR7o5Mmv5mZcieN+FRYaAOWX5SJATX6k1PWz72g==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-p3KP5HCf/bvjBSSKuXid6Zqijx7wIfNW+J/maPs+iwR35at5JCbLUT0LzF1cnjbCHWhqzQTIN2Jpe8pRebIEFQ==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-GZW464g1SH7ag3Y7hXjf8RoUuAFIqklOAq3MRl4OaWabTFJY9PN/E1YklhXLh+OQ3fM9yS2nOkCoS+WLZ6kvxQ==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-XoGGqhLUN/W14NmaqcO/bb1nqjDAw5WtSYb2X8wiuQWvSZUsUVYsOSkOybUrNvcBjaywBdYPy03eXHMXjk9nZA==}++ resolution: {integrity: sha512-SaLBuwGm3MOViRq2ABk3eLoxwZELpH6zhl3FbAoJ7Vm1gofKx6El1Ib5z23NUEhF9AsGl7y+dzLe5Cw2AArGTA==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-dJxPBlzC7NugB2PDLwo9Q8JiTR3M3e4/XANkreKSUxF8vvXKqm1Yfq4Q5dl8budlunRVlUUaDUgFt7eA8D6NLg==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-VqKjzBLejbSMT4IgbmVgDjpkYrNWUYJnbCGo874u7MMKIWsILRX+OpX/gTk8MqjpT1A/c6HY2dCA77ZN0lkQ2Q==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-TO4VLh0/420Y/9dO3+f9abDEFYeCUr2WZRlxJvbp4HPTQcSylXNiL6yZa9FIUvV1yRiFufl1bszTCLDqv9PWNA==}++ resolution: {integrity: sha512-ndfJ/JxxMd3nw31uyKoY2naivF+r29V+Lc0svZxe1JvvIRmi8hUsrMvdOwgS1o6uBHmiz91geQ0ylPP0aj1VUA==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-42ltAGgJesfQE3u9LuuBHNbGrI/AJjNL2OAUdclE70UE6Vy239GCBEYD38uBPoLeNsOhFStGpPI0BAOV+HMxog==}+ peerDependencies:+ d3-selection: '2'++ resolution: {integrity: sha512-fFg7aoaEm9/jf+qfstak0IYpnesZLiMX6GZvXtUSdv8RH2o4E2qeelgdU09eKS6wGuiGMfcnMI0nTIqWzRHGpw==}++ resolution: {integrity: sha512-sdQSFB7+llfUcQHUQO3+B8ERRj0Oa4w9POWMI/puGtuf7gFywGmkaLCElnudfTiKZV+NvHqL0ifzdrI8Ro7ESA==}++ resolution: {integrity: sha512-EmKO5V3OLXh1rtK2wgXRansaK1/mtVdTUEiEI0W8RkvgT05kfxaH29PliLnpLP73yYO6142Q72QNa8Wx/A5CqQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-tuhGbE6CfTM9+5ANGf+oQb72Ky/0+s3xKUpHvShfiz2RxMFgFPjsXuRLBVMtvMs15awe45SRb83D6wH4ew6wlQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-BS8PfmtDGnrgYdOonGZQdLZslWIeCGFP9tpan0hi1Co2Zr2NKADsvGYA8XxuG/4UWgJ6Cjtv+YJnB6MM69QGlQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==}+ peerDependencies:+ supports-color: '*'+ peerDependenciesMeta:+ supports-color:+ optional: true++ resolution: {integrity: sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==}+ engines: {node: '>=6.0'}+ peerDependencies:+ supports-color: '*'+ peerDependenciesMeta:+ supports-color:+ optional: true++ resolution: {integrity: sha512-qIMFpTMZmny+MMIitAB6D7iVPEorVw6YQRWkvarTkT4tBeSLLiHzcwj6q0MmYSFCiVpiqPJTJEYIrpcPzVEIvg==}++ resolution: {integrity: sha512-YpgQiITW3JXGntzdUmyUR1V812Hn8T1YVXhCu+wO3OpS4eU9l4YdD3qjyiKdV6mvV29zapkMeD390UVEf2lkUg==}++ resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==}+ engines: {node: '>=4.0.0'}++ resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==}++ resolution: {integrity: sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ==}++ resolution: {integrity: sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-nRCa7CK3VTrM2NmGkIy4cbK7IZlgBE/PYMn55rrXefr5xXDP0LdtfPnblFDoVdcAfslJ7or6iqAUnx0CCGIWQA==}++ resolution: {integrity: sha512-uBq4egWHTcTt33a72vpSG0z3HnPuIl6NqYcTrKEg2azoEyl2hpW0zqlxysq2pK9HlDIHyHyakeYaYnSAwd8bow==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==}++ resolution: {integrity: sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==}++ resolution: {integrity: sha512-phv3E1Xl4tQOShqSte26C7Fl84EwUdZsyOuSSk9qtAGyyQs2s3jJzComh+Abf4g187lUUAvH+H26omrqia2aGg==}+ engines: {node: '>=10.13.0'}++ resolution: {integrity: sha512-zHXBLhP+QehSSbsS9Pt23Gg964240DPd6QCf8WpkqEXxQ7fhdZzYsocOr5u7apWonsS5EjZDmTF+/slGMyasvw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-BrUQ0cPTB/IwXj23HtwHjS9n7O4h9FX94b4xc5zlTHxeLgTAdzYUDyy6KdExAl9lbN5rtfe44xpjpmj9grxs5w==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-d9T8ucsEhh8Bi1woXCf+TIKDIROLG5WCkxg8geBCbvk22kzwC5G2OnXVMO6FUsvQlgUUXQ2itephWDLqDzbeCw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-HyNQImnsOC7X9PMNaCIeAm4ISCQXs5a5YasTXVliKv4uuBo1dKrG0A+uQS8M5eXjVMnLg3WgXaKvprHlFJQffw==}+ engines: {node: '>=18'}+ hasBin: true++ resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-Wd1uy6y7nBbXUSg9QAuQ+xYEKli5CgUhLjz1QHW11jLDis5vK5XB3PemL6jEmy7HrdhaRFDz+GTZ/3FoH+EUjg==}+ peerDependencies:+ eslint: ^7.23.0 || ^8.0.0 || ^9.0.0+ typescript: '>=3.3.1'+ peerDependenciesMeta:+ typescript:+ optional: true++ resolution: {integrity: sha512-WFj2isz22JahUv+B788TlO3N6zL3nNJGU8CcZbPZvVEkBPaJdCV4vy5wyghty5ROFbCRnm132v8BScu5/1BQ8g==}++ resolution: {integrity: sha512-A1rHYb06zjMGAxdLSkN2fXPBwuSaQ0iO5M/hdyS0Ajj1VBaRp0sPD3dn1FhME3c/JluGFbwSxyCfqdSbtQLAHQ==}+ engines: {node: ^14.18.0 || >=16.0.0}+ peerDependencies:+ eslint: '*'+ eslint-plugin-import: '*'+ eslint-plugin-import-x: '*'+ peerDependenciesMeta:+ eslint-plugin-import:+ optional: true+ eslint-plugin-import-x:+ optional: true++ resolution: {integrity: sha512-L8jSWTze7K2mTg0vos/RuLRS5soomksDPoJLXIslC7c8Wmut3bx7CPpJijDcBZtxQ5lrbUdM+s0OlNbz0DCDNw==}+ engines: {node: '>=4'}+ peerDependencies:+ '@typescript-eslint/parser': '*'+ eslint: '*'+ eslint-import-resolver-node: '*'+ eslint-import-resolver-typescript: '*'+ eslint-import-resolver-webpack: '*'+ peerDependenciesMeta:+ '@typescript-eslint/parser':+ optional: true+ eslint:+ optional: true+ eslint-import-resolver-node:+ optional: true+ eslint-import-resolver-typescript:+ optional: true+ eslint-import-resolver-webpack:+ optional: true++ resolution: {integrity: sha512-whOE1HFo/qJDyX4SnXzP4N6zOWn79WhnCUY/iDR0mPfQZO8wcYE4JClzI2oZrhBnnMUCBCHZhO6VQyoBU95mZA==}+ engines: {node: '>=4'}+ peerDependencies:+ '@typescript-eslint/parser': '*'+ eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 || ^9+ peerDependenciesMeta:+ '@typescript-eslint/parser':+ optional: true++ resolution: {integrity: sha512-scB3nz4WmG75pV8+3eRUQOHZlNSUhFNq37xnpgRkCCELU3XMvXAxLk1eqWWyE22Ki4Q01Fnsw9BA3cJHDPgn2Q==}+ engines: {node: '>=4.0'}+ peerDependencies:+ eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9++ resolution: {integrity: sha512-+f15FfK64YQwZdJNELETdn5ibXEUQmW1DZL6KXhNnc2heoy/sg9VJJeT7n8TlMWouzWqSWavFkIhHyIbIAEapg==}+ engines: {node: '>=10'}+ peerDependencies:+ eslint: ^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 || ^9.0.0++ resolution: {integrity: sha512-Qteup0SqU15kdocexFNAJMvCJEfa2xUKNV4CC1xsVMrIIqEy3SQ/rqyxCWNzfrd3/ldy6HMlD2e0JDVpDg2qIA==}+ engines: {node: '>=4'}+ peerDependencies:+ eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7++ resolution: {integrity: sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==}+ engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0}++ resolution: {integrity: sha512-Uhdk5sfqcee/9H/rCOJikYz67o0a2Tw2hGRPOG2Y1R2dg7brRe1uG0yaNQDHu+TO/uQPF/5eCapvYSmHUjt7JQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-LEyamqS7W5HB3ujJyvi0HQK/dtVINZvd5mAAp9eT5S/ujByGjiZLCzPcHVzuXbpJDJF/cxwHlfceVUDZ2lnSTw==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}+ hasBin: true+ peerDependencies:+ jiti: '*'+ peerDependenciesMeta:+ jiti:+ optional: true++ resolution: {integrity: sha512-j6PAQ2uUr79PZhBjP5C5fhl8e39FmRnOjsD5lGnWrFU8i2G776tBK7+nP8KuQUTTyAZUwfQqXAgrVH5MbH9CYQ==}+ engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}++ resolution: {integrity: sha512-Ap6G0WQwcU/LHsvLwON1fAQX9Zp0A2Y6Y/cJBl9r/JbW90Zyg4/zbG6zzKa2OTALELarYHmKu0GhpM5EO+7T0g==}+ engines: {node: '>=0.10'}++ resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==}+ engines: {node: '>=4.0'}++ resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==}+ engines: {node: '>=4.0'}++ resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw==}++ resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-fBHHqSTFLVnR61C+gltJuE5GkVQMV0S2nqUO8TJ+5Z3qAKG8vAx4FKai1s5jq/inV1+sREynIWSuQ6HgoSXpDQ==}++ resolution: {integrity: sha512-WKgKWg5eUxvRZGwW8FvfbaH7AXSh2cL+3j5fMGzUMCxWBJ3dV3a7Wz8y2f/uQ0e3B6WmodD3oS54jTQ9HVTIIg==}++ resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==}++ resolution: {integrity: sha512-jt2DW/aNFNwke7AUd+Z+e6pz39KO5rzdbbFCg2sGafS4mk13MI7Z8O5z9cADNn5lhGODIgLwug6TZO2ctf7kcw==}+ engines: {node: '>=6.0.0'}++ resolution: {integrity: sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==}+ engines: {node: '>=8.6.0'}++ resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==}++ resolution: {integrity: sha512-KAdnLvy1yu/XrRtP+LJnxbBGrhN+xXu+gt3EUvZhYGKCr3lFHq/7UFJHHFgmJKoqlh6B40bZLEv7w46B0mqn1g==}++ resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==}++ resolution: {integrity: sha512-g6KuKWmFXc0fID8WWH0jit4g0AGBoJhCkJMb1RmbsSEUNvQ+ZC8D6CUZ+GtF8nMzSPXnhiePyyqqipzNNEnHjg==}++ resolution: {integrity: sha512-ypuAmmMKInk5q7XcepxlnUWDLWv4GFtaJqAzWKqn62IpQ3pejtr5dTVbt3vwqVaMKmkNR55sTT+CqUKIaT21BA==}++ resolution: {integrity: sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==}++ resolution: {integrity: sha512-stRHYGeuqpEZTL1Ef0Ovr2ltazUT9g844X5z/zEBFLG8RYlpDiOCIG+ATvYEp+/zmc7sN29mcIMp8gvYplYPIQ==}++ resolution: {integrity: sha512-m2kMNHIG92tSNWv+Z3UeTR9AWLLuo7KctC7mlFPtMEVrfjIhmQhkQnT9v15qA/BfVq3vvj134Y0jl9SBje3jXQ==}++ resolution: {integrity: sha512-GGToxJ/w1x32s/D2EKND7kTil4n8OVk/9mycTc4VDza13lOvpUZTGX3mFSCtV9ksdGBVzvsyAVLM6mHFThxXxw==}++ resolution: {integrity: sha512-tIbYtZbucOs0BRGqPJkshJUYdL+SDH7dVM8gjy+ERp3WAUjLEFJE+02kanyHtwjWOnwrKYBiwAmM0p4kLJAnXg==}+ engines: {node: '>=12.0.0'}+ peerDependencies:+ picomatch: ^3 || ^4+ peerDependenciesMeta:+ picomatch:+ optional: true++ resolution: {integrity: sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==}+ engines: {node: '>=16.0.0'}++ resolution: {integrity: sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==}++ resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-Dobi7gcTEq8yszimcfp/R7+owiT4WncAJ7VTTgFH1jYJ5GaG1FbhjwDG820hptN0QDFvzVY3RfCzdInvGPGzjA==}+ engines: {node: '>=14'}++ resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==}+ engines: {node: '>=16'}++ resolution: {integrity: sha512-GX+ysw4PBCz0PzosHDepZGANEuFCMLrnRTiEy9McGjmkCQYwRq4A/X786G/fjM/+OjsWSU1ZrY5qyARZmO/uwg==}++ resolution: {integrity: sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==}+ engines: {node: '>= 0.6'}++ resolution: {integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==}++ resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==}+ engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0}+ os: [darwin]++ resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==}++ resolution: {integrity: sha512-e5iwyodOHhbMr/yNrc7fDYG4qlbIvI5gajyzPnb5TCwyhjApznQh1BMFou9b30SevY43gCJKXycoCBjMbsuW0Q==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==}++ resolution: {integrity: sha512-SFdFmIJi+ybC0vjlHN0ZGVGHc3lgE0DxPAT0djjVg+kjOnSqclqmj0KQ7ykTOLP6YxoqOvuAODGdcHJn+43q3g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-w9UMqWwJxHNOvoNzSJ2oPF5wvYcvP7jUvYzhp67yEhTi17ZDBBC1z9pTdGuzjD+EFIqLSYRweZjqfiPzQ06Ebg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-EoY1N2xCn44xU6750Sx7OjOIT59FkmstNc3X6y5xpz7D5cBtZRe/3pSlTkDJgqsOk3WwZPkWfonhhUJfttQo3w==}++ resolution: {integrity: sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==}++ resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==}+ engines: {node: '>= 6'}++ resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==}+ engines: {node: '>=10.13.0'}++ resolution: {integrity: sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==}+ engines: {node: '>=18'}++ resolution: {integrity: sha512-DpLKbNU4WylpxJykQujfCcwYWiV/Jhm50Goo0wrVILAv5jOr9d+H+UR3PhSCD2rCCEIg0uc+G+muBTwD54JhDQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==}++ resolution: {integrity: sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==}++ resolution: {integrity: sha512-KIL7eQPfHQRC8+XluaIw7BHUwwqL19bQn4hzNgdr+1wXoU0KKj6rufu47lhY7KbJR2C6T6+PfyN0Ea7wkSS+qQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==}++ resolution: {integrity: sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==}+ engines: {node: '>= 4'}++ resolution: {integrity: sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==}+ engines: {node: '>= 4'}++ resolution: {integrity: sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==}+ engines: {node: '>=0.8.19'}++ resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==}++ resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==}++ resolution: {integrity: sha512-4gd7VpWNQNB4UKKCFFVcp1AVv+FMOgs9NKzjHKusc8jTMhd5eL1NqQqOpE0KzMds804/yHlglp3uxgluOqAPLw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-lDB5YccMydFBtasVtxnZ3MRBHuaoE8GKsppq+EchKL2U4nK/DmEpPHNH8MZe5HkMtpSiTSOZwfN0tzYjO/lJEw==}++ resolution: {integrity: sha512-5Hh7Y1wQbvY5ooGgPbDaL5iYLAPzMTUrjMulskHLH6wnv/A+1q5rgEaiuqEjB+oxGXIVZs1FF+R/KPN3ZSQYYg==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-m3Ofv/X/tV8Y3tHXLohcuVuhWKo7BBq62cqY15etqmLxg2DZ34AGGgQDeR+SCta2+zICb1NX83af0GJmbQ1++g==}++ resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==}+ engines: {node: '>= 0.10'}++ resolution: {integrity: sha512-DDfANUiiG2wC1qawP66qlTugJeL5HyzMpfr8lLK+jMQirGzNod0B12cFB/9q838Ru27sBwfw78/rdoU7RERz6A==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-m6UrgzFVUYawGBh1dUsWR5M2Clqic9RVXC/9f8ceNlv2IcO9j9J/z8UoCLPqtsPBFNzEpfR3xftohbfqDx8EQA==}++ resolution: {integrity: sha512-9dgM/cZBnNvjzaMYHVoxxfPj2QXt22Ev7SuuPrs+xav0ukGB0S6d4ydZdEiM48kLx5kDV+QBPrpVnFyefL8kkQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-n4ZT37wG78iz03xPRKJrHTdZbe3IicyucEtdRsV5yglwc3GyUfbAfpSeD0FJ41NbUNSt5wbhqfp1fS+BgnvDFQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-wa56o2/ElJMYqjCjGkXri7it5FbebW5usLw/nPmCMs5DeZ7eziSYZhSmPRn0txqeW4LnAmQQU7FgqLpsEFKM4A==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-gNCGbnnnnFAUGKeZ9PdbyeGYJqewpmc2aKHUEMO5nQPWU9lOmv7jcmQIv+qHD8fXW6W7qfuCwX4rY9LNRjXrkQ==}++ resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-UfoeMA6fIJ8wTYFEUjelnaGI67v6+N7qXJEvQuIGa99l4xsCruSYOVSQ0uPANn4dAzm8lkYPaKLrrijLq7x23w==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-RKtWF8pGmS87i2D6gqQu/l7EYRlVdfzemCJN/P3UOs//x1QE7mfhvzHIApBTRf7axvT6DMGwSwBXYCT0nfB9xw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-PwwhEakHVKTdRNVOw+/Gyh0+MzlCl4R6qKvkhuvLtPMggI1WAHt9sOwZxQLSGpUaDnrdyDsomoRgNnCfKNSXXg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-1pC6N8qWJbWoPtEjgcL2xyhQOP491EQjeUo3qTKcmV8YSDDJrOepfG8pcC7h/QgnQHYSv0mJ3Z/ZWxmatVrysg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-upqt1SkGkODW9tsGNG5mtXTXtECizwtS2kA161M+gJPc1xdb/Ax629af6YrTwcOeQHbewrPNlE5Dx7kzvXTizA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-5KoIu2Ngpyek75jXodFvnafB6DJgr3u8uuK0LEZJjrU19DrMD3EVERaR8sjz8CCGgpZvxPl9SuE1GMVPFHx1mw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-lZhclumE1G6VYD8VHe35wFaIif+CTy5SJIi5+3y4psDgWu4wPDoBhF8NxUOinEc7pHgiTsT6MaBb92rKhhD+Xw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==}+ engines: {node: '>=0.12.0'}++ resolution: {integrity: sha512-MjYsKHO5O7mCsmRGxWcLWheFqN9DJ/2TmngvjKXihe6efViPqc274+Fx/4fYj/r03+ESvBdTXK0V6tA3rgez1g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-iPAjerrse27/ygGLxw+EBR9agv9Y6uLeYVJMu+QNCoouJ1/1ri0mGrcWpfCqFZuzzx3WjtwxG098X+n4OuRkPg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-ISWac8drv4ZGfwKl5slpHG9OwPNty4jOWPRIhBpxOoD+hqITiwuipOQ2bNthAzwA3B4fIjO4Nln74N0S9byq8A==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-BtEeSsoaQjlSPBemMQIrY1MY0uM6vnS1g5fmufYOtnxLGUZM2178PKbhsk7Ffv58IX+ZtcvoGwccYsh0PglkAA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-9gGx6GTtCQM73BgmHQXfDmLtfjjTUDSyoxTCbp5WtoixAhfgsDirWIcVQ/IHpvI5Vgd5i/J5F7B9cN/WlVbC/w==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-K5pXYOm9wqY1RgjpL3YTkF39tni1XajUIkawTLUo9EZEVUFga5gSQJF8nNS7ZwJQ02y+1YCNYcMh+HIf1ZqE+w==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-6i9mGWSlqzNMEqpCp93KwRS1uUOodk2OJ6b+sq7ZPDSy2WuI5NFIxp/254TytR8ftefexkWn5xNiHUNpPOfSew==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-mfcwb6IzQyOKTs84CQMrOwW4gQcaTOAWJ0zzJCl2WSPDrWk/OzDaImWFH3djXhb24g4eudZfLRozAvPGw4d9hQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==}++ resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==}++ resolution: {integrity: sha512-H0dkQoCa3b2VEeKQBOxFph+JAbcrQdE7KC0UkqwpLmv2EC4P41QXP+rqo9wYodACiG5/WM5s9oDApTU8utwj9g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==}+ hasBin: true++ resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==}++ resolution: {integrity: sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==}+ hasBin: true++ resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==}++ resolution: {integrity: sha512-EJAj1pgHc1hxF6vo2Z3s69fMjO1INq6eGHXZ8Z6wCQeldCuwxGK9Sxf4/cScGn3FZubCVUehfWtcDM/PLteCQw==}++ resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==}++ resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==}++ resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==}++ resolution: {integrity: sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==}+ hasBin: true++ resolution: {integrity: sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==}+ engines: {node: '>=4.0'}++ resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==}++ resolution: {integrity: sha512-0K65Lea881pHotoGEa5gDlMxt3pctLi2RplBb7Ezh4rRdLEOtgi7n4EwK9lamnUCkKBqaeKRVebTq6BAxSkpXQ==}++ resolution: {integrity: sha512-MbjN408fEndfiQXbFQ1vnd+1NoLDsnQW41410oQBXiyXDMYH5z505juWa4KUE1LqxRC7DgOgZDbKLxHIwm27hA==}+ engines: {node: '>=0.10'}++ resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-aORPWntbpH5esaYpGOOmri0OHDOe3wC5M2MQxZ9dvMLZm6DnaAn0kJlcbU9hwsQgLzmZyReKwFwwPkR+nHu5kA==}++ resolution: {integrity: sha512-BH9sEdOCahSgmkVhBLeU7Hc9DWeZ1Eb6wNS6Da8igvUwAe0sqROHddIlvU06q3WyXVEOYDZ6ykBZQnjTbmo4+A==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [android]++ resolution: {integrity: sha512-ylTcDJBN3Hp21TdhRT5zBOIi73P6/W0qwvlFEk22fkdXchtNTOU4Qc37SkzV+EKYxLouZ6M4LG9NfZ1qkhhBWA==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [darwin]++ resolution: {integrity: sha512-oBZgKchomuDYxr7ilwLcyms6BCyLn0z8J0+ZZmfpjwg9fRVZIR5/GMXd7r9RH94iDhld3UmSjBM6nXWM2TfZTQ==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [darwin]++ resolution: {integrity: sha512-c2bH6xTrf4BDpK8MoGG4Bd6zAMZDAXS569UxCAGcA7IKbHNMlhGQ89eRmvpIUGfKWNVdbhSbkQaWhEoMGmGslA==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [freebsd]++ resolution: {integrity: sha512-eVdpxh4wYcm0PofJIZVuYuLiqBIakQ9uFZmipf6LF/HRj5Bgm0eb3qL/mr1smyXIS1twwOxNWndd8z0E374hiA==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm]+ os: [linux]++ resolution: {integrity: sha512-UK65WJAbwIJbiBFXpxrbTNArtfuznvxAJw4Q2ZGlU8kPeDIWEX1dg3rn2veBVUylA2Ezg89ktszWbaQnxD/e3A==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [linux]++ resolution: {integrity: sha512-5Vh9dGeblpTxWHpOx8iauV02popZDsCYMPIgiuw97OJ5uaDsL86cnqSFs5LZkG3ghHoX5isLgWzMs+eD1YzrnA==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [linux]++ resolution: {integrity: sha512-Cfd46gdmj1vQ+lR6VRTTadNHu6ALuw2pKR9lYq4FnhvgBc4zWY1EtZcAc6EffShbb1MFrIPfLDXD6Xprbnni4w==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [linux]++ resolution: {integrity: sha512-XJaLUUFXb6/QG2lGIW6aIk6jKdtjtcffUT0NKvIqhSBY3hh9Ch+1LCeH80dR9q9LBjG3ewbDjnumefsLsP6aiA==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [linux]++ resolution: {integrity: sha512-FZn+vaj7zLv//D/192WFFVA0RgHawIcHqLX9xuWiQt7P0PtdFEVaxgF9rjM/IRYHQXNnk61/H/gb2Ei+kUQ4xQ==}+ engines: {node: '>= 12.0.0'}+ cpu: [arm64]+ os: [win32]++ resolution: {integrity: sha512-5g1yc73p+iAkid5phb4oVFMB45417DkRevRbt/El/gKXJk4jid+vPFF/AXbxn05Aky8PapwzZrdJShv5C0avjw==}+ engines: {node: '>= 12.0.0'}+ cpu: [x64]+ os: [win32]++ resolution: {integrity: sha512-utfs7Pr5uJyyvDETitgsaqSyjCb2qNRAtuqUeWIAKztsOYdcACf2KtARYXg2pSvhkt+9NfoaNY7fxjl6nuMjIQ==}+ engines: {node: '>= 12.0.0'}++ resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==}++ resolution: {integrity: sha512-LgVTMpQtIopCi79SJeDiP0TfWi5CNEc/L/aRdTh3yIvmZXTnheWpKjSZhnvMl8iXbC1tFg9gdHHDMLoV7CnG+w==}++ resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==}+ hasBin: true++ resolution: {integrity: sha512-CmghgHkh0OJNmxGKWc0qfPJCYHASPMVSyGY8fj3xgk4v84ItqDg64JNKFZn5hC6E0vHi6gxnbCgwhyVB09wQtA==}+ peerDependencies:+ react: ^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0++ resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==}++ resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==}+ engines: {node: '>= 8'}++ resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==}+ engines: {node: '>=8.6'}++ resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==}++ resolution: {integrity: sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow==}+ engines: {node: '>=16 || 14 >=14.17'}++ resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==}++ resolution: {integrity: sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==}++ resolution: {integrity: sha512-A/0v5Z59y63US00cRSLiloEIw3t5G+MiKz4BhX21FI+YBJXBOGW0ohFxTxO08dsOYlzxo87T7vGfZKYp2bcAWA==}++ resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==}++ resolution: {integrity: sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==}+ engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1}+ hasBin: true++ resolution: {integrity: sha512-GEbrYkbfF7MoNaoh2iGG84Mnf/WZfB0GdGEsM8wz7Expx/LlWf5U8t9nvJKXSp3qr5IsEbK04cBGhol/KwOsWA==}++ resolution: {integrity: sha512-PHI5f1O0EP5xJ9gQmFGMS6IZcrVvTjpXjz7Na41gTE7eE2hK11lg04CECCYEEjdc17EV4DO+fkGEtt7TpTaTiQ==}+ engines: {node: ^12.20.0 || ^14.18.0 || >=16.0.0}+ hasBin: true++ resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==}++ resolution: {integrity: sha512-8Ofs/AUQh8MaEcrlq5xOX0CQ9ypTF5dl78mjlMNfOK08fzpgTHQRQPBxcPlEtIw0yRpws+Zo/3r+5WRby7u3Gg==}+ engines: {node: '>= 0.6'}++ resolution: {integrity: sha512-EQlCIfY0jOhRldiFxwSXG+ImwkQtDEfQeSOEQp6ieAGSLWGlgjdb/Ck/O7wMfC430ZHGeUKVKax8KGusTPKCgg==}+ peerDependencies:+ next: ^10.0.0 || ^11.0.0 || ^12.0.0 || ^13.0.0 || ^14.0.0 || ^15.0.0+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || >=19.0.0-rc <19.0.0 || ^19.0.0++ resolution: {integrity: sha512-pZvgD5L0IEvX5/9GWyHMf3m8BKiVQwsCMHfoFosXtXBMnaS0ZnIJ9ST4b4NqLVKDEm8QBxoNNGNaBv2JNF6XNA==}+ peerDependencies:+ react: ^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc+ react-dom: ^16.8 || ^17 || ^18 || ^19 || ^19.0.0-rc++ resolution: {integrity: sha512-Hch4wzbaX0vKQtalpXvUiw5sYivBy4cm5rzUKrBnUB/y436LGrvOUqYvlSeNVCWFO/770gDlltR9gqZH62ct4Q==}+ engines: {node: ^18.18.0 || ^19.8.0 || >= 20.0.0}+ hasBin: true+ peerDependencies:+ '@opentelemetry/api': ^1.1.0+ '@playwright/test': ^1.41.2+ babel-plugin-react-compiler: '*'+ react: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0+ react-dom: ^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0+ sass: ^1.3.0+ peerDependenciesMeta:+ '@opentelemetry/api':+ optional: true+ '@playwright/test':+ optional: true+ babel-plugin-react-compiler:+ optional: true+ sass:+ optional: true++ resolution: {integrity: sha512-+CGM1L1CgmtheLcBuleyYOn7NWPVu0s0EJH2C4puxgEZb9h8QpR9G2dBfZJOAUhi7VQxuBPMd0hiISWcTyiYyQ==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-W67iLl4J2EXEGTbfeHCffrjDfitvLANg0UlX3wFUUSTx92KXRFegMHUVgSqE+wvhAbi4WqjGg9czysTV2Epbew==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-nK28WOo+QIjBkDduTINE4JkF/UJJKyf2EJxvJKfblDpyg0Q+pkOHNTL0Qwy6NP6FhE/EnzV73BxxqcJaXY9anw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-8u/hfXFRBD1O0hPUjioLhoWFHRmt6tKA4/vZPyckBr18l1KE9uHrFaFaUi8MDRTpi4uak2goyPTSNJLXX2k2Hw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-k6E21FzySsSK5a21KRADBd/NGneRegFO5pLHfdQLpRDETUNJueLXs3WCzyQ3tFRDYgbq3KHGXfTbi2bs8WQ6rQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-+Lhy3TQTuzXI5hevh8sBGqbmurHbbIjAi0Z4S63nthVLmLxfbj4T54a4CfZrXIrt9iP4mVAPYMo/v99taj3wjQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-gXah6aZrcUxjWg2zR2MwouP2eHlCBzdV4pygudehaKXSGW4v2AsRQUK+lwwXhii6KFZcunEnmSUoYp5CXibxtA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-42CPE9AhahZRsMNslczq0ctAEtqk8Eka26QofnqC346BZdHDySk3LWka23LI7ULIw11NmltpiLagIq8gBozxTw==}++ resolution: {integrity: sha512-0eJJY6hXLGf1udHwfNftBqH+g73EU4B504nZeKpz1sYRKafAghwxEJunB2O7rDZkL4PGfsMVnTXZ2EjibbqcsA==}+ engines: {node: '>=14.0.0'}++ resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==}++ resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-qFOyK5PjiWZd+QQIh+1jhdb9LpxTF0qs7Pm8o5QHYZ0M3vKqSqzsZaEB6oWlxZ+q2sJBMI/Ktgd2N5ZwQoRHfg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==}++ resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==}++ resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==}+ engines: {node: '>=8.6'}++ resolution: {integrity: sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-F63x5tizV6WCh4R6RHyi2Ml+M70DNRXt/+HANowMflpgGFMAym/VKm6G7ZOQRjqN7XbGxK1Lg9t6ZrtzOaivMw==}++ resolution: {integrity: sha512-BndPH67/JxGExRgiX1dX0w1FvZck5Wa4aal9198SrRhZjH3GxKQUKIBnYJTdj2HDN3UQAS06HlfcSbQj2OHmaw==}++ resolution: {integrity: sha512-8OEwKp5juEvb/MjpIc4hjqfgCNysrS94RIOMXYvpYCdm/jglrKEiAYmiumbmGhCvs+IcInsphYDFwqrjr7398w==}+ hasBin: true++ resolution: {integrity: sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-PS08Iboia9mts/2ygV3eLpY5ghnUcfLV/EXTOW1E2qYxJKGGBUtNjN76FYHnMs36RmARn41bC0AZmn+rR0OVpQ==}+ engines: {node: ^10 || ^12 || >=14}++ resolution: {integrity: sha512-3Ybi1tAuwAP9s0r1UQ2J4n5Y0G05bJkpUIO0/bI9MhwmD70S5aTWbXGBwxHrelT+XM1k6dM0pk+SwNkpTRN7Pg==}+ engines: {node: ^10 || ^12 || >=14}++ resolution: {integrity: sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==}+ engines: {node: '>=10'}+ hasBin: true++ resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-mqn0kFRl0EoqhnL0GQ0veqFHyIN1yig9RHh/InzORTUiZHFRAur+aMtRkELNwGs9aNwKS6tg/An4NYBPGwvtzQ==}++ resolution: {integrity: sha512-a39t9ApHNx2L4+HBnQKqxxHNs1r7KF+Intd8Q/g1bUh6q0WIp9voPXJ/x0j+ZL45KF1pJd9+q2jLIRMfvEshkA==}++ resolution: {integrity: sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==}++ resolution: {integrity: sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==}+ engines: {node: '>= 0.10'}++ resolution: {integrity: sha512-todwxLMY7/heScKmntwQG8CXVkWUOdYxIvY2s0VWAAMh/nd8SoYiRaKjlr7+iCs984f2P8zvrfWcDDYVb73NfA==}++ resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==}++ resolution: {integrity: sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg==}++ resolution: {integrity: sha512-aWizCQiyeAenIdUbqEpXgRA1ya65P13NKn/W8rWkcN0OPkRDxdBVLWnIEDsS2RpwCK2nobI7oMUSmexzTDyAmA==}+ peerDependencies:+ '@types/react': '*'+ '@types/react-dom': '*'+ react: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ react-dom: ^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true+ '@types/react-dom':+ optional: true++ resolution: {integrity: sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==}+ hasBin: true++ resolution: {integrity: sha512-4GV5sHFG0e/0AD4X+ySy6UJd3jVl1iNsNHdpad0qhABJ11twS3TTBnseqsKurKcsNqCEFeGL3uLpVChpIO3QfQ==}+ peerDependencies:+ react: ^19.0.0++ resolution: {integrity: sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==}++ resolution: {integrity: sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==}++ resolution: {integrity: sha512-9r+yi9+mgU33AKcj6IbT9oRCO78WriSj6t/cF8DWBZJ9aOGPOTEDvdUDz1FwKim7QXWwmHqtdHnRJfhAxEG46Q==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-Iqb9NjCCTt6Hf+vOdNIZGdTiH1QSqr27H/Ek9sv/a97gfueI/5h1s3yRi1nngzMUaOOToin5dI1dXKdXiF+u0Q==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-vKNFrvpPG8Vyfdjnz5Ne1N56rZlDfHXv5THNXOVZMqbX1rWZA48zQuYT03mx6PAKanqarJu/PDLgshIZAfHHqw==}+ peerDependencies:+ prop-types: ^15.7.2+ react: ^16.8.0 || 17.x || 18.x+ react-dom: ^16.8.0 || 17.x || 18.x++ resolution: {integrity: sha512-gnGKTpYwqL0Iii09gHobNolvX4Kiq4PKx6eWBCYYix+8cdw+cGo3do906l1NBPKkSWx1DghC1dlWG9L2uGd61Q==}+ peerDependencies:+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0+ react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0++ resolution: {integrity: sha512-b6jSvxvVnyptAiLjbkWLE/lOnR4lfTtDAl+eUC7RZy+QQWc6wRzIV2CE6xBuMmDxc2qIihtDCZD5NPOFl7fRBQ==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==}+ peerDependencies:+ react: '>=16.6.0'+ react-dom: '>=16.6.0'++ resolution: {integrity: sha512-V8AVnmPIICiWpGfm6GLzCR/W5FXLchHop40W4nXBmdlEceh16rCN8O8LNWm5bh5XUX91fh7KpA+W0TgMKmgTpQ==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==}+ engines: {node: '>= 6'}++ resolution: {integrity: sha512-57frrGM/OCTLqLOAh0mhVA9VBMHd+9U7Zb2THMGdBUoZVOtGbJzjxsYGDJ3A9AYYCP4hn6y1TVbaOfzWtm5GFg==}+ engines: {node: '>= 12.13.0'}++ resolution: {integrity: sha512-kivNFO+0OcUNu7jQquLXAxz1FIwZj8nrj+YkOKc5694NbjCvcT6aSZiIzNzd2Kul4o4rTto8QVR9lMNtxD4G1w==}++ resolution: {integrity: sha512-UT/q6fwS3c1dHbXv2uFgYJ9BMFHu3fwnd7AYZaEQhXuYQ4hgsxLvsUXzGdKeZrW5xopzDCvuA2N41WJ88I7zIw==}+ engines: {node: '>=14'}+ peerDependencies:+ react: ^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0+ react-dom: ^16.0.0 || ^17.0.0 || ^18.0.0 || ^19.0.0++ resolution: {integrity: sha512-00o4I+DVrefhv+nX0ulyi3biSHCPDe+yLv5o/p6d/UVlirijB8E16FtfwSAi4g3tcqrQ4lRAqQSoFEZJehYEcw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-dYqgNSZbDwkaJ2ceRd9ojCGjBq+mOm9LmtXnAnEGyHhN/5R7iDW2TRw3h+o/jCFxus3P2LfWIIiwowAjANm7IA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==}+ engines: {node: '>=4'}++ resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==}++ resolution: {integrity: sha512-RfqAvLnMl313r7c9oclB1HhUEAezcpLjz95wFH4LVuhk9JF/r22qmVP9AMmOU4vMX7Q8pN8jwNg/CSpdFnMjTQ==}+ engines: {node: '>= 0.4'}+ hasBin: true++ resolution: {integrity: sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==}+ hasBin: true++ resolution: {integrity: sha512-0f4Memo5QP7WQyUEAYUO3esD/XjOc3Zjjg5CPsAq1p8sIu0XPeMbHJemKA0BO7tV0X7+A0FoEpbmHXWxPyD3wQ==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==}+ engines: {iojs: '>=1.0.0', node: '>=0.10.0'}++ resolution: {integrity: sha512-q1b3N5QkRUWUl7iyylaaj3kOpIT0N2i9MqIEQXP73GVsN9cw3fdx8X63cEmWhJGi2PPCF23Ijp7ktmd39rawIA==}++ resolution: {integrity: sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==}++ resolution: {integrity: sha512-AURm5f0jYEOydBj7VQlVvDrjeFgthDdEF5H1dP+6mNpoXOMo1quQqJ4wvJDyRZ9+pO3kGWoOdmV08cSv2aJV6Q==}+ engines: {node: '>=0.4'}++ resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==}++ resolution: {integrity: sha512-iKE9w/Z7xCzUMIZqdBsp6pEQvwuEebH4vdpjcDWnyzaI6yl6O9FHvVpmGelvEHNsoY6wGblkxR6Zty/h00WiSA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-x/+Cz4YrimQxQccJf5mKEbIa1NzeCRNI5Ecl/ekmlYaampdNLPalVyIcCZNNH3MvmqBugV5TMYZXv0ljslUlaw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-RAAZAGbap2kBfbVhvmnTFv73NWLMvDGOITFYTZBAaY8eR+Ir4ef7Up/e7amo+y1+AH+3PtLkrt9mvcTsG9LXug==}++ resolution: {integrity: sha512-b3rppTKm9T+PsVCBEOUR46GWI7fdOs00VKZ1+9c1EWDaDMvjQc6tUwuFyIprgGgTcWoVHSKrU8H31ZHA2e0RHA==}+ engines: {node: '>=10'}++ resolution: {integrity: sha512-xFVuu11jh+xcO7JOAGJNOXld8/TcEHK/4CituBUeUb5hqxJLj9YuemAEuvm9gQ/+pgXYfbQuqAkiYu+u7YEsNA==}++ resolution: {integrity: sha512-6aU+Rwsezw7VR8/nyvKTx8QpWH9FrcYiXXlqC4z5d5XQBDRqtbfsRjnwGyqbi3gddNtWHuEk9OANUotL26qKUw==}++ resolution: {integrity: sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==}+ hasBin: true++ resolution: {integrity: sha512-SdsKMrI9TdgjdweUSR9MweHA4EJ8YxHn8DFaDisvhVlUOe4BF1tLD7GAj0lIqWVl+dPb/rExr0Btby5loQm20Q==}+ engines: {node: '>=10'}+ hasBin: true++ resolution: {integrity: sha512-oeM1lpU/UvhTxw+g3cIfxXHyJRc/uidd3yK1P242gzHds0udQBYzs3y8j4gCCW+ZJ7ad0yctld8RYO+bdurlvw==}++ resolution: {integrity: sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-7PGFlmtwsEADb0WYyvCMa1t+yke6daIG4Wirafur5kcf+MhUnPms1UeR0CKQdTZD81yESwMHbtn+TR+dMviakQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-haPVm1EkS9pgvHrQ/F3Xy+hgcuMV0Wm9vfIBSiwZ05k+xgb0PkBQpGsAA/oWdDobNaZTH5ppvHtzCFbnSEwHVw==}+ engines: {node: ^18.17.0 || ^20.3.0 || >=21.0.0}++ resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-FCLHtRD/gnpCiCHEiJLOwdmFP+wzCmDEkc9y7NsYxeF4u7Btsn1ZuwgwJGxImImHicJArLP4R0yX4c2KCrMrTA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-ZX99e6tRweoUXqR+VBrslhda51Nh5MTQwou5tnUDgbtyM0dBgmhEDtWGP/xbKn6hqfPRHujUNwz5fy/wbbhnpw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==}++ resolution: {integrity: sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==}++ resolution: {integrity: sha512-nAu1WFPQSMNr2Zn9PGSZK9AGn4t/y97lEm+MXTtUDwfP0ksAIX4nO+6ruD9Jwut4C49SB1Ws+fbXsm/yScWOHw==}++ resolution: {integrity: sha512-INb7TM37/mAcsGmc9hyyI6+QR3rR1zVRu36B0NeGXKnOOLiZOfER5SA+N7X7k3yUYRzLWafduTDvJAfDswwEww==}++ resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg==}+ engines: {node: '>= 10.x'}++ resolution: {integrity: sha512-+L3ccpzibovGXFK+Ap/f8LOS0ahMrHTf3xu7mMLSpEGU0EO9ucaysSylKo9eRDFNhWve/y275iPmIZ4z39a9iA==}++ resolution: {integrity: sha512-eLoXW/DHyl62zxY4SCaIgnRhuMr6ri4juEYARS8E6sCEqzKpOiE521Ucofdx+KnDZl5xmvGYaaKCk5FEOxJCoQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==}+ engines: {node: '>=10.0.0'}++ resolution: {integrity: sha512-o7+c9bW6zpAdJHTtujeePODAhkuicdAryFsfVKwA+wGw89wJ4GTY484WTucM9hLtDEOpOvI+aHnzqnC5lHp4Rg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-6CC9uyBL+/48dYizRf7H7VAYCMCNTBeM78x/VTUe9bFEaxBepPJDa1Ow99LqI/1yF7kuy7Q3cQsYMrcjGUcskA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-0u/TldDbKD8bFCQ/4f5+mNRrXwZ8hg2w7ZR8wa16e8z9XpePWl3eGEcUD0OXpEH/VJH/2G3gjUtR3ZOiBe2S/w==}++ resolution: {integrity: sha512-Rs66F0P/1kedk5lyYyH9uBzuiI/kNRmwJAR9quK6VOtIpZ2G+hMZd+HQbbv25MgCA6gEffoMZYxlTod4WcdrKA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-G7Ok5C6E/j4SGfyLCloXTrngQIQU3PWtXGst3yM7Bea9FRURf1S42ZHlZZtsNque2FN2PoUhfZXYLNWwEr4dLQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==}++ resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==}+ engines: {node: '>=4'}++ resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-qSVyDTeMotdvQYoHWLNGwRFJHC+i+ZvdBRYosOFgC+Wg1vx4frN2/RG/NA7SYqqvKNLf39P2LSRA2pu6n0XYZA==}+ engines: {node: '>= 12.0.0'}+ peerDependencies:+ '@babel/core': '*'+ babel-plugin-macros: '*'+ react: '>= 16.8.0 || 17.x.x || ^18.0.0-0 || ^19.0.0-0'+ peerDependenciesMeta:+ '@babel/core':+ optional: true+ babel-plugin-macros:+ optional: true++ resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==}+ engines: {node: '>=8'}++ resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-Oo6tHdpZsGpkKG88HJ8RR1rg/RdnEkQEfMoEk2x1XRI3F1AxeU+ijRXpiVUF4UbLfcxxRGw6TbUINKYdWVsQTQ==}++ resolution: {integrity: sha512-4+Z+0yiYyEtUVCScyfHCxOYP06L5Ne+JiHhY2IjR2KWMIWhJOYZKLSGZaP5HkZ8+bY0cxfzwDE5uOmzFXyIwxw==}++ resolution: {integrity: sha512-g9ljZiwki/LfxmQADO3dEY1CbpmXT5Hm2fJ+QaGKwSXUylMybePR7/67YW7jOrrvjEgL1Fmz5kzyAjWVWLlucg==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-mDAjwmZdh7LTT6pNleZ05Yt65HC3E+NiQzl672vQG38jIrehtJk/J3mNwIg+vShQPcLF/LV7CMnDW6vjj6sfYQ==}++ resolution: {integrity: sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==}+ engines: {node: '>=6'}++ resolution: {integrity: sha512-OqyPZ9u96VohAyMfJykzmivOrY2wfMSf3C5TtFJVgN+Hm6aj+voFhlK+kZEIv2FBh1X6Xp3DlnCOfEQ3B2J86A==}++ resolution: {integrity: sha512-+FbBPE1o9QAYvviau/qC5SE3caw21q3xkvWKBtja5vgqOWIHHJ3ioaq1VPfn/Szqctz2bU/oYeKd9/z5BL+PVg==}++ resolution: {integrity: sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==}+ engines: {node: '>=12.0.0'}++ resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==}+ engines: {node: '>=8.0'}++ resolution: {integrity: sha512-/m8M+2BJUpoJdgAHoG+baCwBT+tf2VraSfkBgl0Y00qIWt41DJ8R5B8nsEw0I58YwF5IZH6z24/2TobDKnqSWw==}+ engines: {node: '>=12'}++ resolution: {integrity: sha512-605uxS6bcYxGXw9qi62XyrV6Q3xwbndjachmNxu8HWTtVPxZfEJN9fd/SZS1Q54Sn2y0TMyMxFj/cJINqGHrKw==}+ hasBin: true++ resolution: {integrity: sha512-3TaVTaAv2gTiMB35i3FiGJaRfwb3Pyn/j3m/bfAvGe8FB7CF6u+LMYqYlDh7reQf7UNvoTvdfAqHGmPGOSsPmA==}+ engines: {node: '>=18.12'}+ peerDependencies:+ typescript: '>=4.8.4'++ resolution: {integrity: sha512-2Ac2RgzDe/cn48GvOe3M+o82pEFewD3UPbyoUHHdKasHwJKjds4fLXWf/Ux5kATBKN20oaFGu+jbElp1pos0mg==}++ resolution: {integrity: sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==}++ resolution: {integrity: sha512-5C1sg4USs1lfG0GFb2RLXsdpXqBSEhAaA/0kPL01wxzpMqLILNxIxIOKiILz+cdg/pLnOUxFYOR5yhHU666wbw==}+ engines: {node: '>=18.0.0'}+ hasBin: true++ resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==}++ resolution: {integrity: sha512-4kXRLfcygLOeNcP6JquqRLmGB/ATjjfehiojL2dJkL7GFm3SPSXbq7oNj8UbD8XriYQ5hPaSuz59iF1ijPHkTw==}+ cpu: [x64]+ os: [darwin]++ resolution: {integrity: sha512-xF7uCeC0UY0Hrv/tqax0BMbFlVP1J/aRyeGQPZT4NjvIPj8gSPDgFhfkfz06DhUwDg5NgMo04uiSkAWE8WB/QQ==}+ cpu: [arm64]+ os: [darwin]++ resolution: {integrity: sha512-vxMDXwaOjweW/4etY7BxrXCSkvtwh0PbwVafyfT1Ww659SedUxd5rM3V2ZCmbwG8NiCfY7d6VtxyHx3Wh1GoZA==}+ cpu: [x64]+ os: [linux]++ resolution: {integrity: sha512-mQX7uYBZFkuPLLlKaNe9IjR1JIef4YvY8f21xFocvttXvdPebnq3PK1Zjzl9A1zun2BEuWNUwQIL8lgvN9Pm3Q==}+ cpu: [arm64]+ os: [linux]++ resolution: {integrity: sha512-YLGEfppGxZj3VWcNOVa08h6ISsVKiG85aCAWosOKNUjb6yErWEuydv6/qImRJUI+tDLvDvW7BxopAkujRnWCrw==}+ cpu: [x64]+ os: [win32]++ resolution: {integrity: sha512-afTUGKBRmOJU1smQSBnFGcbq0iabAPwh1uXu2BVk7BREg30/1gMnJh9DFEQTah+UD3n3ru8V55J83RQNFfqoyw==}+ cpu: [arm64]+ os: [win32]++ resolution: {integrity: sha512-8Osxz5Tu/Dw2kb31EAY+nhq/YZ3wzmQSmYa1nIArqxgCAldxv9TPlrAiaBUDVnKA4aiPn0OFBD1ACcpc5VFOAQ==}+ hasBin: true++ resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==}+ engines: {node: '>= 0.8.0'}++ resolution: {integrity: sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-BaXgOuIxz8n8pIq3e7Atg/7s+DpiYrxn4vdot3w9KbnBhcRQq6o3xemQdIfynqSeXeDrF32x+WvfzmOjPiY9lg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-bTlAFB/FBYMcuX81gbL4OcpH5PmlFHqlCCpAl8AlEzMz5k53oNDvN8p1PNOWLEmI2x4orp3raOFB51tv9X+MFQ==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-3KS2b+kL7fsuk/eJZ7EQdnEmQoaho/r6KUef7hxvltNA5DR8NAUM+8wJMbJyZ4G9/7i3v5zPBIMN5aybAh2/Jg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==}+ engines: {node: '>=14.17'}+ hasBin: true++ resolution: {integrity: sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==}++ resolution: {integrity: sha512-bSjt9pjaEBnNiGgc9rUiHGKv5l4/TGzDmYw3RhnkJGtLhbnnA/5qJj7x3dNDCRx/PJxu774LlH8lCOlB4hEfKg==}++ resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==}++ resolution: {integrity: sha512-jQL3lRnocaFtu3V00JToYz/4QkNWswxijDaCVNZRiRTO3HQDLsdu1ZtmIUvV4yPp+rvWm5j0y0TG/S61cuijTg==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-OdsJnC/znPvHCHLQH/duvQNXnP1w0hPfS+tkSi3mAbfjYBGh4JnyfdwkQBfIVf7t8gs9eSX/CntxUMvtKdG2MQ==}+ peerDependencies:+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || >=19.0.0-rc <19.0.0 || ^19.0.0++ resolution: {integrity: sha512-Fedw0aZvkhynoPYlA5WXrMCAMm+nSWdZt6lzJQ7Ok8S6Q+VsHmHpRWndVRJ8Be0ZbkfPc5LRYH+5XrzXcEeLRQ==}+ engines: {node: '>=10'}+ peerDependencies:+ '@types/react': '*'+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc+ peerDependenciesMeta:+ '@types/react':+ optional: true++ resolution: {integrity: sha512-Pp6GSwGP/NrPIrxVFAIkOQeyw8lFenOHijQWkUTrDvrF4ALqylP2C/KCkeS9dpUM3KvYRQhna5vt7IL95+ZQ9w==}+ peerDependencies:+ react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0++ resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==}++ resolution: {integrity: sha512-PnpQQMuxlwYdocC8fIJqVXvkeViHYzotI+NJrCuav0ZYFoq912ZHBk3mCeuj+5/VpodOjPe1z0Fk2ihgzlXqjQ==}++ resolution: {integrity: sha512-TbX3mj8n0odCBFVlY8AxkqcHASw3L60jIuF8jFP78az3C2YhmGvqbHBpAjTRH2/xqYunrJ9g1jSyjCjpoWzIAA==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-6iBczoX+kDQ7a3+YJBnh3T+KZRxM/iYNPXicqk66/Qfm1b93iu+yOImkg0zHbj5LNOcNv1TEADiZ0xa34B4q6Q==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-K4jVyjnBdgvc86Y6BkaLZEN933SwYOuBFkdmBu9ZfkcAbdVbpITnDmjvZ/aQjRXQrv5EPkTnD1s39GiiqbngCw==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-LYfpUkmqwl0h9A2HL09Mms427Q1RZWuOHsukfVcKRq9q95iQxdw0ix1JQrqbcDR9PH1QDwf5Qo8OZb5lksZ8Xg==}+ engines: {node: '>= 0.4'}++ resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==}+ engines: {node: '>= 8'}+ hasBin: true++ resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==}+ engines: {node: '>=0.10.0'}++ resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==}++ resolution: {integrity: sha512-blAT2mjOEIi0ZzruJfIhb3nps74PRWTCz1IjglWEEpQl5XS/UNama6u2/rjFkDDouqr4L67ry+1aGIALViWjDg==}+ 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++ resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==}+ engines: {node: '>=10'}++snapshots:++ '@alloc/[email protected]': {}++ '@babel/[email protected]': {}++ '@emnapi/[email protected]':+ dependencies:+ '@emnapi/wasi-threads': 1.1.0+ tslib: 2.8.1+ optional: true++ '@emnapi/[email protected]':+ dependencies:+ tslib: 2.8.1+ optional: true++ '@emnapi/[email protected]':+ dependencies:+ tslib: 2.8.1+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ '@esbuild/[email protected]':+ optional: true++ dependencies:+ eslint: 9.39.2([email protected])+ eslint-visitor-keys: 3.4.3++ '@eslint-community/[email protected]': {}++ '@eslint/[email protected]':+ dependencies:+ '@eslint/object-schema': 2.1.7+ debug: 4.4.3+ minimatch: 3.1.2+ transitivePeerDependencies:+ - supports-color++ '@eslint/[email protected]':+ dependencies:+ '@eslint/core': 0.17.0++ '@eslint/[email protected]':+ dependencies:+ '@types/json-schema': 7.0.15++ '@eslint/[email protected]':+ dependencies:+ ajv: 6.12.6+ debug: 4.4.3+ espree: 10.4.0+ globals: 14.0.0+ ignore: 5.3.2+ import-fresh: 3.3.1+ js-yaml: 4.1.1+ minimatch: 3.1.2+ strip-json-comments: 3.1.1+ transitivePeerDependencies:+ - supports-color++ '@eslint/[email protected]': {}++ '@eslint/[email protected]': {}++ '@eslint/[email protected]':+ dependencies:+ '@eslint/core': 0.17.0+ levn: 0.4.1++ '@fastify/[email protected]':+ dependencies:+ ajv: 8.17.1+ ajv-formats: 2.1.1([email protected])+ fast-uri: 2.4.0++ '@fastify/[email protected]':+ dependencies:+ fastify-plugin: 4.5.1+ mnemonist: 0.39.6++ '@fastify/[email protected]': {}++ '@fastify/[email protected]':+ dependencies:+ fast-json-stringify: 5.16.1++ '@fastify/[email protected]':+ dependencies:+ fast-deep-equal: 3.1.3++ '@floating-ui/[email protected]':+ dependencies:+ '@floating-ui/utils': 0.2.10++ '@floating-ui/[email protected]':+ dependencies:+ '@floating-ui/core': 1.7.4+ '@floating-ui/utils': 0.2.10++ dependencies:+ '@floating-ui/dom': 1.7.5+ react: 19.0.0+ react-dom: 19.0.0([email protected])++ '@floating-ui/[email protected]': {}++ '@formatjs/[email protected]':+ dependencies:+ '@formatjs/fast-memoize': 2.2.7+ '@formatjs/intl-localematcher': 0.6.2+ decimal.js: 10.6.0+ tslib: 2.8.1++ '@formatjs/[email protected]':+ dependencies:+ tslib: 2.8.1++ '@formatjs/[email protected]':+ dependencies:+ '@formatjs/ecma402-abstract': 2.3.6+ '@formatjs/icu-skeleton-parser': 1.8.16+ tslib: 2.8.1++ '@formatjs/[email protected]':+ dependencies:+ '@formatjs/ecma402-abstract': 2.3.6+ tslib: 2.8.1++ '@formatjs/[email protected]':+ dependencies:+ tslib: 2.8.1++ '@formatjs/[email protected]':+ dependencies:+ tslib: 2.8.1++ '@humanfs/[email protected]': {}++ '@humanfs/[email protected]':+ dependencies:+ '@humanfs/core': 0.19.1+ '@humanwhocodes/retry': 0.4.3++ '@humanwhocodes/[email protected]': {}++ '@humanwhocodes/[email protected]': {}++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-darwin-arm64': 1.0.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-darwin-x64': 1.0.4+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-arm64': 1.0.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-arm': 1.0.5+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-s390x': 1.0.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linux-x64': 1.0.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linuxmusl-arm64': 1.0.4+ optional: true++ '@img/[email protected]':+ optionalDependencies:+ '@img/sharp-libvips-linuxmusl-x64': 1.0.4+ optional: true++ '@img/[email protected]':+ dependencies:+ '@emnapi/runtime': 1.8.1+ optional: true++ '@img/[email protected]':+ optional: true++ '@img/[email protected]':+ optional: true++ '@jridgewell/[email protected]':+ dependencies:+ '@jridgewell/sourcemap-codec': 1.5.5+ '@jridgewell/trace-mapping': 0.3.31++ '@jridgewell/[email protected]':+ dependencies:+ '@jridgewell/gen-mapping': 0.3.13+ '@jridgewell/trace-mapping': 0.3.31++ '@jridgewell/[email protected]': {}++ '@jridgewell/[email protected]': {}++ '@jridgewell/[email protected]':+ dependencies:+ '@jridgewell/resolve-uri': 3.1.2+ '@jridgewell/sourcemap-codec': 1.5.5++ '@napi-rs/[email protected]':+ dependencies:+ '@emnapi/core': 1.8.1+ '@emnapi/runtime': 1.8.1+ '@tybys/wasm-util': 0.10.1+ optional: true++ '@next/[email protected]': {}++ '@next/[email protected]':+ dependencies:+ fast-glob: 3.3.1++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@next/[email protected]':+ optional: true++ '@nodelib/[email protected]':+ dependencies:+ '@nodelib/fs.stat': 2.0.5+ run-parallel: 1.2.0++ '@nodelib/[email protected]': {}++ '@nodelib/[email protected]':+ dependencies:+ '@nodelib/fs.scandir': 2.1.5+ fastq: 1.20.1++ '@nolyfill/[email protected]': {}++ '@pinojs/[email protected]': {}++ '@radix-ui/[email protected]': {}++ '@radix-ui/[email protected]': {}++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collapsible': 1.1.12(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dialog': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ aria-hidden: 1.2.6+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-escape-keydown': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-label': 2.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ aria-hidden: 1.2.6+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ aria-hidden: 1.2.6+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-arrow': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-rect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/rect': 1.1.1+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-slot': 1.2.4(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ aria-hidden: 1.2.6+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ react-remove-scroll: 2.7.2(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.4(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/number': 1.1.1+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-previous': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle': 1.1.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-separator': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle-group': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-id': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ react: 19.0.0+ use-sync-external-store: 1.6.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@radix-ui/rect': 1.1.1+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ react: 19.0.0+ optionalDependencies:+ '@types/react': 19.2.11++ '@radix-ui/[email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])':+ dependencies:+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ '@radix-ui/[email protected]': {}++ '@rtsao/[email protected]': {}++ '@rushstack/[email protected]': {}++ '@swc/[email protected]': {}++ '@swc/[email protected]':+ dependencies:+ tslib: 2.8.1++ '@tailwindcss/[email protected]':+ dependencies:+ '@jridgewell/remapping': 2.3.5+ enhanced-resolve: 5.19.0+ jiti: 2.6.1+ lightningcss: 1.30.2+ magic-string: 0.30.21+ source-map-js: 1.2.1+ tailwindcss: 4.1.18++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optional: true++ '@tailwindcss/[email protected]':+ optionalDependencies:+ '@tailwindcss/oxide-android-arm64': 4.1.18+ '@tailwindcss/oxide-darwin-arm64': 4.1.18+ '@tailwindcss/oxide-darwin-x64': 4.1.18+ '@tailwindcss/oxide-freebsd-x64': 4.1.18+ '@tailwindcss/oxide-linux-arm-gnueabihf': 4.1.18+ '@tailwindcss/oxide-linux-arm64-gnu': 4.1.18+ '@tailwindcss/oxide-linux-arm64-musl': 4.1.18+ '@tailwindcss/oxide-linux-x64-gnu': 4.1.18+ '@tailwindcss/oxide-linux-x64-musl': 4.1.18+ '@tailwindcss/oxide-wasm32-wasi': 4.1.18+ '@tailwindcss/oxide-win32-arm64-msvc': 4.1.18+ '@tailwindcss/oxide-win32-x64-msvc': 4.1.18++ '@tailwindcss/[email protected]':+ dependencies:+ '@alloc/quick-lru': 5.2.0+ '@tailwindcss/node': 4.1.18+ '@tailwindcss/oxide': 4.1.18+ postcss: 8.5.6+ tailwindcss: 4.1.18++ '@tybys/[email protected]':+ dependencies:+ tslib: 2.8.1+ optional: true++ '@types/[email protected]':+ dependencies:+ '@types/node': 20.19.31++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]':+ dependencies:+ '@types/d3-color': 3.1.3++ '@types/[email protected]': {}++ '@types/[email protected]':+ dependencies:+ '@types/d3-time': 3.0.4++ '@types/[email protected]':+ dependencies:+ '@types/d3-path': 3.1.1++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]': {}++ '@types/[email protected]':+ dependencies:+ undici-types: 6.21.0++ '@types/[email protected](@types/[email protected])':+ dependencies:+ '@types/react': 19.2.11++ '@types/[email protected]':+ dependencies:+ csstype: 3.2.3++ '@types/[email protected]':+ dependencies:+ '@types/node': 20.19.31++ '@typescript-eslint/[email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]))([email protected])':+ dependencies:+ '@eslint-community/regexpp': 4.12.2+ '@typescript-eslint/scope-manager': 8.54.0+ '@typescript-eslint/visitor-keys': 8.54.0+ eslint: 9.39.2([email protected])+ ignore: 7.0.5+ natural-compare: 1.4.0+ ts-api-utils: 2.4.0([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ dependencies:+ '@typescript-eslint/scope-manager': 8.54.0+ '@typescript-eslint/types': 8.54.0+ '@typescript-eslint/typescript-estree': 8.54.0([email protected])+ '@typescript-eslint/visitor-keys': 8.54.0+ debug: 4.4.3+ eslint: 9.39.2([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]([email protected])':+ dependencies:+ '@typescript-eslint/tsconfig-utils': 8.54.0([email protected])+ '@typescript-eslint/types': 8.54.0+ debug: 4.4.3+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]':+ dependencies:+ '@typescript-eslint/types': 8.54.0+ '@typescript-eslint/visitor-keys': 8.54.0++ '@typescript-eslint/[email protected]([email protected])':+ dependencies:+ typescript: 5.9.3++ dependencies:+ '@typescript-eslint/types': 8.54.0+ '@typescript-eslint/typescript-estree': 8.54.0([email protected])+ debug: 4.4.3+ eslint: 9.39.2([email protected])+ ts-api-utils: 2.4.0([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]': {}++ '@typescript-eslint/[email protected]([email protected])':+ dependencies:+ '@typescript-eslint/project-service': 8.54.0([email protected])+ '@typescript-eslint/tsconfig-utils': 8.54.0([email protected])+ '@typescript-eslint/types': 8.54.0+ '@typescript-eslint/visitor-keys': 8.54.0+ debug: 4.4.3+ minimatch: 9.0.5+ semver: 7.7.3+ tinyglobby: 0.2.15+ ts-api-utils: 2.4.0([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ dependencies:+ '@eslint-community/eslint-utils': 4.9.1([email protected]([email protected]))+ '@typescript-eslint/scope-manager': 8.54.0+ '@typescript-eslint/types': 8.54.0+ '@typescript-eslint/typescript-estree': 8.54.0([email protected])+ eslint: 9.39.2([email protected])+ typescript: 5.9.3+ transitivePeerDependencies:+ - supports-color++ '@typescript-eslint/[email protected]':+ dependencies:+ '@typescript-eslint/types': 8.54.0+ eslint-visitor-keys: 4.2.1++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ dependencies:+ '@napi-rs/wasm-runtime': 0.2.12+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ '@unrs/[email protected]':+ optional: true++ [email protected]: {}++ dependencies:+ acorn: 8.15.0++ [email protected]: {}++ optionalDependencies:+ ajv: 8.17.1++ optionalDependencies:+ ajv: 8.17.1++ dependencies:+ fast-deep-equal: 3.1.3+ fast-json-stable-stringify: 2.1.0+ json-schema-traverse: 0.4.1+ uri-js: 4.4.1++ dependencies:+ fast-deep-equal: 3.1.3+ fast-uri: 3.1.0+ json-schema-traverse: 1.0.0+ require-from-string: 2.0.2++ dependencies:+ color-convert: 2.0.1++ [email protected]: {}++ dependencies:+ tslib: 2.8.1++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4+ is-array-buffer: 3.0.5++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-object-atoms: 1.1.1+ get-intrinsic: 1.3.0+ is-string: 1.1.1+ math-intrinsics: 1.1.0++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ es-object-atoms: 1.1.1+ es-shim-unscopables: 1.1.0++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ es-object-atoms: 1.1.1+ es-shim-unscopables: 1.1.0++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-shim-unscopables: 1.1.0++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-shim-unscopables: 1.1.0++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ es-shim-unscopables: 1.1.0++ dependencies:+ array-buffer-byte-length: 1.0.2+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ get-intrinsic: 1.3.0+ is-array-buffer: 3.0.5++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ possible-typed-array-names: 1.1.0++ dependencies:+ '@fastify/error': 3.4.1+ fastq: 1.20.1++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ bindings: 1.5.0+ prebuild-install: 7.1.3++ dependencies:+ file-uri-to-path: 1.0.0++ dependencies:+ buffer: 5.7.1+ inherits: 2.0.4+ readable-stream: 3.6.2++ dependencies:+ balanced-match: 1.0.2+ concat-map: 0.0.1++ dependencies:+ balanced-match: 1.0.2++ dependencies:+ fill-range: 7.1.1++ dependencies:+ base64-js: 1.5.1+ ieee754: 1.2.1++ dependencies:+ streamsearch: 1.1.0++ dependencies:+ es-errors: 1.3.0+ function-bind: 1.1.2++ dependencies:+ call-bind-apply-helpers: 1.0.2+ es-define-property: 1.0.1+ get-intrinsic: 1.3.0+ set-function-length: 1.2.2++ dependencies:+ call-bind-apply-helpers: 1.0.2+ get-intrinsic: 1.3.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ ansi-styles: 4.3.0+ supports-color: 7.2.0++ [email protected]: {}++ dependencies:+ clsx: 2.1.1++ [email protected]: {}++ [email protected]: {}++ dependencies:+ color-name: 1.1.4++ [email protected]: {}++ dependencies:+ color-name: 1.1.4+ simple-swizzle: 0.2.4+ optional: true++ dependencies:+ color-convert: 2.0.1+ color-string: 1.9.1+ optional: true++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ path-key: 3.1.1+ shebang-command: 2.0.0+ which: 2.0.2++ [email protected]: {}++ dependencies:+ internmap: 1.0.1++ dependencies:+ internmap: 2.0.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ d3-dispatch: 2.0.0+ d3-selection: 2.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ d3-array: 2.12.1++ dependencies:+ d3-color: 2.0.0++ dependencies:+ d3-color: 3.1.0++ [email protected]: {}++ dependencies:+ d3-array: 3.2.4+ d3-format: 3.1.2+ d3-interpolate: 3.0.1+ d3-time: 3.1.0+ d3-time-format: 4.1.0++ [email protected]: {}++ dependencies:+ d3-path: 3.1.0++ dependencies:+ d3-time: 3.1.0++ dependencies:+ d3-array: 3.2.4++ [email protected]: {}++ [email protected]: {}++ dependencies:+ d3-color: 2.0.0+ d3-dispatch: 2.0.0+ d3-ease: 2.0.0+ d3-interpolate: 2.0.1+ d3-selection: 2.0.0+ d3-timer: 2.0.0++ dependencies:+ d3-dispatch: 2.0.0+ d3-drag: 2.0.0+ d3-interpolate: 2.0.1+ d3-selection: 2.0.0+ d3-transition: 2.0.0([email protected])++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ is-data-view: 1.0.2++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ is-data-view: 1.0.2++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ is-data-view: 1.0.2++ dependencies:+ ms: 2.1.3++ dependencies:+ ms: 2.1.3++ [email protected]: {}++ [email protected]: {}++ dependencies:+ mimic-response: 3.1.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ es-define-property: 1.0.1+ es-errors: 1.3.0+ gopd: 1.2.0++ dependencies:+ define-data-property: 1.1.4+ has-property-descriptors: 1.0.2+ object-keys: 1.1.1++ [email protected]: {}++ [email protected]: {}++ dependencies:+ esutils: 2.0.3++ dependencies:+ '@babel/runtime': 7.28.6+ csstype: 3.2.3++ [email protected]: {}++ dependencies:+ call-bind-apply-helpers: 1.0.2+ es-errors: 1.3.0+ gopd: 1.2.0++ [email protected]: {}++ dependencies:+ once: 1.4.0++ dependencies:+ graceful-fs: 4.2.11+ tapable: 2.3.0++ 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.4+ 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.1.1+ es-set-tostringtag: 2.1.0+ es-to-primitive: 1.3.0+ function.prototype.name: 1.1.8+ get-intrinsic: 1.3.0+ get-proto: 1.0.1+ 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-negative-zero: 2.0.3+ is-regex: 1.2.1+ is-set: 2.0.3+ is-shared-array-buffer: 1.0.4+ is-string: 1.1.1+ is-typed-array: 1.1.15+ is-weakref: 1.1.1+ math-intrinsics: 1.1.0+ object-inspect: 1.13.4+ object-keys: 1.1.1+ object.assign: 4.1.7+ own-keys: 1.0.1+ regexp.prototype.flags: 1.5.4+ safe-array-concat: 1.1.3+ safe-push-apply: 1.0.0+ safe-regex-test: 1.1.0+ set-proto: 1.0.0+ stop-iteration-iterator: 1.1.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.20++ [email protected]: {}++ [email protected]: {}++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ es-set-tostringtag: 2.1.0+ function-bind: 1.1.2+ get-intrinsic: 1.3.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+ internal-slot: 1.1.0+ iterator.prototype: 1.1.5+ safe-array-concat: 1.1.3++ dependencies:+ es-errors: 1.3.0++ dependencies:+ es-errors: 1.3.0+ get-intrinsic: 1.3.0+ has-tostringtag: 1.0.2+ hasown: 2.0.2++ dependencies:+ hasown: 2.0.2++ dependencies:+ is-callable: 1.2.7+ is-date-object: 1.1.0+ is-symbol: 1.1.1++ optionalDependencies:+ '@esbuild/aix-ppc64': 0.27.2+ '@esbuild/android-arm': 0.27.2+ '@esbuild/android-arm64': 0.27.2+ '@esbuild/android-x64': 0.27.2+ '@esbuild/darwin-arm64': 0.27.2+ '@esbuild/darwin-x64': 0.27.2+ '@esbuild/freebsd-arm64': 0.27.2+ '@esbuild/freebsd-x64': 0.27.2+ '@esbuild/linux-arm': 0.27.2+ '@esbuild/linux-arm64': 0.27.2+ '@esbuild/linux-ia32': 0.27.2+ '@esbuild/linux-loong64': 0.27.2+ '@esbuild/linux-mips64el': 0.27.2+ '@esbuild/linux-ppc64': 0.27.2+ '@esbuild/linux-riscv64': 0.27.2+ '@esbuild/linux-s390x': 0.27.2+ '@esbuild/linux-x64': 0.27.2+ '@esbuild/netbsd-arm64': 0.27.2+ '@esbuild/netbsd-x64': 0.27.2+ '@esbuild/openbsd-arm64': 0.27.2+ '@esbuild/openbsd-x64': 0.27.2+ '@esbuild/openharmony-arm64': 0.27.2+ '@esbuild/sunos-x64': 0.27.2+ '@esbuild/win32-arm64': 0.27.2+ '@esbuild/win32-ia32': 0.27.2+ '@esbuild/win32-x64': 0.27.2++ [email protected]: {}++ dependencies:+ '@next/eslint-plugin-next': 15.1.6+ '@rushstack/eslint-patch': 1.15.0+ '@typescript-eslint/eslint-plugin': 8.54.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected]([email protected]))([email protected])+ eslint: 9.39.2([email protected])+ eslint-import-resolver-node: 0.3.9+ eslint-import-resolver-typescript: 3.10.1([email protected])([email protected]([email protected]))+ eslint-plugin-import: 2.32.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected]))+ eslint-plugin-jsx-a11y: 6.10.2([email protected]([email protected]))+ eslint-plugin-react: 7.37.5([email protected]([email protected]))+ eslint-plugin-react-hooks: 5.2.0([email protected]([email protected]))+ optionalDependencies:+ typescript: 5.9.3+ transitivePeerDependencies:+ - eslint-import-resolver-webpack+ - eslint-plugin-import-x+ - supports-color++ dependencies:+ debug: 3.2.7+ is-core-module: 2.16.1+ resolve: 1.22.11+ transitivePeerDependencies:+ - supports-color++ dependencies:+ '@nolyfill/is-core-module': 1.0.39+ debug: 4.4.3+ eslint: 9.39.2([email protected])+ get-tsconfig: 4.13.1+ is-bun-module: 2.0.0+ stable-hash: 0.0.5+ tinyglobby: 0.2.15+ unrs-resolver: 1.11.1+ optionalDependencies:+ eslint-plugin-import: 2.32.0(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected]))+ transitivePeerDependencies:+ - supports-color++ [email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected])([email protected]([email protected])))([email protected]([email protected])):+ dependencies:+ debug: 3.2.7+ optionalDependencies:+ eslint: 9.39.2([email protected])+ eslint-import-resolver-node: 0.3.9+ eslint-import-resolver-typescript: 3.10.1([email protected])([email protected]([email protected]))+ transitivePeerDependencies:+ - supports-color++ [email protected](@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected])):+ dependencies:+ '@rtsao/scc': 1.1.0+ array-includes: 3.1.9+ array.prototype.findlastindex: 1.2.6+ array.prototype.flat: 1.3.3+ array.prototype.flatmap: 1.3.3+ debug: 3.2.7+ doctrine: 2.1.0+ eslint: 9.39.2([email protected])+ eslint-import-resolver-node: 0.3.9+ eslint-module-utils: 2.12.1(@typescript-eslint/[email protected]([email protected]([email protected]))([email protected]))([email protected])([email protected]([email protected])([email protected]([email protected])))([email protected]([email protected]))+ hasown: 2.0.2+ is-core-module: 2.16.1+ is-glob: 4.0.3+ minimatch: 3.1.2+ object.fromentries: 2.0.8+ object.groupby: 1.0.3+ object.values: 1.2.1+ semver: 6.3.1+ string.prototype.trimend: 1.0.9+ tsconfig-paths: 3.15.0+ optionalDependencies:+ transitivePeerDependencies:+ - eslint-import-resolver-typescript+ - eslint-import-resolver-webpack+ - supports-color++ dependencies:+ aria-query: 5.3.2+ array-includes: 3.1.9+ array.prototype.flatmap: 1.3.3+ ast-types-flow: 0.0.8+ axe-core: 4.11.1+ axobject-query: 4.1.0+ damerau-levenshtein: 1.0.8+ emoji-regex: 9.2.2+ eslint: 9.39.2([email protected])+ 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.1.0+ string.prototype.includes: 2.0.1++ dependencies:+ eslint: 9.39.2([email protected])++ dependencies:+ array-includes: 3.1.9+ array.prototype.findlast: 1.2.5+ array.prototype.flatmap: 1.3.3+ array.prototype.tosorted: 1.1.4+ doctrine: 2.1.0+ es-iterator-helpers: 1.2.2+ eslint: 9.39.2([email protected])+ estraverse: 5.3.0+ hasown: 2.0.2+ jsx-ast-utils: 3.3.5+ minimatch: 3.1.2+ object.entries: 1.1.9+ object.fromentries: 2.0.8+ object.values: 1.2.1+ prop-types: 15.8.1+ resolve: 2.0.0-next.5+ semver: 6.3.1+ string.prototype.matchall: 4.0.12+ string.prototype.repeat: 1.0.0++ dependencies:+ esrecurse: 4.3.0+ estraverse: 5.3.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@eslint-community/eslint-utils': 4.9.1([email protected]([email protected]))+ '@eslint-community/regexpp': 4.12.2+ '@eslint/config-array': 0.21.1+ '@eslint/config-helpers': 0.4.2+ '@eslint/core': 0.17.0+ '@eslint/eslintrc': 3.3.3+ '@eslint/js': 9.39.2+ '@eslint/plugin-kit': 0.4.1+ '@humanfs/node': 0.16.7+ '@humanwhocodes/module-importer': 1.0.1+ '@humanwhocodes/retry': 0.4.3+ '@types/estree': 1.0.8+ ajv: 6.12.6+ chalk: 4.1.2+ cross-spawn: 7.0.6+ debug: 4.4.3+ escape-string-regexp: 4.0.0+ eslint-scope: 8.4.0+ eslint-visitor-keys: 4.2.1+ espree: 10.4.0+ esquery: 1.7.0+ esutils: 2.0.3+ fast-deep-equal: 3.1.3+ file-entry-cache: 8.0.0+ find-up: 5.0.0+ glob-parent: 6.0.2+ ignore: 5.3.2+ imurmurhash: 0.1.4+ is-glob: 4.0.3+ 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.4+ optionalDependencies:+ jiti: 2.6.1+ transitivePeerDependencies:+ - supports-color++ dependencies:+ acorn: 8.15.0+ acorn-jsx: 5.3.2([email protected])+ eslint-visitor-keys: 4.2.1++ dependencies:+ estraverse: 5.3.0++ dependencies:+ estraverse: 5.3.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@nodelib/fs.stat': 2.0.5+ '@nodelib/fs.walk': 1.2.8+ glob-parent: 5.1.2+ merge2: 1.4.1+ micromatch: 4.0.8++ [email protected]: {}++ dependencies:+ '@fastify/merge-json-schemas': 0.1.1+ ajv: 8.17.1+ ajv-formats: 3.0.1([email protected])+ fast-deep-equal: 3.1.3+ fast-uri: 2.4.0+ json-schema-ref-resolver: 1.0.1+ rfdc: 1.4.1++ [email protected]: {}++ dependencies:+ fast-decode-uri-component: 1.0.1++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@fastify/ajv-compiler': 3.6.0+ '@fastify/error': 3.4.1+ '@fastify/fast-json-stringify-compiler': 4.3.0+ abstract-logging: 2.0.1+ avvio: 8.4.0+ fast-content-type-parse: 1.1.0+ fast-json-stringify: 5.16.1+ find-my-way: 8.2.2+ light-my-request: 5.14.0+ pino: 9.14.0+ process-warning: 3.0.0+ proxy-addr: 2.0.7+ rfdc: 1.4.1+ secure-json-parse: 2.7.0+ semver: 7.7.3+ toad-cache: 3.7.0++ dependencies:+ reusify: 1.1.0++ optionalDependencies:+ picomatch: 4.0.3++ dependencies:+ flat-cache: 4.0.1++ [email protected]: {}++ dependencies:+ to-regex-range: 5.0.1++ dependencies:+ fast-deep-equal: 3.1.3+ fast-querystring: 1.1.2+ safe-regex2: 3.1.0++ dependencies:+ locate-path: 6.0.0+ path-exists: 4.0.0++ dependencies:+ flatted: 3.3.3+ keyv: 4.5.4++ [email protected]: {}++ dependencies:+ is-callable: 1.2.7++ [email protected]: {}++ [email protected]: {}++ optional: true++ [email protected]: {}++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ functions-have-names: 1.2.3+ hasown: 2.0.2+ is-callable: 1.2.7++ [email protected]: {}++ [email protected]: {}++ dependencies:+ call-bind-apply-helpers: 1.0.2+ es-define-property: 1.0.1+ es-errors: 1.3.0+ es-object-atoms: 1.1.1+ function-bind: 1.1.2+ get-proto: 1.0.1+ gopd: 1.2.0+ has-symbols: 1.1.0+ hasown: 2.0.2+ math-intrinsics: 1.1.0++ [email protected]: {}++ dependencies:+ dunder-proto: 1.0.1+ es-object-atoms: 1.1.1++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ get-intrinsic: 1.3.0++ dependencies:+ resolve-pkg-maps: 1.0.0++ [email protected]: {}++ dependencies:+ is-glob: 4.0.3++ dependencies:+ is-glob: 4.0.3++ [email protected]: {}++ dependencies:+ define-properties: 1.2.1+ gopd: 1.2.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ es-define-property: 1.0.1++ dependencies:+ dunder-proto: 1.0.1++ [email protected]: {}++ dependencies:+ has-symbols: 1.1.0++ dependencies:+ function-bind: 1.1.2++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ parent-module: 1.0.1+ resolve-from: 4.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ es-errors: 1.3.0+ hasown: 2.0.2+ side-channel: 1.1.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ '@formatjs/ecma402-abstract': 2.3.6+ '@formatjs/fast-memoize': 2.2.7+ '@formatjs/icu-messageformat-parser': 2.11.4+ tslib: 2.8.1++ [email protected]: {}++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ get-intrinsic: 1.3.0++ optional: true++ dependencies:+ async-function: 1.0.0+ call-bound: 1.0.4+ get-proto: 1.0.1+ has-tostringtag: 1.0.2+ safe-regex-test: 1.1.0++ dependencies:+ has-bigints: 1.1.0++ dependencies:+ call-bound: 1.0.4+ has-tostringtag: 1.0.2++ dependencies:+ semver: 7.7.3++ [email protected]: {}++ dependencies:+ hasown: 2.0.2++ dependencies:+ call-bound: 1.0.4+ get-intrinsic: 1.3.0+ is-typed-array: 1.1.15++ dependencies:+ call-bound: 1.0.4+ has-tostringtag: 1.0.2++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4++ dependencies:+ call-bound: 1.0.4+ generator-function: 2.0.1+ get-proto: 1.0.1+ has-tostringtag: 1.0.2+ safe-regex-test: 1.1.0++ dependencies:+ is-extglob: 2.1.1++ [email protected]: {}++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4+ has-tostringtag: 1.0.2++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4+ gopd: 1.2.0+ has-tostringtag: 1.0.2+ hasown: 2.0.2++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4++ dependencies:+ call-bound: 1.0.4+ has-tostringtag: 1.0.2++ dependencies:+ call-bound: 1.0.4+ has-symbols: 1.1.0+ safe-regex-test: 1.1.0++ dependencies:+ which-typed-array: 1.1.20++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4++ dependencies:+ call-bound: 1.0.4+ get-intrinsic: 1.3.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ define-data-property: 1.1.4+ es-object-atoms: 1.1.1+ get-intrinsic: 1.3.0+ get-proto: 1.0.1+ has-symbols: 1.1.0+ set-function-name: 2.0.2++ [email protected]: {}++ [email protected]: {}++ dependencies:+ argparse: 2.0.1++ [email protected]: {}++ dependencies:+ fast-deep-equal: 3.1.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ minimist: 1.2.8++ dependencies:+ array-includes: 3.1.9+ array.prototype.flat: 1.3.3+ object.assign: 4.1.7+ object.values: 1.2.1++ dependencies:+ json-buffer: 3.0.1++ [email protected]: {}++ dependencies:+ language-subtag-registry: 0.3.23++ dependencies:+ prelude-ls: 1.2.1+ type-check: 0.4.0++ dependencies:+ cookie: 0.7.2+ process-warning: 3.0.0+ set-cookie-parser: 2.7.2++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ dependencies:+ detect-libc: 2.1.2+ optionalDependencies:+ lightningcss-android-arm64: 1.30.2+ lightningcss-darwin-arm64: 1.30.2+ lightningcss-darwin-x64: 1.30.2+ lightningcss-freebsd-x64: 1.30.2+ lightningcss-linux-arm-gnueabihf: 1.30.2+ lightningcss-linux-arm64-gnu: 1.30.2+ lightningcss-linux-arm64-musl: 1.30.2+ lightningcss-linux-x64-gnu: 1.30.2+ lightningcss-linux-x64-musl: 1.30.2+ lightningcss-win32-arm64-msvc: 1.30.2+ lightningcss-win32-x64-msvc: 1.30.2++ dependencies:+ p-locate: 5.0.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ js-tokens: 4.0.0++ dependencies:+ react: 19.0.0++ dependencies:+ '@jridgewell/sourcemap-codec': 1.5.5++ [email protected]: {}++ [email protected]: {}++ dependencies:+ braces: 3.0.3+ picomatch: 2.3.1++ [email protected]: {}++ dependencies:+ brace-expansion: 1.1.12++ dependencies:+ brace-expansion: 2.0.2++ [email protected]: {}++ [email protected]: {}++ dependencies:+ obliterator: 2.0.5++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]([email protected]([email protected]([email protected]))([email protected]))([email protected]):+ dependencies:+ '@formatjs/intl-localematcher': 0.5.10+ negotiator: 1.0.0+ react: 19.0.0+ use-intl: 3.26.5([email protected])++ dependencies:+ react: 19.0.0+ react-dom: 19.0.0([email protected])++ dependencies:+ '@next/env': 15.1.6+ '@swc/counter': 0.1.3+ '@swc/helpers': 0.5.15+ busboy: 1.6.0+ caniuse-lite: 1.0.30001767+ postcss: 8.4.31+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ styled-jsx: 5.1.6([email protected])+ optionalDependencies:+ '@next/swc-darwin-arm64': 15.1.6+ '@next/swc-darwin-x64': 15.1.6+ '@next/swc-linux-arm64-gnu': 15.1.6+ '@next/swc-linux-arm64-musl': 15.1.6+ '@next/swc-linux-x64-gnu': 15.1.6+ '@next/swc-linux-x64-musl': 15.1.6+ '@next/swc-win32-arm64-msvc': 15.1.6+ '@next/swc-win32-x64-msvc': 15.1.6+ sharp: 0.33.5+ transitivePeerDependencies:+ - '@babel/core'+ - babel-plugin-macros++ dependencies:+ semver: 7.7.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-object-atoms: 1.1.1+ has-symbols: 1.1.0+ object-keys: 1.1.1++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-object-atoms: 1.1.1++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-object-atoms: 1.1.1++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-object-atoms: 1.1.1++ [email protected]: {}++ [email protected]: {}++ dependencies:+ wrappy: 1.0.2++ dependencies:+ deep-is: 0.1.4+ fast-levenshtein: 2.0.6+ levn: 0.4.1+ prelude-ls: 1.2.1+ type-check: 0.4.0+ word-wrap: 1.2.5++ dependencies:+ get-intrinsic: 1.3.0+ object-keys: 1.1.1+ safe-push-apply: 1.0.0++ dependencies:+ yocto-queue: 0.1.0++ dependencies:+ p-limit: 3.1.0++ dependencies:+ callsites: 3.1.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ split2: 4.2.0++ [email protected]: {}++ dependencies:+ '@pinojs/redact': 0.4.0+ atomic-sleep: 1.0.0+ on-exit-leak-free: 2.1.2+ pino-abstract-transport: 2.0.0+ pino-std-serializers: 7.1.0+ process-warning: 5.0.0+ quick-format-unescaped: 4.0.4+ real-require: 0.2.0+ safe-stable-stringify: 2.5.0+ sonic-boom: 4.2.0+ thread-stream: 3.1.0++ [email protected]: {}++ dependencies:+ nanoid: 3.3.11+ picocolors: 1.1.1+ source-map-js: 1.2.1++ dependencies:+ nanoid: 3.3.11+ picocolors: 1.1.1+ source-map-js: 1.2.1++ dependencies:+ detect-libc: 2.1.2+ expand-template: 2.0.3+ github-from-package: 0.0.0+ minimist: 1.2.8+ mkdirp-classic: 0.5.3+ napi-build-utils: 2.0.0+ node-abi: 3.87.0+ pump: 3.0.3+ rc: 1.2.8+ simple-get: 4.0.1+ tar-fs: 2.1.4+ tunnel-agent: 0.6.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ loose-envify: 1.4.0+ object-assign: 4.1.1+ react-is: 16.13.1++ dependencies:+ forwarded: 0.2.0+ ipaddr.js: 1.9.1++ dependencies:+ end-of-stream: 1.4.5+ once: 1.4.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected](@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected]):+ dependencies:+ '@radix-ui/primitive': 1.1.3+ '@radix-ui/react-accessible-icon': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-accordion': 1.2.12(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-alert-dialog': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-arrow': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-aspect-ratio': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-avatar': 1.1.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-checkbox': 1.3.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-collapsible': 1.1.12(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-collection': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-compose-refs': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context': 1.1.2(@types/[email protected])([email protected])+ '@radix-ui/react-context-menu': 2.2.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-dialog': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-direction': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-dismissable-layer': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-dropdown-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-focus-guards': 1.1.3(@types/[email protected])([email protected])+ '@radix-ui/react-focus-scope': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-form': 0.1.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-hover-card': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-label': 2.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-menu': 2.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-menubar': 1.1.16(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-navigation-menu': 1.2.14(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-one-time-password-field': 0.1.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-password-toggle-field': 0.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popover': 1.1.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-popper': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-portal': 1.1.9(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-presence': 1.1.5(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-primitive': 2.1.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-progress': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-radio-group': 1.3.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-roving-focus': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-scroll-area': 1.2.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-select': 2.2.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-separator': 1.1.7(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slider': 1.3.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-slot': 1.2.3(@types/[email protected])([email protected])+ '@radix-ui/react-switch': 1.2.6(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-tabs': 1.1.13(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toast': 1.2.15(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle': 1.1.10(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toggle-group': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-toolbar': 1.1.11(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-tooltip': 1.2.8(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ '@radix-ui/react-use-callback-ref': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-controllable-state': 1.2.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-effect-event': 0.0.2(@types/[email protected])([email protected])+ '@radix-ui/react-use-escape-keydown': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-is-hydrated': 0.1.0(@types/[email protected])([email protected])+ '@radix-ui/react-use-layout-effect': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-use-size': 1.1.1(@types/[email protected])([email protected])+ '@radix-ui/react-visually-hidden': 1.2.3(@types/[email protected](@types/[email protected]))(@types/[email protected])([email protected]([email protected]))([email protected])+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ optionalDependencies:+ '@types/react': 19.2.11+ '@types/react-dom': 19.2.3(@types/[email protected])++ dependencies:+ deep-extend: 0.6.0+ ini: 1.3.8+ minimist: 1.2.8+ strip-json-comments: 2.0.1++ dependencies:+ react: 19.0.0+ scheduler: 0.25.0++ [email protected]: {}++ [email protected]: {}++ dependencies:+ react: 19.0.0+ react-style-singleton: 2.2.3(@types/[email protected])([email protected])+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ react: 19.0.0+ react-remove-scroll-bar: 2.3.8(@types/[email protected])([email protected])+ react-style-singleton: 2.2.3(@types/[email protected])([email protected])+ tslib: 2.8.1+ use-callback-ref: 1.3.3(@types/[email protected])([email protected])+ use-sidecar: 1.1.3(@types/[email protected])([email protected])+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ d3-geo: 2.0.2+ d3-selection: 2.0.0+ d3-zoom: 2.0.0+ prop-types: 15.8.1+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ topojson-client: 3.1.0++ dependencies:+ fast-equals: 5.4.0+ prop-types: 15.8.1+ react: 19.0.0+ react-dom: 19.0.0([email protected])++ dependencies:+ get-nonce: 1.0.1+ react: 19.0.0+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@babel/runtime': 7.28.6+ dom-helpers: 5.2.1+ loose-envify: 1.4.0+ prop-types: 15.8.1+ react: 19.0.0+ react-dom: 19.0.0([email protected])++ [email protected]: {}++ dependencies:+ inherits: 2.0.4+ string_decoder: 1.3.0+ util-deprecate: 1.0.2++ [email protected]: {}++ dependencies:+ decimal.js-light: 2.5.1++ dependencies:+ clsx: 2.1.1+ eventemitter3: 4.0.7+ lodash: 4.17.23+ react: 19.0.0+ react-dom: 19.0.0([email protected])+ react-is: 18.3.1+ recharts-scale: 0.4.5+ tiny-invariant: 1.3.3+ victory-vendor: 36.9.2++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ es-object-atoms: 1.1.1+ get-intrinsic: 1.3.0+ get-proto: 1.0.1+ which-builtin-type: 1.2.1++ 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++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ is-core-module: 2.16.1+ path-parse: 1.0.7+ supports-preserve-symlinks-flag: 1.0.0++ dependencies:+ is-core-module: 2.16.1+ path-parse: 1.0.7+ supports-preserve-symlinks-flag: 1.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ queue-microtask: 1.2.3++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ get-intrinsic: 1.3.0+ has-symbols: 1.1.0+ isarray: 2.0.5++ [email protected]: {}++ dependencies:+ es-errors: 1.3.0+ isarray: 2.0.5++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ is-regex: 1.2.1++ dependencies:+ ret: 0.4.3++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ define-data-property: 1.1.4+ es-errors: 1.3.0+ function-bind: 1.1.2+ get-intrinsic: 1.3.0+ gopd: 1.2.0+ has-property-descriptors: 1.0.2++ dependencies:+ define-data-property: 1.1.4+ es-errors: 1.3.0+ functions-have-names: 1.2.3+ has-property-descriptors: 1.0.2++ dependencies:+ dunder-proto: 1.0.1+ es-errors: 1.3.0+ es-object-atoms: 1.1.1++ dependencies:+ color: 4.2.3+ detect-libc: 2.1.2+ semver: 7.7.3+ 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+ optional: true++ dependencies:+ shebang-regex: 3.0.0++ [email protected]: {}++ dependencies:+ es-errors: 1.3.0+ object-inspect: 1.13.4++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ get-intrinsic: 1.3.0+ object-inspect: 1.13.4++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ get-intrinsic: 1.3.0+ object-inspect: 1.13.4+ side-channel-map: 1.0.1++ dependencies:+ es-errors: 1.3.0+ object-inspect: 1.13.4+ side-channel-list: 1.0.0+ side-channel-map: 1.0.1+ side-channel-weakmap: 1.0.2++ [email protected]: {}++ dependencies:+ decompress-response: 6.0.0+ once: 1.4.0+ simple-concat: 1.0.1++ dependencies:+ is-arrayish: 0.3.4+ optional: true++ dependencies:+ atomic-sleep: 1.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ es-errors: 1.3.0+ internal-slot: 1.1.0++ [email protected]: {}++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-abstract: 1.24.1++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-errors: 1.3.0+ es-object-atoms: 1.1.1+ get-intrinsic: 1.3.0+ gopd: 1.2.0+ has-symbols: 1.1.0+ internal-slot: 1.1.0+ regexp.prototype.flags: 1.5.4+ set-function-name: 2.0.2+ side-channel: 1.1.0++ dependencies:+ define-properties: 1.2.1+ es-abstract: 1.24.1++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-data-property: 1.1.4+ define-properties: 1.2.1+ es-abstract: 1.24.1+ es-object-atoms: 1.1.1+ has-property-descriptors: 1.0.2++ dependencies:+ call-bind: 1.0.8+ call-bound: 1.0.4+ define-properties: 1.2.1+ es-object-atoms: 1.1.1++ dependencies:+ call-bind: 1.0.8+ define-properties: 1.2.1+ es-object-atoms: 1.1.1++ dependencies:+ safe-buffer: 5.2.1++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ client-only: 0.0.1+ react: 19.0.0++ dependencies:+ has-flag: 4.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ dependencies:+ chownr: 1.1.4+ mkdirp-classic: 0.5.3+ pump: 3.0.3+ tar-stream: 2.2.0++ dependencies:+ bl: 4.1.0+ end-of-stream: 1.4.5+ fs-constants: 1.0.0+ inherits: 2.0.4+ readable-stream: 3.6.2++ dependencies:+ real-require: 0.2.0++ [email protected]: {}++ dependencies:+ fdir: 6.5.0([email protected])+ picomatch: 4.0.3++ dependencies:+ is-number: 7.0.0++ [email protected]: {}++ dependencies:+ commander: 2.20.3++ dependencies:+ typescript: 5.9.3++ dependencies:+ '@types/json5': 0.0.29+ json5: 1.0.2+ minimist: 1.2.8+ strip-bom: 3.0.0++ [email protected]: {}++ dependencies:+ esbuild: 0.27.2+ get-tsconfig: 4.13.1+ optionalDependencies:+ fsevents: 2.3.3++ dependencies:+ safe-buffer: 5.2.1++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optional: true++ optionalDependencies:+ turbo-darwin-64: 2.8.3+ turbo-darwin-arm64: 2.8.3+ turbo-linux-64: 2.8.3+ turbo-linux-arm64: 2.8.3+ turbo-windows-64: 2.8.3+ turbo-windows-arm64: 2.8.3++ dependencies:+ prelude-ls: 1.2.1++ dependencies:+ call-bound: 1.0.4+ es-errors: 1.3.0+ is-typed-array: 1.1.15++ dependencies:+ call-bind: 1.0.8+ for-each: 0.3.5+ gopd: 1.2.0+ has-proto: 1.2.0+ is-typed-array: 1.1.15++ dependencies:+ available-typed-arrays: 1.0.7+ call-bind: 1.0.8+ for-each: 0.3.5+ gopd: 1.2.0+ has-proto: 1.2.0+ is-typed-array: 1.1.15+ reflect.getprototypeof: 1.0.10++ dependencies:+ call-bind: 1.0.8+ for-each: 0.3.5+ gopd: 1.2.0+ is-typed-array: 1.1.15+ possible-typed-array-names: 1.1.0+ reflect.getprototypeof: 1.0.10++ [email protected]: {}++ dependencies:+ call-bound: 1.0.4+ has-bigints: 1.1.0+ has-symbols: 1.1.0+ which-boxed-primitive: 1.1.1++ [email protected]: {}++ dependencies:+ napi-postinstall: 0.3.4+ optionalDependencies:+ '@unrs/resolver-binding-android-arm-eabi': 1.11.1+ '@unrs/resolver-binding-android-arm64': 1.11.1+ '@unrs/resolver-binding-darwin-arm64': 1.11.1+ '@unrs/resolver-binding-darwin-x64': 1.11.1+ '@unrs/resolver-binding-freebsd-x64': 1.11.1+ '@unrs/resolver-binding-linux-arm-gnueabihf': 1.11.1+ '@unrs/resolver-binding-linux-arm-musleabihf': 1.11.1+ '@unrs/resolver-binding-linux-arm64-gnu': 1.11.1+ '@unrs/resolver-binding-linux-arm64-musl': 1.11.1+ '@unrs/resolver-binding-linux-ppc64-gnu': 1.11.1+ '@unrs/resolver-binding-linux-riscv64-gnu': 1.11.1+ '@unrs/resolver-binding-linux-riscv64-musl': 1.11.1+ '@unrs/resolver-binding-linux-s390x-gnu': 1.11.1+ '@unrs/resolver-binding-linux-x64-gnu': 1.11.1+ '@unrs/resolver-binding-linux-x64-musl': 1.11.1+ '@unrs/resolver-binding-wasm32-wasi': 1.11.1+ '@unrs/resolver-binding-win32-arm64-msvc': 1.11.1+ '@unrs/resolver-binding-win32-ia32-msvc': 1.11.1+ '@unrs/resolver-binding-win32-x64-msvc': 1.11.1++ dependencies:+ punycode: 2.3.1++ dependencies:+ react: 19.0.0+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ '@formatjs/fast-memoize': 2.2.7+ intl-messageformat: 10.7.18+ react: 19.0.0++ dependencies:+ detect-node-es: 1.1.0+ react: 19.0.0+ tslib: 2.8.1+ optionalDependencies:+ '@types/react': 19.2.11++ dependencies:+ react: 19.0.0++ [email protected]: {}++ dependencies:+ '@types/d3-array': 3.2.2+ '@types/d3-ease': 3.0.2+ '@types/d3-interpolate': 3.0.4+ '@types/d3-scale': 4.0.9+ '@types/d3-shape': 3.1.8+ '@types/d3-time': 3.0.4+ '@types/d3-timer': 3.0.2+ d3-array: 3.2.4+ d3-ease: 3.0.1+ d3-interpolate: 3.0.1+ d3-scale: 4.0.2+ d3-shape: 3.2.0+ d3-time: 3.1.0+ d3-timer: 3.0.1++ dependencies:+ is-bigint: 1.1.0+ is-boolean-object: 1.2.2+ is-number-object: 1.1.1+ is-string: 1.1.1+ is-symbol: 1.1.1++ dependencies:+ call-bound: 1.0.4+ function.prototype.name: 1.1.8+ has-tostringtag: 1.0.2+ is-async-function: 2.1.1+ is-date-object: 1.1.0+ is-finalizationregistry: 1.1.1+ is-generator-function: 1.1.2+ is-regex: 1.2.1+ is-weakref: 1.1.1+ isarray: 2.0.5+ which-boxed-primitive: 1.1.1+ which-collection: 1.0.2+ which-typed-array: 1.1.20++ dependencies:+ is-map: 2.0.3+ is-set: 2.0.3+ is-weakmap: 2.0.2+ is-weakset: 2.0.4++ dependencies:+ available-typed-arrays: 1.0.7+ call-bind: 1.0.8+ call-bound: 1.0.4+ for-each: 0.3.5+ get-proto: 1.0.1+ gopd: 1.2.0+ has-tostringtag: 1.0.2++ dependencies:+ isexe: 2.0.0++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}++ [email protected]: {}diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yamlnew file mode 100644index 0000000..286cf7f--- /dev/null+++ b/pnpm-workspace.yaml@@ -0,0 +1,3 @@+packages:+ - apps/*+ - packages/*diff --git a/start.sh b/start.shnew file mode 100755index 0000000..0261c33--- /dev/null+++ b/start.sh@@ -0,0 +1,53 @@+#!/bin/bash++# ClashStats 启动脚本++set -e++echo "╔════════════════════════════════════════════════════════╗"+echo "║ OpenClash Traffic Statistics System ║"+echo "╚════════════════════════════════════════════════════════╝"+echo++# 颜色定义+RED='\033[0;31m'+GREEN='\033[0;32m'+YELLOW='\033[1;33m'+BLUE='\033[0;34m'+NC='\033[0m' # No Color++# 检查 pnpm+if ! command -v pnpm &> /dev/null; then+ echo -e "${RED}Error: pnpm is not installed${NC}"+ echo "Please install pnpm first: npm install -g pnpm"+ exit 1+fi++# 安装依赖+echo -e "${BLUE}[1/3] Installing dependencies...${NC}"+pnpm install++# 检查环境变量+echo+echo -e "${BLUE}[2/3] Checking environment configuration...${NC}"+if [ ! -f "apps/collector/.env" ]; then+ echo -e "${YELLOW}Warning: .env file not found in apps/collector/${NC}"+ echo "Creating from template..."+ cp apps/collector/.env.example apps/collector/.env+ echo -e "${YELLOW}Please edit apps/collector/.env with your OpenClash configuration${NC}"+ exit 1+fi++echo -e "${GREEN}✓ Environment configured${NC}"++# 启动服务+echo+echo -e "${BLUE}[3/3] Starting services...${NC}"+echo -e "${GREEN} • Collector will run on http://localhost:3001${NC}"+echo -e "${GREEN} • Web UI will run on http://localhost:3000${NC}"+echo+echo -e "${YELLOW}Press Ctrl+C to stop all services${NC}"+echo++# 使用 turborepo 启动所有服务+pnpm devdiff --git a/turbo.json b/turbo.jsonnew file mode 100644index 0000000..5581572--- /dev/null+++ b/turbo.json@@ -0,0 +1,17 @@+{+ "$schema": "https://turbo.build/schema.json",+ "globalDependencies": ["**/.env.*local"],+ "tasks": {+ "build": {+ "dependsOn": ["^build"],+ "outputs": [".next/**", "!.next/cache/**", "dist/**"]+ },+ "dev": {+ "cache": false,+ "persistent": true+ },+ "lint": {+ "dependsOn": ["^lint"]+ }+ }+}