- Added IDs to input fields in CrowdSecConfig for better accessibility. - Updated labels to use <label> elements for checkboxes and inputs. - Improved error handling and user feedback in the CrowdSecConfig tests. - Enhanced test coverage for console enrollment and banned IP functionalities. fix: Update SecurityHeaders to include aria-label for delete button - Added aria-label to the delete button for better screen reader support. test: Add comprehensive tests for proxyHostsHelpers and validation utilities - Implemented tests for formatting and help text functions in proxyHostsHelpers. - Added validation tests for email and IP address formats. chore: Update vitest configuration for dynamic coverage thresholds - Adjusted coverage thresholds to be dynamic based on environment variables. - Included additional coverage reporters. chore: Update frontend-test-coverage script to reflect new coverage threshold - Increased minimum coverage requirement from 85% to 87.5%. fix: Ensure tests pass with consistent data in passwd file - Updated tests/etc/passwd to ensure consistent content.
82 lines
3.1 KiB
JSON
82 lines
3.1 KiB
JSON
{
|
|
"name": "charon-frontend",
|
|
"private": true,
|
|
"version": "0.3.0",
|
|
"type": "module",
|
|
"tools": [],
|
|
"constraints": [
|
|
"NPM SCRIPTS ONLY: Do not try to construct complex `vitest` or `playwright` commands. Always look at `package.json` first and use `npm run <script-name>`."
|
|
],
|
|
"scripts": {
|
|
"dev": "vite",
|
|
"build": "tsc -p tsconfig.build.json && vite build",
|
|
"pretype-check": "npm ci --silent",
|
|
"type-check": "tsc --noEmit",
|
|
"lint": "eslint . --report-unused-disable-directives",
|
|
"preview": "vite preview",
|
|
"test": "vitest run",
|
|
"test:ci": "vitest run",
|
|
"test:ui": "vitest --ui",
|
|
"check-coverage": "bash ../scripts/frontend-test-coverage.sh",
|
|
"pretest:coverage": "npm ci --silent && node -e \"require('fs').mkdirSync('coverage/.tmp', { recursive: true })\"",
|
|
"test:coverage": "vitest run --coverage",
|
|
"e2e:install": "npx playwright install --with-deps",
|
|
"e2e:test": "playwright test",
|
|
"e2e:up:block": "docker compose -f ../.docker/compose/docker-compose.local.yml down && CHARON_SECURITY_WAF_MODE=block docker compose -f ../.docker/compose/docker-compose.local.yml up -d",
|
|
"e2e:up:monitor": "docker compose -f ../.docker/compose/docker-compose.local.yml down && CHARON_SECURITY_WAF_MODE=monitor docker compose -f ../.docker/compose/docker-compose.local.yml up -d",
|
|
"e2e:down": "docker compose -f ../.docker/compose/docker-compose.local.yml down"
|
|
},
|
|
"dependencies": {
|
|
"@radix-ui/react-checkbox": "^1.3.3",
|
|
"@radix-ui/react-dialog": "^1.1.15",
|
|
"@radix-ui/react-progress": "^1.1.8",
|
|
"@radix-ui/react-select": "^2.2.6",
|
|
"@radix-ui/react-tabs": "^1.1.13",
|
|
"@radix-ui/react-tooltip": "^1.2.8",
|
|
"@tanstack/react-query": "^5.90.20",
|
|
"axios": "^1.13.4",
|
|
"class-variance-authority": "^0.7.1",
|
|
"clsx": "^2.1.1",
|
|
"date-fns": "^4.1.0",
|
|
"i18next": "^25.8.4",
|
|
"i18next-browser-languagedetector": "^8.2.0",
|
|
"lucide-react": "^0.563.0",
|
|
"react": "^19.2.4",
|
|
"react-dom": "^19.2.4",
|
|
"react-hook-form": "^7.71.1",
|
|
"react-hot-toast": "^2.6.0",
|
|
"react-i18next": "^16.5.4",
|
|
"react-router-dom": "^7.13.0",
|
|
"tailwind-merge": "^3.4.0",
|
|
"tldts": "^7.0.22"
|
|
},
|
|
"devDependencies": {
|
|
"@playwright/test": "^1.58.2",
|
|
"@tailwindcss/postcss": "^4.1.18",
|
|
"@testing-library/jest-dom": "^6.9.1",
|
|
"@testing-library/react": "^16.3.2",
|
|
"@testing-library/user-event": "^14.6.1",
|
|
"@types/node": "^25.2.1",
|
|
"@types/react": "^19.2.13",
|
|
"@types/react-dom": "^19.2.3",
|
|
"@typescript-eslint/eslint-plugin": "^8.54.0",
|
|
"@typescript-eslint/parser": "^8.54.0",
|
|
"@vitejs/plugin-react": "^5.1.3",
|
|
"@vitest/coverage-istanbul": "^4.0.18",
|
|
"@vitest/coverage-v8": "^4.0.18",
|
|
"@vitest/ui": "^4.0.18",
|
|
"autoprefixer": "^10.4.24",
|
|
"eslint": "^9.39.2",
|
|
"eslint-plugin-react-hooks": "^7.0.1",
|
|
"eslint-plugin-react-refresh": "^0.5.0",
|
|
"jsdom": "25.0.1",
|
|
"knip": "^5.83.0",
|
|
"postcss": "^8.5.6",
|
|
"tailwindcss": "^4.1.18",
|
|
"typescript": "^5.9.3",
|
|
"typescript-eslint": "^8.54.0",
|
|
"vite": "^7.3.1",
|
|
"vitest": "^4.0.18"
|
|
}
|
|
}
|