agentic-qe 3.6.8 → 3.6.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude/skills/README.md +1 -1
- package/.claude/skills/skills-manifest.json +1 -1
- package/package.json +3 -2
- package/v3/CHANGELOG.md +20 -0
- package/v3/dist/adapters/a2a/agent-cards/generator.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/agent-cards/generator.js +2 -1
- package/v3/dist/adapters/a2a/agent-cards/generator.js.map +1 -1
- package/v3/dist/adapters/a2a/auth/jwt-utils.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/auth/jwt-utils.js +3 -2
- package/v3/dist/adapters/a2a/auth/jwt-utils.js.map +1 -1
- package/v3/dist/adapters/a2a/auth/middleware.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/auth/middleware.js +3 -0
- package/v3/dist/adapters/a2a/auth/middleware.js.map +1 -1
- package/v3/dist/adapters/a2a/discovery/agent-health.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/discovery/agent-health.js +4 -3
- package/v3/dist/adapters/a2a/discovery/agent-health.js.map +1 -1
- package/v3/dist/adapters/a2a/discovery/file-watcher.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/discovery/file-watcher.js +3 -2
- package/v3/dist/adapters/a2a/discovery/file-watcher.js.map +1 -1
- package/v3/dist/adapters/a2a/discovery/hot-reload-service.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/discovery/hot-reload-service.js +6 -5
- package/v3/dist/adapters/a2a/discovery/hot-reload-service.js.map +1 -1
- package/v3/dist/adapters/a2a/jsonrpc/envelope.d.ts.map +1 -1
- package/v3/dist/adapters/a2a/jsonrpc/envelope.js +5 -4
- package/v3/dist/adapters/a2a/jsonrpc/envelope.js.map +1 -1
- package/v3/dist/adapters/ag-ui/event-adapter.d.ts.map +1 -1
- package/v3/dist/adapters/ag-ui/event-adapter.js +2 -1
- package/v3/dist/adapters/ag-ui/event-adapter.js.map +1 -1
- package/v3/dist/adapters/ag-ui/event-batcher.d.ts.map +1 -1
- package/v3/dist/adapters/ag-ui/event-batcher.js +2 -1
- package/v3/dist/adapters/ag-ui/event-batcher.js.map +1 -1
- package/v3/dist/adapters/ag-ui/json-patch-utils.d.ts.map +1 -1
- package/v3/dist/adapters/ag-ui/json-patch-utils.js +2 -1
- package/v3/dist/adapters/ag-ui/json-patch-utils.js.map +1 -1
- package/v3/dist/adapters/ag-ui/json-patch.d.ts +1 -1
- package/v3/dist/adapters/ag-ui/json-patch.d.ts.map +1 -1
- package/v3/dist/adapters/ag-ui/json-patch.js +4 -6
- package/v3/dist/adapters/ag-ui/json-patch.js.map +1 -1
- package/v3/dist/adapters/ag-ui/stream-controller.d.ts.map +1 -1
- package/v3/dist/adapters/ag-ui/stream-controller.js +3 -0
- package/v3/dist/adapters/ag-ui/stream-controller.js.map +1 -1
- package/v3/dist/adapters/claude-flow/detect.d.ts.map +1 -1
- package/v3/dist/adapters/claude-flow/detect.js +4 -3
- package/v3/dist/adapters/claude-flow/detect.js.map +1 -1
- package/v3/dist/adapters/claude-flow/pretrain-bridge.d.ts.map +1 -1
- package/v3/dist/adapters/claude-flow/pretrain-bridge.js +7 -5
- package/v3/dist/adapters/claude-flow/pretrain-bridge.js.map +1 -1
- package/v3/dist/adapters/claude-flow/trajectory-bridge.d.ts.map +1 -1
- package/v3/dist/adapters/claude-flow/trajectory-bridge.js +2 -14
- package/v3/dist/adapters/claude-flow/trajectory-bridge.js.map +1 -1
- package/v3/dist/adapters/trajectory-adapter.d.ts.map +1 -1
- package/v3/dist/adapters/trajectory-adapter.js +5 -3
- package/v3/dist/adapters/trajectory-adapter.js.map +1 -1
- package/v3/dist/agents/claim-verifier/verifiers/test-verifier.d.ts.map +1 -1
- package/v3/dist/agents/claim-verifier/verifiers/test-verifier.js +2 -1
- package/v3/dist/agents/claim-verifier/verifiers/test-verifier.js.map +1 -1
- package/v3/dist/benchmarks/performance-benchmarks.d.ts.map +1 -1
- package/v3/dist/benchmarks/performance-benchmarks.js +4 -3
- package/v3/dist/benchmarks/performance-benchmarks.js.map +1 -1
- package/v3/dist/benchmarks/run-benchmarks.js +27 -45
- package/v3/dist/benchmarks/run-benchmarks.js.map +1 -1
- package/v3/dist/cli/bundle.js +13182 -14562
- package/v3/dist/cli/commands/claude-flow-setup.d.ts.map +1 -1
- package/v3/dist/cli/commands/claude-flow-setup.js +7 -5
- package/v3/dist/cli/commands/claude-flow-setup.js.map +1 -1
- package/v3/dist/cli/commands/hooks.d.ts.map +1 -1
- package/v3/dist/cli/commands/hooks.js +2 -1
- package/v3/dist/cli/commands/hooks.js.map +1 -1
- package/v3/dist/cli/commands/init.d.ts.map +1 -1
- package/v3/dist/cli/commands/init.js +2 -1
- package/v3/dist/cli/commands/init.js.map +1 -1
- package/v3/dist/cli/commands/learning-helpers.d.ts +101 -0
- package/v3/dist/cli/commands/learning-helpers.d.ts.map +1 -0
- package/v3/dist/cli/commands/learning-helpers.js +294 -0
- package/v3/dist/cli/commands/learning-helpers.js.map +1 -0
- package/v3/dist/cli/commands/learning.d.ts +1 -6
- package/v3/dist/cli/commands/learning.d.ts.map +1 -1
- package/v3/dist/cli/commands/learning.js +230 -839
- package/v3/dist/cli/commands/learning.js.map +1 -1
- package/v3/dist/cli/commands/qe-tools.d.ts.map +1 -1
- package/v3/dist/cli/commands/qe-tools.js +2 -1
- package/v3/dist/cli/commands/qe-tools.js.map +1 -1
- package/v3/dist/cli/commands/sync.d.ts.map +1 -1
- package/v3/dist/cli/commands/sync.js +5 -4
- package/v3/dist/cli/commands/sync.js.map +1 -1
- package/v3/dist/cli/commands/token-usage.d.ts.map +1 -1
- package/v3/dist/cli/commands/token-usage.js +2 -1
- package/v3/dist/cli/commands/token-usage.js.map +1 -1
- package/v3/dist/cli/commands/validate.d.ts.map +1 -1
- package/v3/dist/cli/commands/validate.js +3 -2
- package/v3/dist/cli/commands/validate.js.map +1 -1
- package/v3/dist/cli/config/cli-config.d.ts.map +1 -1
- package/v3/dist/cli/config/cli-config.js +2 -1
- package/v3/dist/cli/config/cli-config.js.map +1 -1
- package/v3/dist/cli/handlers/init-handler.d.ts.map +1 -1
- package/v3/dist/cli/handlers/init-handler.js +3 -2
- package/v3/dist/cli/handlers/init-handler.js.map +1 -1
- package/v3/dist/cli/helpers/safe-json.d.ts +4 -48
- package/v3/dist/cli/helpers/safe-json.d.ts.map +1 -1
- package/v3/dist/cli/helpers/safe-json.js +4 -68
- package/v3/dist/cli/helpers/safe-json.js.map +1 -1
- package/v3/dist/cli/index.js +3 -2
- package/v3/dist/cli/index.js.map +1 -1
- package/v3/dist/cli/scheduler/persistent-scheduler.d.ts.map +1 -1
- package/v3/dist/cli/scheduler/persistent-scheduler.js +4 -2
- package/v3/dist/cli/scheduler/persistent-scheduler.js.map +1 -1
- package/v3/dist/cli/wizards/test-wizard.d.ts.map +1 -1
- package/v3/dist/cli/wizards/test-wizard.js +2 -1
- package/v3/dist/cli/wizards/test-wizard.js.map +1 -1
- package/v3/dist/coordination/agent-teams/tracing.d.ts.map +1 -1
- package/v3/dist/coordination/agent-teams/tracing.js +2 -1
- package/v3/dist/coordination/agent-teams/tracing.js.map +1 -1
- package/v3/dist/coordination/circuit-breaker/breaker-registry.d.ts.map +1 -1
- package/v3/dist/coordination/circuit-breaker/breaker-registry.js +3 -2
- package/v3/dist/coordination/circuit-breaker/breaker-registry.js.map +1 -1
- package/v3/dist/coordination/circuit-breaker/domain-circuit-breaker.d.ts.map +1 -1
- package/v3/dist/coordination/circuit-breaker/domain-circuit-breaker.js +3 -2
- package/v3/dist/coordination/circuit-breaker/domain-circuit-breaker.js.map +1 -1
- package/v3/dist/coordination/consensus/consensus-engine.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/consensus-engine.js +7 -6
- package/v3/dist/coordination/consensus/consensus-engine.js.map +1 -1
- package/v3/dist/coordination/consensus/model-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/model-provider.js +2 -1
- package/v3/dist/coordination/consensus/model-provider.js.map +1 -1
- package/v3/dist/coordination/consensus/providers/claude-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/providers/claude-provider.js +13 -12
- package/v3/dist/coordination/consensus/providers/claude-provider.js.map +1 -1
- package/v3/dist/coordination/consensus/providers/gemini-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/providers/gemini-provider.js +13 -12
- package/v3/dist/coordination/consensus/providers/gemini-provider.js.map +1 -1
- package/v3/dist/coordination/consensus/providers/native-learning-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/providers/native-learning-provider.js +3 -2
- package/v3/dist/coordination/consensus/providers/native-learning-provider.js.map +1 -1
- package/v3/dist/coordination/consensus/providers/ollama-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/providers/ollama-provider.js +3 -2
- package/v3/dist/coordination/consensus/providers/ollama-provider.js.map +1 -1
- package/v3/dist/coordination/consensus/providers/openai-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/providers/openai-provider.js +3 -2
- package/v3/dist/coordination/consensus/providers/openai-provider.js.map +1 -1
- package/v3/dist/coordination/consensus/providers/openrouter-provider.d.ts.map +1 -1
- package/v3/dist/coordination/consensus/providers/openrouter-provider.js +3 -2
- package/v3/dist/coordination/consensus/providers/openrouter-provider.js.map +1 -1
- package/v3/dist/coordination/dynamic-scaling/dynamic-scaler.d.ts.map +1 -1
- package/v3/dist/coordination/dynamic-scaling/dynamic-scaler.js +5 -4
- package/v3/dist/coordination/dynamic-scaling/dynamic-scaler.js.map +1 -1
- package/v3/dist/coordination/mincut/dream-integration.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/dream-integration.js.map +1 -1
- package/v3/dist/coordination/mincut/mincut-health-monitor.d.ts +4 -2
- package/v3/dist/coordination/mincut/mincut-health-monitor.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/mincut-health-monitor.js +13 -3
- package/v3/dist/coordination/mincut/mincut-health-monitor.js.map +1 -1
- package/v3/dist/coordination/mincut/mincut-persistence.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/mincut-persistence.js +5 -4
- package/v3/dist/coordination/mincut/mincut-persistence.js.map +1 -1
- package/v3/dist/coordination/mincut/neural-goap.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/neural-goap.js +2 -1
- package/v3/dist/coordination/mincut/neural-goap.js.map +1 -1
- package/v3/dist/coordination/mincut/strange-loop.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/strange-loop.js +10 -2
- package/v3/dist/coordination/mincut/strange-loop.js.map +1 -1
- package/v3/dist/coordination/mincut/time-crystal.d.ts.map +1 -1
- package/v3/dist/coordination/mincut/time-crystal.js +2 -1
- package/v3/dist/coordination/mincut/time-crystal.js.map +1 -1
- package/v3/dist/coordination/mixins/consensus-enabled-domain.d.ts +19 -3
- package/v3/dist/coordination/mixins/consensus-enabled-domain.d.ts.map +1 -1
- package/v3/dist/coordination/mixins/consensus-enabled-domain.js +6 -2
- package/v3/dist/coordination/mixins/consensus-enabled-domain.js.map +1 -1
- package/v3/dist/coordination/plugin.d.ts +1 -1
- package/v3/dist/coordination/plugin.d.ts.map +1 -1
- package/v3/dist/coordination/plugin.js +1 -1
- package/v3/dist/coordination/plugin.js.map +1 -1
- package/v3/dist/coordination/protocol-executor.d.ts.map +1 -1
- package/v3/dist/coordination/protocol-executor.js +4 -3
- package/v3/dist/coordination/protocol-executor.js.map +1 -1
- package/v3/dist/coordination/protocols/code-intelligence-index.d.ts +1 -1
- package/v3/dist/coordination/protocols/code-intelligence-index.d.ts.map +1 -1
- package/v3/dist/coordination/protocols/code-intelligence-index.js +22 -10
- package/v3/dist/coordination/protocols/code-intelligence-index.js.map +1 -1
- package/v3/dist/coordination/protocols/defect-investigation.d.ts +2 -2
- package/v3/dist/coordination/protocols/defect-investigation.d.ts.map +1 -1
- package/v3/dist/coordination/protocols/defect-investigation.js +16 -7
- package/v3/dist/coordination/protocols/defect-investigation.js.map +1 -1
- package/v3/dist/coordination/protocols/learning-consolidation.d.ts +1 -1
- package/v3/dist/coordination/protocols/learning-consolidation.d.ts.map +1 -1
- package/v3/dist/coordination/protocols/learning-consolidation.js +6 -5
- package/v3/dist/coordination/protocols/learning-consolidation.js.map +1 -1
- package/v3/dist/coordination/protocols/morning-sync.d.ts.map +1 -1
- package/v3/dist/coordination/protocols/morning-sync.js +2 -1
- package/v3/dist/coordination/protocols/morning-sync.js.map +1 -1
- package/v3/dist/coordination/protocols/quality-gate.d.ts.map +1 -1
- package/v3/dist/coordination/protocols/quality-gate.js +6 -5
- package/v3/dist/coordination/protocols/quality-gate.js.map +1 -1
- package/v3/dist/coordination/protocols/security-audit.d.ts +1 -1
- package/v3/dist/coordination/protocols/security-audit.d.ts.map +1 -1
- package/v3/dist/coordination/protocols/security-audit.js +35 -13
- package/v3/dist/coordination/protocols/security-audit.js.map +1 -1
- package/v3/dist/coordination/queen-coordinator.d.ts +26 -257
- package/v3/dist/coordination/queen-coordinator.d.ts.map +1 -1
- package/v3/dist/coordination/queen-coordinator.js +282 -1175
- package/v3/dist/coordination/queen-coordinator.js.map +1 -1
- package/v3/dist/coordination/queen-event-handlers.d.ts +61 -0
- package/v3/dist/coordination/queen-event-handlers.d.ts.map +1 -0
- package/v3/dist/coordination/queen-event-handlers.js +311 -0
- package/v3/dist/coordination/queen-event-handlers.js.map +1 -0
- package/v3/dist/coordination/queen-lifecycle.d.ts +61 -0
- package/v3/dist/coordination/queen-lifecycle.d.ts.map +1 -0
- package/v3/dist/coordination/queen-lifecycle.js +162 -0
- package/v3/dist/coordination/queen-lifecycle.js.map +1 -0
- package/v3/dist/coordination/queen-task-management.d.ts +84 -0
- package/v3/dist/coordination/queen-task-management.d.ts.map +1 -0
- package/v3/dist/coordination/queen-task-management.js +333 -0
- package/v3/dist/coordination/queen-task-management.js.map +1 -0
- package/v3/dist/coordination/queen-types.d.ts +175 -0
- package/v3/dist/coordination/queen-types.d.ts.map +1 -0
- package/v3/dist/coordination/queen-types.js +80 -0
- package/v3/dist/coordination/queen-types.js.map +1 -0
- package/v3/dist/coordination/queen-work-stealing.d.ts +33 -0
- package/v3/dist/coordination/queen-work-stealing.d.ts.map +1 -0
- package/v3/dist/coordination/queen-work-stealing.js +78 -0
- package/v3/dist/coordination/queen-work-stealing.js.map +1 -0
- package/v3/dist/coordination/result-saver.d.ts.map +1 -1
- package/v3/dist/coordination/result-saver.js +2 -1
- package/v3/dist/coordination/result-saver.js.map +1 -1
- package/v3/dist/coordination/task-executor.d.ts +45 -2
- package/v3/dist/coordination/task-executor.d.ts.map +1 -1
- package/v3/dist/coordination/task-executor.js +643 -570
- package/v3/dist/coordination/task-executor.js.map +1 -1
- package/v3/dist/coordination/workflow-builtin.d.ts +17 -0
- package/v3/dist/coordination/workflow-builtin.d.ts.map +1 -0
- package/v3/dist/coordination/workflow-builtin.js +648 -0
- package/v3/dist/coordination/workflow-builtin.js.map +1 -0
- package/v3/dist/coordination/workflow-orchestrator.d.ts +13 -300
- package/v3/dist/coordination/workflow-orchestrator.d.ts.map +1 -1
- package/v3/dist/coordination/workflow-orchestrator.js +142 -1009
- package/v3/dist/coordination/workflow-orchestrator.js.map +1 -1
- package/v3/dist/coordination/workflow-types.d.ts +250 -0
- package/v3/dist/coordination/workflow-types.d.ts.map +1 -0
- package/v3/dist/coordination/workflow-types.js +27 -0
- package/v3/dist/coordination/workflow-types.js.map +1 -0
- package/v3/dist/domains/base-domain-coordinator.d.ts +119 -0
- package/v3/dist/domains/base-domain-coordinator.d.ts.map +1 -0
- package/v3/dist/domains/base-domain-coordinator.js +200 -0
- package/v3/dist/domains/base-domain-coordinator.js.map +1 -0
- package/v3/dist/domains/chaos-resilience/coordinator.d.ts +12 -70
- package/v3/dist/domains/chaos-resilience/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/chaos-resilience/coordinator.js +25 -181
- package/v3/dist/domains/chaos-resilience/coordinator.js.map +1 -1
- package/v3/dist/domains/chaos-resilience/plugin.d.ts.map +1 -1
- package/v3/dist/domains/chaos-resilience/plugin.js +2 -1
- package/v3/dist/domains/chaos-resilience/plugin.js.map +1 -1
- package/v3/dist/domains/chaos-resilience/services/chaos-engineer.d.ts.map +1 -1
- package/v3/dist/domains/chaos-resilience/services/chaos-engineer.js +15 -13
- package/v3/dist/domains/chaos-resilience/services/chaos-engineer.js.map +1 -1
- package/v3/dist/domains/chaos-resilience/services/load-tester.d.ts.map +1 -1
- package/v3/dist/domains/chaos-resilience/services/load-tester.js +8 -7
- package/v3/dist/domains/chaos-resilience/services/load-tester.js.map +1 -1
- package/v3/dist/domains/chaos-resilience/services/performance-profiler.d.ts.map +1 -1
- package/v3/dist/domains/chaos-resilience/services/performance-profiler.js +7 -5
- package/v3/dist/domains/chaos-resilience/services/performance-profiler.js.map +1 -1
- package/v3/dist/domains/code-intelligence/coordinator-consensus.d.ts +33 -0
- package/v3/dist/domains/code-intelligence/coordinator-consensus.d.ts.map +1 -0
- package/v3/dist/domains/code-intelligence/coordinator-consensus.js +81 -0
- package/v3/dist/domains/code-intelligence/coordinator-consensus.js.map +1 -0
- package/v3/dist/domains/code-intelligence/coordinator-gnn.d.ts +44 -0
- package/v3/dist/domains/code-intelligence/coordinator-gnn.d.ts.map +1 -0
- package/v3/dist/domains/code-intelligence/coordinator-gnn.js +183 -0
- package/v3/dist/domains/code-intelligence/coordinator-gnn.js.map +1 -0
- package/v3/dist/domains/code-intelligence/coordinator-hypergraph.d.ts +40 -0
- package/v3/dist/domains/code-intelligence/coordinator-hypergraph.d.ts.map +1 -0
- package/v3/dist/domains/code-intelligence/coordinator-hypergraph.js +191 -0
- package/v3/dist/domains/code-intelligence/coordinator-hypergraph.js.map +1 -0
- package/v3/dist/domains/code-intelligence/coordinator.d.ts +17 -93
- package/v3/dist/domains/code-intelligence/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/coordinator.js +46 -565
- package/v3/dist/domains/code-intelligence/coordinator.js.map +1 -1
- package/v3/dist/domains/code-intelligence/index.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/index.js +10 -0
- package/v3/dist/domains/code-intelligence/index.js.map +1 -1
- package/v3/dist/domains/code-intelligence/plugin.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/plugin.js +2 -1
- package/v3/dist/domains/code-intelligence/plugin.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/c4-model/index.d.ts +3 -3
- package/v3/dist/domains/code-intelligence/services/c4-model/index.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/c4-model/index.js +2 -2
- package/v3/dist/domains/code-intelligence/services/c4-model/index.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/c4-model/types.d.ts +1 -1
- package/v3/dist/domains/code-intelligence/services/c4-model/types.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/impact-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/impact-analyzer.js +3 -2
- package/v3/dist/domains/code-intelligence/services/impact-analyzer.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/knowledge-graph.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/knowledge-graph.js +8 -6
- package/v3/dist/domains/code-intelligence/services/knowledge-graph.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/metric-collector/loc-counter.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/metric-collector/loc-counter.js +3 -2
- package/v3/dist/domains/code-intelligence/services/metric-collector/loc-counter.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/metric-collector/test-counter.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/metric-collector/test-counter.js +3 -2
- package/v3/dist/domains/code-intelligence/services/metric-collector/test-counter.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/product-factors-bridge.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/product-factors-bridge.js +8 -6
- package/v3/dist/domains/code-intelligence/services/product-factors-bridge.js.map +1 -1
- package/v3/dist/domains/code-intelligence/services/semantic-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/code-intelligence/services/semantic-analyzer.js +5 -4
- package/v3/dist/domains/code-intelligence/services/semantic-analyzer.js.map +1 -1
- package/v3/dist/domains/contract-testing/coordinator.d.ts +13 -89
- package/v3/dist/domains/contract-testing/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/contract-testing/coordinator.js +43 -215
- package/v3/dist/domains/contract-testing/coordinator.js.map +1 -1
- package/v3/dist/domains/contract-testing/plugin.d.ts.map +1 -1
- package/v3/dist/domains/contract-testing/plugin.js +5 -4
- package/v3/dist/domains/contract-testing/plugin.js.map +1 -1
- package/v3/dist/domains/contract-testing/services/api-compatibility.d.ts.map +1 -1
- package/v3/dist/domains/contract-testing/services/api-compatibility.js +7 -5
- package/v3/dist/domains/contract-testing/services/api-compatibility.js.map +1 -1
- package/v3/dist/domains/contract-testing/services/contract-validator.d.ts.map +1 -1
- package/v3/dist/domains/contract-testing/services/contract-validator.js +10 -8
- package/v3/dist/domains/contract-testing/services/contract-validator.js.map +1 -1
- package/v3/dist/domains/contract-testing/services/schema-validator.d.ts.map +1 -1
- package/v3/dist/domains/contract-testing/services/schema-validator.js +10 -8
- package/v3/dist/domains/contract-testing/services/schema-validator.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/coordinator.d.ts +8 -59
- package/v3/dist/domains/coverage-analysis/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/coordinator.js +30 -138
- package/v3/dist/domains/coverage-analysis/coordinator.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/index.js +7 -0
- package/v3/dist/domains/coverage-analysis/index.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/coverage-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/coverage-analyzer.js +5 -3
- package/v3/dist/domains/coverage-analysis/services/coverage-analyzer.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/coverage-parser.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/coverage-parser.js +2 -1
- package/v3/dist/domains/coverage-analysis/services/coverage-parser.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/gap-detector.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/gap-detector.js +6 -4
- package/v3/dist/domains/coverage-analysis/services/gap-detector.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/ghost-coverage-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/ghost-coverage-analyzer.js +5 -4
- package/v3/dist/domains/coverage-analysis/services/ghost-coverage-analyzer.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/risk-scorer.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/risk-scorer.js +3 -2
- package/v3/dist/domains/coverage-analysis/services/risk-scorer.js.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/sublinear-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/coverage-analysis/services/sublinear-analyzer.js +4 -3
- package/v3/dist/domains/coverage-analysis/services/sublinear-analyzer.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/coordinator.d.ts +10 -58
- package/v3/dist/domains/defect-intelligence/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/defect-intelligence/coordinator.js +50 -171
- package/v3/dist/domains/defect-intelligence/coordinator.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/plugin.d.ts.map +1 -1
- package/v3/dist/domains/defect-intelligence/plugin.js +2 -1
- package/v3/dist/domains/defect-intelligence/plugin.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/causal-root-cause-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/causal-root-cause-analyzer.js +4 -3
- package/v3/dist/domains/defect-intelligence/services/causal-root-cause-analyzer.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/defect-predictor.d.ts.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/defect-predictor.js +6 -4
- package/v3/dist/domains/defect-intelligence/services/defect-predictor.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/pattern-learner.d.ts.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/pattern-learner.js +4 -3
- package/v3/dist/domains/defect-intelligence/services/pattern-learner.js.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/root-cause-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/defect-intelligence/services/root-cause-analyzer.js +6 -4
- package/v3/dist/domains/defect-intelligence/services/root-cause-analyzer.js.map +1 -1
- package/v3/dist/domains/domain-interface.d.ts +6 -219
- package/v3/dist/domains/domain-interface.d.ts.map +1 -1
- package/v3/dist/domains/domain-interface.js +6 -312
- package/v3/dist/domains/domain-interface.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/coordinator.d.ts +11 -37
- package/v3/dist/domains/enterprise-integration/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/coordinator.js +39 -148
- package/v3/dist/domains/enterprise-integration/coordinator.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/plugin.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/plugin.js +2 -1
- package/v3/dist/domains/enterprise-integration/plugin.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/esb-middleware-service.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/esb-middleware-service.js +7 -5
- package/v3/dist/domains/enterprise-integration/services/esb-middleware-service.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/message-broker-service.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/message-broker-service.js +11 -9
- package/v3/dist/domains/enterprise-integration/services/message-broker-service.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/odata-service.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/odata-service.js +4 -3
- package/v3/dist/domains/enterprise-integration/services/odata-service.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/sap-integration-service.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/sap-integration-service.js +5 -3
- package/v3/dist/domains/enterprise-integration/services/sap-integration-service.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/soap-wsdl-service.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/soap-wsdl-service.js +4 -3
- package/v3/dist/domains/enterprise-integration/services/soap-wsdl-service.js.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/sod-analysis-service.d.ts.map +1 -1
- package/v3/dist/domains/enterprise-integration/services/sod-analysis-service.js +3 -2
- package/v3/dist/domains/enterprise-integration/services/sod-analysis-service.js.map +1 -1
- package/v3/dist/domains/learning-optimization/coordinator-consensus.d.ts +37 -0
- package/v3/dist/domains/learning-optimization/coordinator-consensus.d.ts.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-consensus.js +82 -0
- package/v3/dist/domains/learning-optimization/coordinator-consensus.js.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-dream.d.ts +32 -0
- package/v3/dist/domains/learning-optimization/coordinator-dream.d.ts.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-dream.js +43 -0
- package/v3/dist/domains/learning-optimization/coordinator-dream.js.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-helpers.d.ts +56 -0
- package/v3/dist/domains/learning-optimization/coordinator-helpers.d.ts.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-helpers.js +142 -0
- package/v3/dist/domains/learning-optimization/coordinator-helpers.js.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-sona-methods.d.ts +64 -0
- package/v3/dist/domains/learning-optimization/coordinator-sona-methods.d.ts.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator-sona-methods.js +73 -0
- package/v3/dist/domains/learning-optimization/coordinator-sona-methods.js.map +1 -0
- package/v3/dist/domains/learning-optimization/coordinator.d.ts +17 -82
- package/v3/dist/domains/learning-optimization/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/learning-optimization/coordinator.js +36 -320
- package/v3/dist/domains/learning-optimization/coordinator.js.map +1 -1
- package/v3/dist/domains/learning-optimization/plugin.d.ts.map +1 -1
- package/v3/dist/domains/learning-optimization/plugin.js +2 -1
- package/v3/dist/domains/learning-optimization/plugin.js.map +1 -1
- package/v3/dist/domains/learning-optimization/services/learning-coordinator.d.ts.map +1 -1
- package/v3/dist/domains/learning-optimization/services/learning-coordinator.js +11 -10
- package/v3/dist/domains/learning-optimization/services/learning-coordinator.js.map +1 -1
- package/v3/dist/domains/learning-optimization/services/metrics-optimizer.d.ts.map +1 -1
- package/v3/dist/domains/learning-optimization/services/metrics-optimizer.js +8 -7
- package/v3/dist/domains/learning-optimization/services/metrics-optimizer.js.map +1 -1
- package/v3/dist/domains/learning-optimization/services/production-intel.d.ts.map +1 -1
- package/v3/dist/domains/learning-optimization/services/production-intel.js +11 -10
- package/v3/dist/domains/learning-optimization/services/production-intel.js.map +1 -1
- package/v3/dist/domains/learning-optimization/services/transfer-specialist.d.ts.map +1 -1
- package/v3/dist/domains/learning-optimization/services/transfer-specialist.js +8 -7
- package/v3/dist/domains/learning-optimization/services/transfer-specialist.js.map +1 -1
- package/v3/dist/domains/quality-assessment/coordinator-claim-verifier.d.ts +41 -0
- package/v3/dist/domains/quality-assessment/coordinator-claim-verifier.d.ts.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-claim-verifier.js +157 -0
- package/v3/dist/domains/quality-assessment/coordinator-claim-verifier.js.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-gate-evaluation.d.ts +26 -0
- package/v3/dist/domains/quality-assessment/coordinator-gate-evaluation.d.ts.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-gate-evaluation.js +135 -0
- package/v3/dist/domains/quality-assessment/coordinator-gate-evaluation.js.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-reports.d.ts +90 -0
- package/v3/dist/domains/quality-assessment/coordinator-reports.d.ts.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-reports.js +265 -0
- package/v3/dist/domains/quality-assessment/coordinator-reports.js.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-rl-integration.d.ts +92 -0
- package/v3/dist/domains/quality-assessment/coordinator-rl-integration.d.ts.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator-rl-integration.js +321 -0
- package/v3/dist/domains/quality-assessment/coordinator-rl-integration.js.map +1 -0
- package/v3/dist/domains/quality-assessment/coordinator.d.ts +18 -127
- package/v3/dist/domains/quality-assessment/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/coordinator.js +58 -1022
- package/v3/dist/domains/quality-assessment/coordinator.js.map +1 -1
- package/v3/dist/domains/quality-assessment/index.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/index.js +10 -0
- package/v3/dist/domains/quality-assessment/index.js.map +1 -1
- package/v3/dist/domains/quality-assessment/plugin.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/plugin.js +2 -1
- package/v3/dist/domains/quality-assessment/plugin.js.map +1 -1
- package/v3/dist/domains/quality-assessment/services/coherence-gate.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/services/coherence-gate.js +2 -1
- package/v3/dist/domains/quality-assessment/services/coherence-gate.js.map +1 -1
- package/v3/dist/domains/quality-assessment/services/deployment-advisor.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/services/deployment-advisor.js +5 -3
- package/v3/dist/domains/quality-assessment/services/deployment-advisor.js.map +1 -1
- package/v3/dist/domains/quality-assessment/services/quality-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/services/quality-analyzer.js +6 -4
- package/v3/dist/domains/quality-assessment/services/quality-analyzer.js.map +1 -1
- package/v3/dist/domains/quality-assessment/services/quality-gate.d.ts.map +1 -1
- package/v3/dist/domains/quality-assessment/services/quality-gate.js +3 -2
- package/v3/dist/domains/quality-assessment/services/quality-gate.js.map +1 -1
- package/v3/dist/domains/requirements-validation/coordinator.d.ts +17 -61
- package/v3/dist/domains/requirements-validation/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/coordinator.js +25 -175
- package/v3/dist/domains/requirements-validation/coordinator.js.map +1 -1
- package/v3/dist/domains/requirements-validation/plugin.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/plugin.js +2 -1
- package/v3/dist/domains/requirements-validation/plugin.js.map +1 -1
- package/v3/dist/domains/requirements-validation/qcsd-ideation-plugin.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/qcsd-ideation-plugin.js +12 -11
- package/v3/dist/domains/requirements-validation/qcsd-ideation-plugin.js.map +1 -1
- package/v3/dist/domains/requirements-validation/qcsd-refinement-plugin.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/qcsd-refinement-plugin.js +11 -10
- package/v3/dist/domains/requirements-validation/qcsd-refinement-plugin.js.map +1 -1
- package/v3/dist/domains/requirements-validation/services/bdd-scenario-writer.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/services/bdd-scenario-writer.js +4 -3
- package/v3/dist/domains/requirements-validation/services/bdd-scenario-writer.js.map +1 -1
- package/v3/dist/domains/requirements-validation/services/product-factors-assessment/code-intelligence/codebase-analyzer.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/services/product-factors-assessment/code-intelligence/codebase-analyzer.js +3 -2
- package/v3/dist/domains/requirements-validation/services/product-factors-assessment/code-intelligence/codebase-analyzer.js.map +1 -1
- package/v3/dist/domains/requirements-validation/services/requirements-validator.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/services/requirements-validator.js +7 -5
- package/v3/dist/domains/requirements-validation/services/requirements-validator.js.map +1 -1
- package/v3/dist/domains/requirements-validation/services/testability-scorer.d.ts.map +1 -1
- package/v3/dist/domains/requirements-validation/services/testability-scorer.js +4 -3
- package/v3/dist/domains/requirements-validation/services/testability-scorer.js.map +1 -1
- package/v3/dist/domains/security-compliance/coordinator.d.ts +12 -58
- package/v3/dist/domains/security-compliance/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/coordinator.js +22 -164
- package/v3/dist/domains/security-compliance/coordinator.js.map +1 -1
- package/v3/dist/domains/security-compliance/index.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/index.js +14 -0
- package/v3/dist/domains/security-compliance/index.js.map +1 -1
- package/v3/dist/domains/security-compliance/plugin.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/plugin.js +2 -1
- package/v3/dist/domains/security-compliance/plugin.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/compliance-validator.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/compliance-validator.js +6 -5
- package/v3/dist/domains/security-compliance/services/compliance-validator.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dast-helpers.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dast-helpers.js +2 -1
- package/v3/dist/domains/security-compliance/services/scanners/dast-helpers.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dast-scanner.d.ts +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dast-scanner.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dast-scanner.js +4 -3
- package/v3/dist/domains/security-compliance/services/scanners/dast-scanner.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dependency-scanner.d.ts +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dependency-scanner.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/dependency-scanner.js +7 -5
- package/v3/dist/domains/security-compliance/services/scanners/dependency-scanner.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/sast-scanner.d.ts +2 -2
- package/v3/dist/domains/security-compliance/services/scanners/sast-scanner.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/sast-scanner.js +6 -4
- package/v3/dist/domains/security-compliance/services/scanners/sast-scanner.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/scanner-orchestrator.d.ts +2 -2
- package/v3/dist/domains/security-compliance/services/scanners/scanner-orchestrator.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/scanner-orchestrator.js +3 -2
- package/v3/dist/domains/security-compliance/services/scanners/scanner-orchestrator.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/scanners/scanner-types.d.ts +2 -2
- package/v3/dist/domains/security-compliance/services/scanners/scanner-types.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/security-auditor-dast.d.ts +11 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-dast.d.ts.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-dast.js +284 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-dast.js.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-reports.d.ts +44 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-reports.d.ts.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-reports.js +193 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-reports.js.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-sast.d.ts +27 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-sast.d.ts.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-sast.js +279 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-sast.js.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-secrets.d.ts +34 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-secrets.d.ts.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-secrets.js +236 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-secrets.js.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-types.d.ts +93 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-types.d.ts.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-types.js +50 -0
- package/v3/dist/domains/security-compliance/services/security-auditor-types.js.map +1 -0
- package/v3/dist/domains/security-compliance/services/security-auditor.d.ts +12 -132
- package/v3/dist/domains/security-compliance/services/security-auditor.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/security-auditor.js +71 -1188
- package/v3/dist/domains/security-compliance/services/security-auditor.js.map +1 -1
- package/v3/dist/domains/security-compliance/services/semgrep-integration.d.ts.map +1 -1
- package/v3/dist/domains/security-compliance/services/semgrep-integration.js +4 -2
- package/v3/dist/domains/security-compliance/services/semgrep-integration.js.map +1 -1
- package/v3/dist/domains/test-execution/coordinator.d.ts +8 -60
- package/v3/dist/domains/test-execution/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/coordinator.js +19 -132
- package/v3/dist/domains/test-execution/coordinator.js.map +1 -1
- package/v3/dist/domains/test-execution/services/auth-state-manager.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/auth-state-manager.js +2 -1
- package/v3/dist/domains/test-execution/services/auth-state-manager.js.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/assertion-handlers.d.ts +2 -2
- package/v3/dist/domains/test-execution/services/e2e/assertion-handlers.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/browser-orchestrator.d.ts +2 -2
- package/v3/dist/domains/test-execution/services/e2e/browser-orchestrator.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/browser-orchestrator.js +2 -1
- package/v3/dist/domains/test-execution/services/e2e/browser-orchestrator.js.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/e2e-coordinator.d.ts +2 -2
- package/v3/dist/domains/test-execution/services/e2e/e2e-coordinator.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/e2e-coordinator.js +3 -2
- package/v3/dist/domains/test-execution/services/e2e/e2e-coordinator.js.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/result-collector.d.ts +1 -1
- package/v3/dist/domains/test-execution/services/e2e/result-collector.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/step-executors.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/step-executors.js +2 -1
- package/v3/dist/domains/test-execution/services/e2e/step-executors.js.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/step-retry-handler.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/step-retry-handler.js +3 -2
- package/v3/dist/domains/test-execution/services/e2e/step-retry-handler.js.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/types.d.ts +2 -2
- package/v3/dist/domains/test-execution/services/e2e/types.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/e2e/wait-condition-handler.d.ts +1 -1
- package/v3/dist/domains/test-execution/services/e2e/wait-condition-handler.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/flaky-detector.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/flaky-detector.js +7 -5
- package/v3/dist/domains/test-execution/services/flaky-detector.js.map +1 -1
- package/v3/dist/domains/test-execution/services/retry-handler.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/retry-handler.js +8 -6
- package/v3/dist/domains/test-execution/services/retry-handler.js.map +1 -1
- package/v3/dist/domains/test-execution/services/test-executor.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/test-executor.js +8 -6
- package/v3/dist/domains/test-execution/services/test-executor.js.map +1 -1
- package/v3/dist/domains/test-execution/services/test-prioritizer.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/test-prioritizer.js +2 -1
- package/v3/dist/domains/test-execution/services/test-prioritizer.js.map +1 -1
- package/v3/dist/domains/test-execution/services/user-flow-generator.d.ts +28 -0
- package/v3/dist/domains/test-execution/services/user-flow-generator.d.ts.map +1 -1
- package/v3/dist/domains/test-execution/services/user-flow-generator.js +156 -189
- package/v3/dist/domains/test-execution/services/user-flow-generator.js.map +1 -1
- package/v3/dist/domains/test-generation/coordinator.d.ts +14 -78
- package/v3/dist/domains/test-generation/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/coordinator.js +58 -202
- package/v3/dist/domains/test-generation/coordinator.js.map +1 -1
- package/v3/dist/domains/test-generation/generators/base-test-generator.d.ts +10 -0
- package/v3/dist/domains/test-generation/generators/base-test-generator.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/generators/base-test-generator.js +37 -30
- package/v3/dist/domains/test-generation/generators/base-test-generator.js.map +1 -1
- package/v3/dist/domains/test-generation/index.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/index.js +10 -0
- package/v3/dist/domains/test-generation/index.js.map +1 -1
- package/v3/dist/domains/test-generation/plugin.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/plugin.js +2 -1
- package/v3/dist/domains/test-generation/plugin.js.map +1 -1
- package/v3/dist/domains/test-generation/services/code-transform-integration.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/services/code-transform-integration.js +2 -1
- package/v3/dist/domains/test-generation/services/code-transform-integration.js.map +1 -1
- package/v3/dist/domains/test-generation/services/pattern-matcher.d.ts +10 -0
- package/v3/dist/domains/test-generation/services/pattern-matcher.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/services/pattern-matcher.js +43 -41
- package/v3/dist/domains/test-generation/services/pattern-matcher.js.map +1 -1
- package/v3/dist/domains/test-generation/services/test-generator.d.ts.map +1 -1
- package/v3/dist/domains/test-generation/services/test-generator.js +47 -17
- package/v3/dist/domains/test-generation/services/test-generator.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/coordinator.d.ts +17 -60
- package/v3/dist/domains/visual-accessibility/coordinator.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/coordinator.js +32 -183
- package/v3/dist/domains/visual-accessibility/coordinator.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/plugin.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/plugin.js +4 -3
- package/v3/dist/domains/visual-accessibility/plugin.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-browser.d.ts +114 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-browser.d.ts.map +1 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-browser.js +578 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-browser.js.map +1 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-heuristics.d.ts +54 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-heuristics.d.ts.map +1 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-heuristics.js +403 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester-heuristics.js.map +1 -0
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester.d.ts +1 -314
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester.js +79 -1467
- package/v3/dist/domains/visual-accessibility/services/accessibility-tester.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/axe-core-audit.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/axe-core-audit.js +2 -1
- package/v3/dist/domains/visual-accessibility/services/axe-core-audit.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/axe-core-integration.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/axe-core-integration.js +5 -4
- package/v3/dist/domains/visual-accessibility/services/axe-core-integration.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/browser-security-scanner.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/browser-security-scanner.js +5 -4
- package/v3/dist/domains/visual-accessibility/services/browser-security-scanner.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/browser-swarm-coordinator.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/browser-swarm-coordinator.js +8 -7
- package/v3/dist/domains/visual-accessibility/services/browser-swarm-coordinator.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/eu-compliance.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/eu-compliance.js +2 -1
- package/v3/dist/domains/visual-accessibility/services/eu-compliance.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/responsive-tester.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/responsive-tester.js +5 -4
- package/v3/dist/domains/visual-accessibility/services/responsive-tester.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/viewport-capture.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/viewport-capture.js +7 -6
- package/v3/dist/domains/visual-accessibility/services/viewport-capture.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/visual-regression.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/visual-regression.js +11 -10
- package/v3/dist/domains/visual-accessibility/services/visual-regression.js.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/visual-tester.d.ts.map +1 -1
- package/v3/dist/domains/visual-accessibility/services/visual-tester.js +7 -6
- package/v3/dist/domains/visual-accessibility/services/visual-tester.js.map +1 -1
- package/v3/dist/early-exit/early-exit-controller.d.ts.map +1 -1
- package/v3/dist/early-exit/early-exit-controller.js +4 -3
- package/v3/dist/early-exit/early-exit-controller.js.map +1 -1
- package/v3/dist/feedback/coverage-learner.d.ts.map +1 -1
- package/v3/dist/feedback/coverage-learner.js +7 -5
- package/v3/dist/feedback/coverage-learner.js.map +1 -1
- package/v3/dist/feedback/test-outcome-tracker.d.ts.map +1 -1
- package/v3/dist/feedback/test-outcome-tracker.js +6 -4
- package/v3/dist/feedback/test-outcome-tracker.js.map +1 -1
- package/v3/dist/governance/adversarial-defense-integration.d.ts +0 -18
- package/v3/dist/governance/adversarial-defense-integration.d.ts.map +1 -1
- package/v3/dist/governance/adversarial-defense-integration.js +2 -1
- package/v3/dist/governance/adversarial-defense-integration.js.map +1 -1
- package/v3/dist/governance/compliance-reporter.d.ts +0 -16
- package/v3/dist/governance/compliance-reporter.d.ts.map +1 -1
- package/v3/dist/governance/compliance-reporter.js +6 -8
- package/v3/dist/governance/compliance-reporter.js.map +1 -1
- package/v3/dist/governance/continue-gate-integration.d.ts.map +1 -1
- package/v3/dist/governance/continue-gate-integration.js +3 -2
- package/v3/dist/governance/continue-gate-integration.js.map +1 -1
- package/v3/dist/governance/evolution-pipeline-integration.d.ts.map +1 -1
- package/v3/dist/governance/evolution-pipeline-integration.js +3 -2
- package/v3/dist/governance/evolution-pipeline-integration.js.map +1 -1
- package/v3/dist/governance/proof-envelope-integration.d.ts.map +1 -1
- package/v3/dist/governance/proof-envelope-integration.js +4 -4
- package/v3/dist/governance/proof-envelope-integration.js.map +1 -1
- package/v3/dist/governance/shard-embeddings.d.ts.map +1 -1
- package/v3/dist/governance/shard-embeddings.js +16 -2
- package/v3/dist/governance/shard-embeddings.js.map +1 -1
- package/v3/dist/governance/shard-retriever-integration.d.ts.map +1 -1
- package/v3/dist/governance/shard-retriever-integration.js +4 -3
- package/v3/dist/governance/shard-retriever-integration.js.map +1 -1
- package/v3/dist/governance/wasm-kernel-integration.d.ts.map +1 -1
- package/v3/dist/governance/wasm-kernel-integration.js +4 -2
- package/v3/dist/governance/wasm-kernel-integration.js.map +1 -1
- package/v3/dist/hooks/reasoning-bank-pattern-store.d.ts.map +1 -1
- package/v3/dist/hooks/reasoning-bank-pattern-store.js +3 -2
- package/v3/dist/hooks/reasoning-bank-pattern-store.js.map +1 -1
- package/v3/dist/hooks/task-completed-hook.d.ts.map +1 -1
- package/v3/dist/hooks/task-completed-hook.js +3 -2
- package/v3/dist/hooks/task-completed-hook.js.map +1 -1
- package/v3/dist/init/agents-installer.d.ts.map +1 -1
- package/v3/dist/init/agents-installer.js +2 -1
- package/v3/dist/init/agents-installer.js.map +1 -1
- package/v3/dist/init/enhancements/claude-flow-adapter.d.ts.map +1 -1
- package/v3/dist/init/enhancements/claude-flow-adapter.js +3 -2
- package/v3/dist/init/enhancements/claude-flow-adapter.js.map +1 -1
- package/v3/dist/init/fleet-integration.d.ts.map +1 -1
- package/v3/dist/init/fleet-integration.js +2 -1
- package/v3/dist/init/fleet-integration.js.map +1 -1
- package/v3/dist/init/governance-installer.d.ts.map +1 -1
- package/v3/dist/init/governance-installer.js +5 -4
- package/v3/dist/init/governance-installer.js.map +1 -1
- package/v3/dist/init/init-wizard-hooks.d.ts +26 -0
- package/v3/dist/init/init-wizard-hooks.d.ts.map +1 -0
- package/v3/dist/init/init-wizard-hooks.js +555 -0
- package/v3/dist/init/init-wizard-hooks.js.map +1 -0
- package/v3/dist/init/init-wizard-migration.d.ts +52 -0
- package/v3/dist/init/init-wizard-migration.d.ts.map +1 -0
- package/v3/dist/init/init-wizard-migration.js +349 -0
- package/v3/dist/init/init-wizard-migration.js.map +1 -0
- package/v3/dist/init/init-wizard-steps.d.ts +68 -0
- package/v3/dist/init/init-wizard-steps.d.ts.map +1 -0
- package/v3/dist/init/init-wizard-steps.js +457 -0
- package/v3/dist/init/init-wizard-steps.js.map +1 -0
- package/v3/dist/init/init-wizard.d.ts +8 -130
- package/v3/dist/init/init-wizard.d.ts.map +1 -1
- package/v3/dist/init/init-wizard.js +108 -1528
- package/v3/dist/init/init-wizard.js.map +1 -1
- package/v3/dist/init/migration/config-migrator.d.ts.map +1 -1
- package/v3/dist/init/migration/config-migrator.js +2 -1
- package/v3/dist/init/migration/config-migrator.js.map +1 -1
- package/v3/dist/init/migration/data-migrator.d.ts.map +1 -1
- package/v3/dist/init/migration/data-migrator.js +5 -3
- package/v3/dist/init/migration/data-migrator.js.map +1 -1
- package/v3/dist/init/migration/detector.d.ts.map +1 -1
- package/v3/dist/init/migration/detector.js +2 -1
- package/v3/dist/init/migration/detector.js.map +1 -1
- package/v3/dist/init/n8n-installer.d.ts.map +1 -1
- package/v3/dist/init/n8n-installer.js +4 -3
- package/v3/dist/init/n8n-installer.js.map +1 -1
- package/v3/dist/init/orchestrator.d.ts.map +1 -1
- package/v3/dist/init/orchestrator.js +2 -1
- package/v3/dist/init/orchestrator.js.map +1 -1
- package/v3/dist/init/phases/01-detection.d.ts.map +1 -1
- package/v3/dist/init/phases/01-detection.js +2 -1
- package/v3/dist/init/phases/01-detection.js.map +1 -1
- package/v3/dist/init/phases/06-code-intelligence.d.ts.map +1 -1
- package/v3/dist/init/phases/06-code-intelligence.js +2 -1
- package/v3/dist/init/phases/06-code-intelligence.js.map +1 -1
- package/v3/dist/init/phases/07-hooks.d.ts.map +1 -1
- package/v3/dist/init/phases/07-hooks.js +2 -1
- package/v3/dist/init/phases/07-hooks.js.map +1 -1
- package/v3/dist/init/phases/08-mcp.d.ts.map +1 -1
- package/v3/dist/init/phases/08-mcp.js +3 -2
- package/v3/dist/init/phases/08-mcp.js.map +1 -1
- package/v3/dist/init/phases/phase-interface.d.ts.map +1 -1
- package/v3/dist/init/phases/phase-interface.js +3 -2
- package/v3/dist/init/phases/phase-interface.js.map +1 -1
- package/v3/dist/init/project-analyzer.d.ts.map +1 -1
- package/v3/dist/init/project-analyzer.js +3 -2
- package/v3/dist/init/project-analyzer.js.map +1 -1
- package/v3/dist/init/skills-installer.d.ts.map +1 -1
- package/v3/dist/init/skills-installer.js +2 -1
- package/v3/dist/init/skills-installer.js.map +1 -1
- package/v3/dist/integrations/agent-booster-wasm/index.d.ts.map +1 -1
- package/v3/dist/integrations/agent-booster-wasm/index.js +4 -1
- package/v3/dist/integrations/agent-booster-wasm/index.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/metrics/pattern-updater.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/metrics/pattern-updater.js +6 -4
- package/v3/dist/integrations/agentic-flow/metrics/pattern-updater.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/onnx-embeddings/adapter.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/onnx-embeddings/adapter.js +10 -0
- package/v3/dist/integrations/agentic-flow/onnx-embeddings/adapter.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/pattern-loader.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/pattern-loader.js +4 -2
- package/v3/dist/integrations/agentic-flow/pattern-loader.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/experience-replay.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/experience-replay.js +4 -3
- package/v3/dist/integrations/agentic-flow/reasoning-bank/experience-replay.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/index.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/index.js +2 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/index.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/pattern-evolution.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/pattern-evolution.js +6 -5
- package/v3/dist/integrations/agentic-flow/reasoning-bank/pattern-evolution.js.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/trajectory-tracker.d.ts.map +1 -1
- package/v3/dist/integrations/agentic-flow/reasoning-bank/trajectory-tracker.js +7 -6
- package/v3/dist/integrations/agentic-flow/reasoning-bank/trajectory-tracker.js.map +1 -1
- package/v3/dist/integrations/browser/agent-browser/client.d.ts.map +1 -1
- package/v3/dist/integrations/browser/agent-browser/client.js +33 -31
- package/v3/dist/integrations/browser/agent-browser/client.js.map +1 -1
- package/v3/dist/integrations/browser/agent-browser/command-executor.d.ts.map +1 -1
- package/v3/dist/integrations/browser/agent-browser/command-executor.js +42 -22
- package/v3/dist/integrations/browser/agent-browser/command-executor.js.map +1 -1
- package/v3/dist/integrations/browser/agent-browser/snapshot-parser.d.ts.map +1 -1
- package/v3/dist/integrations/browser/agent-browser/snapshot-parser.js +2 -1
- package/v3/dist/integrations/browser/agent-browser/snapshot-parser.js.map +1 -1
- package/v3/dist/integrations/browser/web-content-fetcher.d.ts.map +1 -1
- package/v3/dist/integrations/browser/web-content-fetcher.js +4 -2
- package/v3/dist/integrations/browser/web-content-fetcher.js.map +1 -1
- package/v3/dist/integrations/coherence/coherence-service.d.ts.map +1 -1
- package/v3/dist/integrations/coherence/coherence-service.js +4 -3
- package/v3/dist/integrations/coherence/coherence-service.js.map +1 -1
- package/v3/dist/integrations/coherence/engines/spectral-adapter.d.ts.map +1 -1
- package/v3/dist/integrations/coherence/engines/spectral-adapter.js +4 -3
- package/v3/dist/integrations/coherence/engines/spectral-adapter.js.map +1 -1
- package/v3/dist/integrations/coherence/wasm-loader.d.ts.map +1 -1
- package/v3/dist/integrations/coherence/wasm-loader.js +4 -3
- package/v3/dist/integrations/coherence/wasm-loader.js.map +1 -1
- package/v3/dist/integrations/embeddings/cache/EmbeddingCache.d.ts +6 -0
- package/v3/dist/integrations/embeddings/cache/EmbeddingCache.d.ts.map +1 -1
- package/v3/dist/integrations/embeddings/cache/EmbeddingCache.js +35 -6
- package/v3/dist/integrations/embeddings/cache/EmbeddingCache.js.map +1 -1
- package/v3/dist/integrations/n8n/agent-factory.d.ts.map +1 -1
- package/v3/dist/integrations/n8n/agent-factory.js +2 -1
- package/v3/dist/integrations/n8n/agent-factory.js.map +1 -1
- package/v3/dist/integrations/rl-suite/base-algorithm.d.ts.map +1 -1
- package/v3/dist/integrations/rl-suite/base-algorithm.js +8 -3
- package/v3/dist/integrations/rl-suite/base-algorithm.js.map +1 -1
- package/v3/dist/integrations/rl-suite/persistence/q-value-store.d.ts.map +1 -1
- package/v3/dist/integrations/rl-suite/persistence/q-value-store.js +2 -1
- package/v3/dist/integrations/rl-suite/persistence/q-value-store.js.map +1 -1
- package/v3/dist/integrations/ruvector/ast-complexity.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/ast-complexity.js +3 -2
- package/v3/dist/integrations/ruvector/ast-complexity.js.map +1 -1
- package/v3/dist/integrations/ruvector/attention-wrapper.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/attention-wrapper.js +2 -1
- package/v3/dist/integrations/ruvector/attention-wrapper.js.map +1 -1
- package/v3/dist/integrations/ruvector/coverage-router.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/coverage-router.js +3 -2
- package/v3/dist/integrations/ruvector/coverage-router.js.map +1 -1
- package/v3/dist/integrations/ruvector/diff-risk-classifier.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/diff-risk-classifier.js +3 -2
- package/v3/dist/integrations/ruvector/diff-risk-classifier.js.map +1 -1
- package/v3/dist/integrations/ruvector/gnn-wrapper.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/gnn-wrapper.js +2 -1
- package/v3/dist/integrations/ruvector/gnn-wrapper.js.map +1 -1
- package/v3/dist/integrations/ruvector/graph-boundaries.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/graph-boundaries.js +3 -2
- package/v3/dist/integrations/ruvector/graph-boundaries.js.map +1 -1
- package/v3/dist/integrations/ruvector/hypergraph-engine.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/hypergraph-engine.js +68 -67
- package/v3/dist/integrations/ruvector/hypergraph-engine.js.map +1 -1
- package/v3/dist/integrations/ruvector/hypergraph-schema.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/hypergraph-schema.js +3 -2
- package/v3/dist/integrations/ruvector/hypergraph-schema.js.map +1 -1
- package/v3/dist/integrations/ruvector/persistent-q-router.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/persistent-q-router.js +35 -11
- package/v3/dist/integrations/ruvector/persistent-q-router.js.map +1 -1
- package/v3/dist/integrations/ruvector/q-learning-router.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/q-learning-router.js +3 -2
- package/v3/dist/integrations/ruvector/q-learning-router.js.map +1 -1
- package/v3/dist/integrations/ruvector/server-client.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/server-client.js +23 -10
- package/v3/dist/integrations/ruvector/server-client.js.map +1 -1
- package/v3/dist/integrations/ruvector/sona-persistence.d.ts.map +1 -1
- package/v3/dist/integrations/ruvector/sona-persistence.js +11 -6
- package/v3/dist/integrations/ruvector/sona-persistence.js.map +1 -1
- package/v3/dist/integrations/vibium/client.d.ts.map +1 -1
- package/v3/dist/integrations/vibium/client.js +11 -10
- package/v3/dist/integrations/vibium/client.js.map +1 -1
- package/v3/dist/kernel/anti-drift-middleware.d.ts.map +1 -1
- package/v3/dist/kernel/anti-drift-middleware.js +8 -3
- package/v3/dist/kernel/anti-drift-middleware.js.map +1 -1
- package/v3/dist/kernel/hybrid-backend.d.ts.map +1 -1
- package/v3/dist/kernel/hybrid-backend.js +4 -0
- package/v3/dist/kernel/hybrid-backend.js.map +1 -1
- package/v3/dist/kernel/index.d.ts +1 -1
- package/v3/dist/kernel/index.d.ts.map +1 -1
- package/v3/dist/kernel/index.js +1 -1
- package/v3/dist/kernel/index.js.map +1 -1
- package/v3/dist/kernel/kernel.d.ts +5 -0
- package/v3/dist/kernel/kernel.d.ts.map +1 -1
- package/v3/dist/kernel/kernel.js +42 -29
- package/v3/dist/kernel/kernel.js.map +1 -1
- package/v3/dist/kernel/memory-factory.d.ts.map +1 -1
- package/v3/dist/kernel/memory-factory.js +12 -4
- package/v3/dist/kernel/memory-factory.js.map +1 -1
- package/v3/dist/kernel/plugin-loader.d.ts.map +1 -1
- package/v3/dist/kernel/plugin-loader.js +4 -1
- package/v3/dist/kernel/plugin-loader.js.map +1 -1
- package/v3/dist/kernel/unified-memory-hnsw.d.ts +101 -0
- package/v3/dist/kernel/unified-memory-hnsw.d.ts.map +1 -0
- package/v3/dist/kernel/unified-memory-hnsw.js +411 -0
- package/v3/dist/kernel/unified-memory-hnsw.js.map +1 -0
- package/v3/dist/kernel/unified-memory-migration.d.ts.map +1 -1
- package/v3/dist/kernel/unified-memory-migration.js +14 -15
- package/v3/dist/kernel/unified-memory-migration.js.map +1 -1
- package/v3/dist/kernel/unified-memory-schemas.d.ts +21 -0
- package/v3/dist/kernel/unified-memory-schemas.d.ts.map +1 -0
- package/v3/dist/kernel/unified-memory-schemas.js +581 -0
- package/v3/dist/kernel/unified-memory-schemas.js.map +1 -0
- package/v3/dist/kernel/unified-memory.d.ts +13 -197
- package/v3/dist/kernel/unified-memory.d.ts.map +1 -1
- package/v3/dist/kernel/unified-memory.js +113 -1382
- package/v3/dist/kernel/unified-memory.js.map +1 -1
- package/v3/dist/kernel/unified-persistence.d.ts.map +1 -1
- package/v3/dist/kernel/unified-persistence.js +6 -4
- package/v3/dist/kernel/unified-persistence.js.map +1 -1
- package/v3/dist/learning/aqe-learning-engine.d.ts.map +1 -1
- package/v3/dist/learning/aqe-learning-engine.js +11 -9
- package/v3/dist/learning/aqe-learning-engine.js.map +1 -1
- package/v3/dist/learning/dream/concept-graph.d.ts.map +1 -1
- package/v3/dist/learning/dream/concept-graph.js +6 -4
- package/v3/dist/learning/dream/concept-graph.js.map +1 -1
- package/v3/dist/learning/dream/dream-engine.d.ts +8 -0
- package/v3/dist/learning/dream/dream-engine.d.ts.map +1 -1
- package/v3/dist/learning/dream/dream-engine.js +35 -5
- package/v3/dist/learning/dream/dream-engine.js.map +1 -1
- package/v3/dist/learning/dream/dream-scheduler.d.ts.map +1 -1
- package/v3/dist/learning/dream/dream-scheduler.js +34 -22
- package/v3/dist/learning/dream/dream-scheduler.js.map +1 -1
- package/v3/dist/learning/experience-capture-middleware.d.ts.map +1 -1
- package/v3/dist/learning/experience-capture-middleware.js +2 -1
- package/v3/dist/learning/experience-capture-middleware.js.map +1 -1
- package/v3/dist/learning/experience-capture.d.ts.map +1 -1
- package/v3/dist/learning/experience-capture.js +4 -1
- package/v3/dist/learning/experience-capture.js.map +1 -1
- package/v3/dist/learning/memory-auditor.d.ts.map +1 -1
- package/v3/dist/learning/memory-auditor.js +3 -2
- package/v3/dist/learning/memory-auditor.js.map +1 -1
- package/v3/dist/learning/metrics-tracker.d.ts.map +1 -1
- package/v3/dist/learning/metrics-tracker.js +6 -2
- package/v3/dist/learning/metrics-tracker.js.map +1 -1
- package/v3/dist/learning/pattern-lifecycle.d.ts.map +1 -1
- package/v3/dist/learning/pattern-lifecycle.js +11 -5
- package/v3/dist/learning/pattern-lifecycle.js.map +1 -1
- package/v3/dist/learning/pattern-store.d.ts +7 -0
- package/v3/dist/learning/pattern-store.d.ts.map +1 -1
- package/v3/dist/learning/pattern-store.js +32 -4
- package/v3/dist/learning/pattern-store.js.map +1 -1
- package/v3/dist/learning/qe-hooks.d.ts.map +1 -1
- package/v3/dist/learning/qe-hooks.js +55 -10
- package/v3/dist/learning/qe-hooks.js.map +1 -1
- package/v3/dist/learning/qe-reasoning-bank.d.ts +13 -0
- package/v3/dist/learning/qe-reasoning-bank.d.ts.map +1 -1
- package/v3/dist/learning/qe-reasoning-bank.js +64 -24
- package/v3/dist/learning/qe-reasoning-bank.js.map +1 -1
- package/v3/dist/learning/qe-unified-memory.d.ts.map +1 -1
- package/v3/dist/learning/qe-unified-memory.js +31 -21
- package/v3/dist/learning/qe-unified-memory.js.map +1 -1
- package/v3/dist/learning/real-embeddings.d.ts.map +1 -1
- package/v3/dist/learning/real-embeddings.js +2 -1
- package/v3/dist/learning/real-embeddings.js.map +1 -1
- package/v3/dist/learning/real-qe-reasoning-bank.d.ts.map +1 -1
- package/v3/dist/learning/real-qe-reasoning-bank.js +47 -34
- package/v3/dist/learning/real-qe-reasoning-bank.js.map +1 -1
- package/v3/dist/learning/skill-validation-learner.d.ts.map +1 -1
- package/v3/dist/learning/skill-validation-learner.js +21 -12
- package/v3/dist/learning/skill-validation-learner.js.map +1 -1
- package/v3/dist/learning/sqlite-persistence.d.ts +9 -0
- package/v3/dist/learning/sqlite-persistence.d.ts.map +1 -1
- package/v3/dist/learning/sqlite-persistence.js +65 -6
- package/v3/dist/learning/sqlite-persistence.js.map +1 -1
- package/v3/dist/learning/token-tracker.d.ts.map +1 -1
- package/v3/dist/learning/token-tracker.js +4 -2
- package/v3/dist/learning/token-tracker.js.map +1 -1
- package/v3/dist/learning/v2-to-v3-migration.d.ts.map +1 -1
- package/v3/dist/learning/v2-to-v3-migration.js +9 -4
- package/v3/dist/learning/v2-to-v3-migration.js.map +1 -1
- package/v3/dist/mcp/bundle.js +14901 -13696
- package/v3/dist/mcp/handlers/agent-handlers.d.ts.map +1 -1
- package/v3/dist/mcp/handlers/agent-handlers.js +5 -4
- package/v3/dist/mcp/handlers/agent-handlers.js.map +1 -1
- package/v3/dist/mcp/handlers/core-handlers.d.ts.map +1 -1
- package/v3/dist/mcp/handlers/core-handlers.js +4 -3
- package/v3/dist/mcp/handlers/core-handlers.js.map +1 -1
- package/v3/dist/mcp/handlers/handler-factory.d.ts.map +1 -1
- package/v3/dist/mcp/handlers/handler-factory.js +12 -3
- package/v3/dist/mcp/handlers/handler-factory.js.map +1 -1
- package/v3/dist/mcp/handlers/memory-handlers.d.ts.map +1 -1
- package/v3/dist/mcp/handlers/memory-handlers.js +8 -8
- package/v3/dist/mcp/handlers/memory-handlers.js.map +1 -1
- package/v3/dist/mcp/handlers/task-handlers.d.ts.map +1 -1
- package/v3/dist/mcp/handlers/task-handlers.js +11 -10
- package/v3/dist/mcp/handlers/task-handlers.js.map +1 -1
- package/v3/dist/mcp/http-server.js +1 -1
- package/v3/dist/mcp/http-server.js.map +1 -1
- package/v3/dist/mcp/security/index.d.ts +2 -6
- package/v3/dist/mcp/security/index.d.ts.map +1 -1
- package/v3/dist/mcp/security/index.js +2 -2
- package/v3/dist/mcp/security/index.js.map +1 -1
- package/v3/dist/mcp/security/oauth21-provider.d.ts +7 -0
- package/v3/dist/mcp/security/oauth21-provider.d.ts.map +1 -1
- package/v3/dist/mcp/security/oauth21-provider.js +15 -3
- package/v3/dist/mcp/security/oauth21-provider.js.map +1 -1
- package/v3/dist/mcp/server.d.ts.map +1 -1
- package/v3/dist/mcp/server.js +10 -24
- package/v3/dist/mcp/server.js.map +1 -1
- package/v3/dist/mcp/tool-registry.d.ts.map +1 -1
- package/v3/dist/mcp/tool-registry.js +2 -1
- package/v3/dist/mcp/tool-registry.js.map +1 -1
- package/v3/dist/mcp/tools/analysis/token-usage.d.ts.map +1 -1
- package/v3/dist/mcp/tools/analysis/token-usage.js +2 -1
- package/v3/dist/mcp/tools/analysis/token-usage.js.map +1 -1
- package/v3/dist/mcp/tools/base.d.ts.map +1 -1
- package/v3/dist/mcp/tools/base.js +2 -1
- package/v3/dist/mcp/tools/base.js.map +1 -1
- package/v3/dist/mcp/tools/chaos-resilience/inject.d.ts.map +1 -1
- package/v3/dist/mcp/tools/chaos-resilience/inject.js +2 -1
- package/v3/dist/mcp/tools/chaos-resilience/inject.js.map +1 -1
- package/v3/dist/mcp/tools/code-intelligence/analyze.d.ts.map +1 -1
- package/v3/dist/mcp/tools/code-intelligence/analyze.js +2 -1
- package/v3/dist/mcp/tools/code-intelligence/analyze.js.map +1 -1
- package/v3/dist/mcp/tools/coherence/audit.d.ts.map +1 -1
- package/v3/dist/mcp/tools/coherence/audit.js +2 -1
- package/v3/dist/mcp/tools/coherence/audit.js.map +1 -1
- package/v3/dist/mcp/tools/coherence/check.d.ts.map +1 -1
- package/v3/dist/mcp/tools/coherence/check.js +2 -1
- package/v3/dist/mcp/tools/coherence/check.js.map +1 -1
- package/v3/dist/mcp/tools/coherence/collapse.d.ts.map +1 -1
- package/v3/dist/mcp/tools/coherence/collapse.js +2 -1
- package/v3/dist/mcp/tools/coherence/collapse.js.map +1 -1
- package/v3/dist/mcp/tools/coherence/consensus.d.ts.map +1 -1
- package/v3/dist/mcp/tools/coherence/consensus.js +2 -1
- package/v3/dist/mcp/tools/coherence/consensus.js.map +1 -1
- package/v3/dist/mcp/tools/contract-testing/validate.d.ts.map +1 -1
- package/v3/dist/mcp/tools/contract-testing/validate.js +4 -3
- package/v3/dist/mcp/tools/contract-testing/validate.js.map +1 -1
- package/v3/dist/mcp/tools/coverage-analysis/index.d.ts.map +1 -1
- package/v3/dist/mcp/tools/coverage-analysis/index.js +7 -6
- package/v3/dist/mcp/tools/coverage-analysis/index.js.map +1 -1
- package/v3/dist/mcp/tools/defect-intelligence/predict.d.ts.map +1 -1
- package/v3/dist/mcp/tools/defect-intelligence/predict.js +2 -1
- package/v3/dist/mcp/tools/defect-intelligence/predict.js.map +1 -1
- package/v3/dist/mcp/tools/embeddings/embedding.d.ts.map +1 -1
- package/v3/dist/mcp/tools/embeddings/embedding.js +6 -5
- package/v3/dist/mcp/tools/embeddings/embedding.js.map +1 -1
- package/v3/dist/mcp/tools/learning-optimization/dream.d.ts.map +1 -1
- package/v3/dist/mcp/tools/learning-optimization/dream.js +3 -2
- package/v3/dist/mcp/tools/learning-optimization/dream.js.map +1 -1
- package/v3/dist/mcp/tools/learning-optimization/optimize.d.ts.map +1 -1
- package/v3/dist/mcp/tools/learning-optimization/optimize.js +2 -1
- package/v3/dist/mcp/tools/learning-optimization/optimize.js.map +1 -1
- package/v3/dist/mcp/tools/planning/goap-execute.d.ts.map +1 -1
- package/v3/dist/mcp/tools/planning/goap-execute.js +2 -1
- package/v3/dist/mcp/tools/planning/goap-execute.js.map +1 -1
- package/v3/dist/mcp/tools/planning/goap-plan.d.ts.map +1 -1
- package/v3/dist/mcp/tools/planning/goap-plan.js +2 -1
- package/v3/dist/mcp/tools/planning/goap-plan.js.map +1 -1
- package/v3/dist/mcp/tools/planning/goap-status.d.ts.map +1 -1
- package/v3/dist/mcp/tools/planning/goap-status.js +2 -1
- package/v3/dist/mcp/tools/planning/goap-status.js.map +1 -1
- package/v3/dist/mcp/tools/quality-assessment/evaluate.d.ts.map +1 -1
- package/v3/dist/mcp/tools/quality-assessment/evaluate.js +2 -1
- package/v3/dist/mcp/tools/quality-assessment/evaluate.js.map +1 -1
- package/v3/dist/mcp/tools/qx-analysis/analyze.d.ts.map +1 -1
- package/v3/dist/mcp/tools/qx-analysis/analyze.js +2 -1
- package/v3/dist/mcp/tools/qx-analysis/analyze.js.map +1 -1
- package/v3/dist/mcp/tools/qx-analysis/impact-analyzer.d.ts +12 -0
- package/v3/dist/mcp/tools/qx-analysis/impact-analyzer.d.ts.map +1 -1
- package/v3/dist/mcp/tools/qx-analysis/impact-analyzer.js +158 -109
- package/v3/dist/mcp/tools/qx-analysis/impact-analyzer.js.map +1 -1
- package/v3/dist/mcp/tools/requirements-validation/quality-criteria.d.ts.map +1 -1
- package/v3/dist/mcp/tools/requirements-validation/quality-criteria.js +2 -1
- package/v3/dist/mcp/tools/requirements-validation/quality-criteria.js.map +1 -1
- package/v3/dist/mcp/tools/requirements-validation/validate.d.ts.map +1 -1
- package/v3/dist/mcp/tools/requirements-validation/validate.js +2 -1
- package/v3/dist/mcp/tools/requirements-validation/validate.js.map +1 -1
- package/v3/dist/mcp/tools/security-compliance/scan.d.ts.map +1 -1
- package/v3/dist/mcp/tools/security-compliance/scan.js +2 -1
- package/v3/dist/mcp/tools/security-compliance/scan.js.map +1 -1
- package/v3/dist/mcp/tools/test-execution/e2e-execute.d.ts.map +1 -1
- package/v3/dist/mcp/tools/test-execution/e2e-execute.js +2 -1
- package/v3/dist/mcp/tools/test-execution/e2e-execute.js.map +1 -1
- package/v3/dist/mcp/tools/test-execution/execute.d.ts.map +1 -1
- package/v3/dist/mcp/tools/test-execution/execute.js +2 -1
- package/v3/dist/mcp/tools/test-execution/execute.js.map +1 -1
- package/v3/dist/mcp/tools/test-generation/generate.d.ts.map +1 -1
- package/v3/dist/mcp/tools/test-generation/generate.js +2 -1
- package/v3/dist/mcp/tools/test-generation/generate.js.map +1 -1
- package/v3/dist/mcp/tools/visual-accessibility/index.d.ts.map +1 -1
- package/v3/dist/mcp/tools/visual-accessibility/index.js +3 -2
- package/v3/dist/mcp/tools/visual-accessibility/index.js.map +1 -1
- package/v3/dist/mcp/transport/sse/sse-transport.js +1 -1
- package/v3/dist/mcp/transport/sse/sse-transport.js.map +1 -1
- package/v3/dist/mcp/transport/stdio.js +1 -1
- package/v3/dist/mcp/transport/stdio.js.map +1 -1
- package/v3/dist/mcp/transport/websocket/websocket-transport.js +1 -1
- package/v3/dist/mcp/transport/websocket/websocket-transport.js.map +1 -1
- package/v3/dist/memory/crdt/or-set.d.ts.map +1 -1
- package/v3/dist/memory/crdt/or-set.js +2 -1
- package/v3/dist/memory/crdt/or-set.js.map +1 -1
- package/v3/dist/optimization/auto-tuner.d.ts.map +1 -1
- package/v3/dist/optimization/auto-tuner.js +2 -1
- package/v3/dist/optimization/auto-tuner.js.map +1 -1
- package/v3/dist/optimization/early-exit-token-optimizer.d.ts.map +1 -1
- package/v3/dist/optimization/early-exit-token-optimizer.js +2 -1
- package/v3/dist/optimization/early-exit-token-optimizer.js.map +1 -1
- package/v3/dist/optimization/qe-workers.d.ts.map +1 -1
- package/v3/dist/optimization/qe-workers.js +2 -1
- package/v3/dist/optimization/qe-workers.js.map +1 -1
- package/v3/dist/performance/benchmarks.d.ts.map +1 -1
- package/v3/dist/performance/benchmarks.js +2 -1
- package/v3/dist/performance/benchmarks.js.map +1 -1
- package/v3/dist/performance/optimizer.d.ts.map +1 -1
- package/v3/dist/performance/optimizer.js +119 -71
- package/v3/dist/performance/optimizer.js.map +1 -1
- package/v3/dist/performance/run-gates.js +2 -1
- package/v3/dist/performance/run-gates.js.map +1 -1
- package/v3/dist/planning/goap-planner.d.ts +4 -1
- package/v3/dist/planning/goap-planner.d.ts.map +1 -1
- package/v3/dist/planning/goap-planner.js +128 -46
- package/v3/dist/planning/goap-planner.js.map +1 -1
- package/v3/dist/planning/index.d.ts +1 -1
- package/v3/dist/planning/index.d.ts.map +1 -1
- package/v3/dist/planning/index.js.map +1 -1
- package/v3/dist/planning/plan-executor.d.ts.map +1 -1
- package/v3/dist/planning/plan-executor.js +7 -5
- package/v3/dist/planning/plan-executor.js.map +1 -1
- package/v3/dist/planning/types.d.ts +0 -16
- package/v3/dist/planning/types.d.ts.map +1 -1
- package/v3/dist/routing/routing-feedback.d.ts.map +1 -1
- package/v3/dist/routing/routing-feedback.js +7 -5
- package/v3/dist/routing/routing-feedback.js.map +1 -1
- package/v3/dist/shared/base-domain-plugin.d.ts +198 -0
- package/v3/dist/shared/base-domain-plugin.d.ts.map +1 -0
- package/v3/dist/shared/base-domain-plugin.js +292 -0
- package/v3/dist/shared/base-domain-plugin.js.map +1 -0
- package/v3/dist/shared/domain-service-registry.d.ts +70 -0
- package/v3/dist/shared/domain-service-registry.d.ts.map +1 -0
- package/v3/dist/shared/domain-service-registry.js +87 -0
- package/v3/dist/shared/domain-service-registry.js.map +1 -0
- package/v3/dist/shared/embeddings/nomic-embedder.d.ts.map +1 -1
- package/v3/dist/shared/embeddings/nomic-embedder.js +2 -1
- package/v3/dist/shared/embeddings/nomic-embedder.js.map +1 -1
- package/v3/dist/shared/embeddings/ollama-client.d.ts.map +1 -1
- package/v3/dist/shared/embeddings/ollama-client.js +2 -1
- package/v3/dist/shared/embeddings/ollama-client.js.map +1 -1
- package/v3/dist/shared/error-utils.d.ts +16 -0
- package/v3/dist/shared/error-utils.d.ts.map +1 -0
- package/v3/dist/shared/error-utils.js +20 -0
- package/v3/dist/shared/error-utils.js.map +1 -0
- package/v3/dist/shared/http/http-client.d.ts.map +1 -1
- package/v3/dist/shared/http/http-client.js +2 -1
- package/v3/dist/shared/http/http-client.js.map +1 -1
- package/v3/dist/shared/index.d.ts +3 -0
- package/v3/dist/shared/index.d.ts.map +1 -1
- package/v3/dist/shared/index.js +3 -0
- package/v3/dist/shared/index.js.map +1 -1
- package/v3/dist/shared/io/file-reader.d.ts.map +1 -1
- package/v3/dist/shared/io/file-reader.js +2 -1
- package/v3/dist/shared/io/file-reader.js.map +1 -1
- package/v3/dist/shared/llm/circuit-breaker.d.ts.map +1 -1
- package/v3/dist/shared/llm/circuit-breaker.js +2 -1
- package/v3/dist/shared/llm/circuit-breaker.js.map +1 -1
- package/v3/dist/shared/llm/metrics/cost-metrics.js.map +1 -1
- package/v3/dist/shared/llm/metrics/router-metrics.d.ts.map +1 -1
- package/v3/dist/shared/llm/metrics/router-metrics.js.map +1 -1
- package/v3/dist/shared/llm/provider-manager.d.ts.map +1 -1
- package/v3/dist/shared/llm/provider-manager.js +2 -1
- package/v3/dist/shared/llm/provider-manager.js.map +1 -1
- package/v3/dist/shared/llm/providers/azure-openai.d.ts.map +1 -1
- package/v3/dist/shared/llm/providers/azure-openai.js +2 -1
- package/v3/dist/shared/llm/providers/azure-openai.js.map +1 -1
- package/v3/dist/shared/llm/providers/bedrock.d.ts.map +1 -1
- package/v3/dist/shared/llm/providers/bedrock.js +2 -1
- package/v3/dist/shared/llm/providers/bedrock.js.map +1 -1
- package/v3/dist/shared/llm/providers/claude.d.ts.map +1 -1
- package/v3/dist/shared/llm/providers/claude.js +2 -1
- package/v3/dist/shared/llm/providers/claude.js.map +1 -1
- package/v3/dist/shared/llm/providers/gemini.d.ts.map +1 -1
- package/v3/dist/shared/llm/providers/gemini.js +4 -2
- package/v3/dist/shared/llm/providers/gemini.js.map +1 -1
- package/v3/dist/shared/llm/providers/openai.d.ts.map +1 -1
- package/v3/dist/shared/llm/providers/openai.js +2 -1
- package/v3/dist/shared/llm/providers/openai.js.map +1 -1
- package/v3/dist/shared/llm/providers/openrouter.d.ts.map +1 -1
- package/v3/dist/shared/llm/providers/openrouter.js +4 -2
- package/v3/dist/shared/llm/providers/openrouter.js.map +1 -1
- package/v3/dist/shared/llm/router/hybrid-router.d.ts.map +1 -1
- package/v3/dist/shared/llm/router/hybrid-router.js +2 -1
- package/v3/dist/shared/llm/router/hybrid-router.js.map +1 -1
- package/v3/dist/shared/llm/translation/prompt-translator.d.ts.map +1 -1
- package/v3/dist/shared/llm/translation/prompt-translator.js +2 -1
- package/v3/dist/shared/llm/translation/prompt-translator.js.map +1 -1
- package/v3/dist/shared/safe-json.d.ts +57 -0
- package/v3/dist/shared/safe-json.d.ts.map +1 -0
- package/v3/dist/shared/safe-json.js +78 -0
- package/v3/dist/shared/safe-json.js.map +1 -0
- package/v3/dist/shared/sql-safety.d.ts +9 -0
- package/v3/dist/shared/sql-safety.d.ts.map +1 -1
- package/v3/dist/shared/sql-safety.js +20 -1
- package/v3/dist/shared/sql-safety.js.map +1 -1
- package/v3/dist/shared/utils/circular-buffer.js +1 -1
- package/v3/dist/shared/utils/circular-buffer.js.map +1 -1
- package/v3/dist/skills/security-visual-testing/index.d.ts.map +1 -1
- package/v3/dist/skills/security-visual-testing/index.js +6 -5
- package/v3/dist/skills/security-visual-testing/index.js.map +1 -1
- package/v3/dist/strange-loop/strange-loop.d.ts +0 -9
- package/v3/dist/strange-loop/strange-loop.d.ts.map +1 -1
- package/v3/dist/strange-loop/strange-loop.js +23 -15
- package/v3/dist/strange-loop/strange-loop.js.map +1 -1
- package/v3/dist/sync/claude-flow-bridge.d.ts.map +1 -1
- package/v3/dist/sync/claude-flow-bridge.js +2 -1
- package/v3/dist/sync/claude-flow-bridge.js.map +1 -1
- package/v3/dist/sync/cloud/index.d.ts +1 -1
- package/v3/dist/sync/cloud/index.d.ts.map +1 -1
- package/v3/dist/sync/cloud/index.js +1 -1
- package/v3/dist/sync/cloud/index.js.map +1 -1
- package/v3/dist/sync/cloud/postgres-writer.d.ts.map +1 -1
- package/v3/dist/sync/cloud/postgres-writer.js +20 -9
- package/v3/dist/sync/cloud/postgres-writer.js.map +1 -1
- package/v3/dist/sync/cloud/tunnel-manager.d.ts +17 -1
- package/v3/dist/sync/cloud/tunnel-manager.d.ts.map +1 -1
- package/v3/dist/sync/cloud/tunnel-manager.js +36 -1
- package/v3/dist/sync/cloud/tunnel-manager.js.map +1 -1
- package/v3/dist/sync/embeddings/sync-embedding-generator.d.ts.map +1 -1
- package/v3/dist/sync/embeddings/sync-embedding-generator.js +11 -5
- package/v3/dist/sync/embeddings/sync-embedding-generator.js.map +1 -1
- package/v3/dist/sync/readers/json-reader.d.ts.map +1 -1
- package/v3/dist/sync/readers/json-reader.js +2 -1
- package/v3/dist/sync/readers/json-reader.js.map +1 -1
- package/v3/dist/sync/readers/sqlite-reader.d.ts.map +1 -1
- package/v3/dist/sync/readers/sqlite-reader.js +14 -6
- package/v3/dist/sync/readers/sqlite-reader.js.map +1 -1
- package/v3/dist/sync/sync-agent.d.ts.map +1 -1
- package/v3/dist/sync/sync-agent.js +10 -6
- package/v3/dist/sync/sync-agent.js.map +1 -1
- package/v3/dist/test-scheduling/executors/vitest-executor.d.ts.map +1 -1
- package/v3/dist/test-scheduling/executors/vitest-executor.js +3 -2
- package/v3/dist/test-scheduling/executors/vitest-executor.js.map +1 -1
- package/v3/dist/test-scheduling/flaky-tracking/flaky-tracker.d.ts.map +1 -1
- package/v3/dist/test-scheduling/flaky-tracking/flaky-tracker.js +2 -1
- package/v3/dist/test-scheduling/flaky-tracking/flaky-tracker.js.map +1 -1
- package/v3/dist/testing/load/agent-load-tester.d.ts.map +1 -1
- package/v3/dist/testing/load/agent-load-tester.js +2 -1
- package/v3/dist/testing/load/agent-load-tester.js.map +1 -1
- package/v3/dist/validation/parallel-eval-runner.d.ts.map +1 -1
- package/v3/dist/validation/parallel-eval-runner.js +83 -37
- package/v3/dist/validation/parallel-eval-runner.js.map +1 -1
- package/v3/dist/validation/swarm-skill-validator.d.ts.map +1 -1
- package/v3/dist/validation/swarm-skill-validator.js +2 -1
- package/v3/dist/validation/swarm-skill-validator.js.map +1 -1
- package/v3/dist/validation/validation-result-aggregator.d.ts.map +1 -1
- package/v3/dist/validation/validation-result-aggregator.js +2 -1
- package/v3/dist/validation/validation-result-aggregator.js.map +1 -1
- package/v3/dist/workers/base-worker.d.ts.map +1 -1
- package/v3/dist/workers/base-worker.js +2 -1
- package/v3/dist/workers/base-worker.js.map +1 -1
- package/v3/dist/workers/workers/cloud-sync.d.ts.map +1 -1
- package/v3/dist/workers/workers/cloud-sync.js +2 -1
- package/v3/dist/workers/workers/cloud-sync.js.map +1 -1
- package/v3/dist/workers/workers/learning-consolidation.d.ts.map +1 -1
- package/v3/dist/workers/workers/learning-consolidation.js +4 -3
- package/v3/dist/workers/workers/learning-consolidation.js.map +1 -1
- package/v3/dist/workers/workers/test-health.d.ts.map +1 -1
- package/v3/dist/workers/workers/test-health.js +2 -1
- package/v3/dist/workers/workers/test-health.js.map +1 -1
- package/v3/package.json +3 -2
|
@@ -23,7 +23,11 @@ import { v4 as uuidv4 } from 'uuid';
|
|
|
23
23
|
import { ok, err } from '../../../shared/types/index.js';
|
|
24
24
|
import { EUComplianceService } from './eu-compliance.js';
|
|
25
25
|
import { isBrowserModeEnabled, isAxeCoreEnabled, } from '../../../integrations/vibium/index.js';
|
|
26
|
+
import { toError } from '../../../shared/error-utils.js';
|
|
26
27
|
import { getBrowserClientForUseCase, } from '../../../integrations/browser/index.js';
|
|
28
|
+
// Extracted modules
|
|
29
|
+
import { WCAG_CRITERIA, getErrorMessage, auditWithBrowserClient, auditWithVibium, auditElementWithVibium, checkContrastWithVibium, checkKeyboardWithVibium, } from './accessibility-tester-browser.js';
|
|
30
|
+
import { initializeRules, filterRulesByLevel, runRule, validateCriterion, analyzeContrastForElements, generateKeyboardReportWithHeuristics, hashUrl, } from './accessibility-tester-heuristics.js';
|
|
27
31
|
const DEFAULT_CONFIG = {
|
|
28
32
|
defaultWCAGLevel: 'AA',
|
|
29
33
|
includeWarnings: true,
|
|
@@ -39,40 +43,9 @@ const DEFAULT_CONFIG = {
|
|
|
39
43
|
browserClient: undefined,
|
|
40
44
|
preferAgentBrowser: true,
|
|
41
45
|
};
|
|
42
|
-
/**
|
|
43
|
-
* WCAG 2.2 criteria definitions
|
|
44
|
-
*/
|
|
45
|
-
const WCAG_CRITERIA = {
|
|
46
|
-
'1.1.1': { id: '1.1.1', level: 'A', title: 'Non-text Content' },
|
|
47
|
-
'1.3.1': { id: '1.3.1', level: 'A', title: 'Info and Relationships' },
|
|
48
|
-
'1.4.1': { id: '1.4.1', level: 'A', title: 'Use of Color' },
|
|
49
|
-
'1.4.3': { id: '1.4.3', level: 'AA', title: 'Contrast (Minimum)' },
|
|
50
|
-
'1.4.6': { id: '1.4.6', level: 'AAA', title: 'Contrast (Enhanced)' },
|
|
51
|
-
'2.1.1': { id: '2.1.1', level: 'A', title: 'Keyboard' },
|
|
52
|
-
'2.1.2': { id: '2.1.2', level: 'A', title: 'No Keyboard Trap' },
|
|
53
|
-
'2.4.1': { id: '2.4.1', level: 'A', title: 'Bypass Blocks' },
|
|
54
|
-
'2.4.3': { id: '2.4.3', level: 'A', title: 'Focus Order' },
|
|
55
|
-
'2.4.4': { id: '2.4.4', level: 'A', title: 'Link Purpose (In Context)' },
|
|
56
|
-
'2.4.7': { id: '2.4.7', level: 'AA', title: 'Focus Visible' },
|
|
57
|
-
'3.1.1': { id: '3.1.1', level: 'A', title: 'Language of Page' },
|
|
58
|
-
'4.1.1': { id: '4.1.1', level: 'A', title: 'Parsing' },
|
|
59
|
-
'4.1.2': { id: '4.1.2', level: 'A', title: 'Name, Role, Value' },
|
|
60
|
-
};
|
|
61
46
|
/**
|
|
62
47
|
* Accessibility Auditing Service Implementation
|
|
63
48
|
* Provides WCAG 2.2 compliance checking with optional browser mode via Vibium
|
|
64
|
-
*
|
|
65
|
-
* @example
|
|
66
|
-
* ```typescript
|
|
67
|
-
* // Heuristic mode (default when Vibium unavailable)
|
|
68
|
-
* const service = new AccessibilityTesterService(memory);
|
|
69
|
-
* const result = await service.audit('https://example.com');
|
|
70
|
-
*
|
|
71
|
-
* // Browser mode with Vibium
|
|
72
|
-
* const vibiumClient = await createVibiumClient({ enabled: true });
|
|
73
|
-
* const browserService = new AccessibilityTesterService(memory, {}, vibiumClient);
|
|
74
|
-
* const browserResult = await browserService.audit('https://example.com');
|
|
75
|
-
* ```
|
|
76
49
|
*/
|
|
77
50
|
export class AccessibilityTesterService {
|
|
78
51
|
memory;
|
|
@@ -82,80 +55,37 @@ export class AccessibilityTesterService {
|
|
|
82
55
|
browserClient;
|
|
83
56
|
managedBrowserClient = null;
|
|
84
57
|
euComplianceService;
|
|
85
|
-
/**
|
|
86
|
-
* Create an AccessibilityTesterService
|
|
87
|
-
*
|
|
88
|
-
* @param memory - Memory backend for storing audit results
|
|
89
|
-
* @param config - Service configuration options
|
|
90
|
-
* @param vibiumClient - Optional Vibium client for browser-based testing (legacy)
|
|
91
|
-
*/
|
|
92
58
|
constructor(memory, config = {}, vibiumClient) {
|
|
93
59
|
this.memory = memory;
|
|
94
60
|
this.config = { ...DEFAULT_CONFIG, ...config };
|
|
95
|
-
this.rules =
|
|
61
|
+
this.rules = initializeRules();
|
|
96
62
|
this.vibiumClient = vibiumClient ?? null;
|
|
97
63
|
this.browserClient = config.browserClient ?? null;
|
|
98
64
|
this.euComplianceService = new EUComplianceService(memory);
|
|
99
65
|
}
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
* Browser mode requires:
|
|
104
|
-
* 1. useBrowserMode config setting enabled
|
|
105
|
-
* 2. Browser client (IBrowserClient) or VibiumClient instance provided
|
|
106
|
-
* 3. Feature flags enabled (if using Vibium)
|
|
107
|
-
*
|
|
108
|
-
* Priority order:
|
|
109
|
-
* 1. Provided browserClient (from config)
|
|
110
|
-
* 2. agent-browser (if preferAgentBrowser is true)
|
|
111
|
-
* 3. Vibium (if available and feature flags enabled)
|
|
112
|
-
*
|
|
113
|
-
* @returns true if browser mode should be used
|
|
114
|
-
*/
|
|
66
|
+
// ============================================================================
|
|
67
|
+
// Browser Mode Detection
|
|
68
|
+
// ============================================================================
|
|
115
69
|
shouldUseBrowserMode() {
|
|
116
|
-
|
|
117
|
-
if (!this.config.useBrowserMode) {
|
|
70
|
+
if (!this.config.useBrowserMode)
|
|
118
71
|
return false;
|
|
119
|
-
|
|
120
|
-
// Check if browser client is provided
|
|
121
|
-
if (this.browserClient) {
|
|
72
|
+
if (this.browserClient)
|
|
122
73
|
return true;
|
|
123
|
-
|
|
124
|
-
// Check if we should prefer agent-browser (factory will be used)
|
|
125
|
-
if (this.config.preferAgentBrowser) {
|
|
126
|
-
// Will attempt to create agent-browser client on demand
|
|
74
|
+
if (this.config.preferAgentBrowser)
|
|
127
75
|
return true;
|
|
128
|
-
|
|
129
|
-
// Legacy Vibium path - check feature flags
|
|
130
|
-
if (!isBrowserModeEnabled()) {
|
|
76
|
+
if (!isBrowserModeEnabled())
|
|
131
77
|
return false;
|
|
132
|
-
|
|
133
|
-
// Check if axe-core is enabled for accessibility testing
|
|
134
|
-
if (!isAxeCoreEnabled()) {
|
|
78
|
+
if (!isAxeCoreEnabled())
|
|
135
79
|
return false;
|
|
136
|
-
|
|
137
|
-
// Check if Vibium client is available
|
|
138
|
-
if (!this.vibiumClient) {
|
|
80
|
+
if (!this.vibiumClient)
|
|
139
81
|
return false;
|
|
140
|
-
}
|
|
141
82
|
return true;
|
|
142
83
|
}
|
|
143
|
-
/**
|
|
144
|
-
* Get or create a browser client for accessibility testing
|
|
145
|
-
* Prefers agent-browser, falls back to Vibium
|
|
146
|
-
*
|
|
147
|
-
* @returns Browser client or null if unavailable
|
|
148
|
-
*/
|
|
149
84
|
async getBrowserClient() {
|
|
150
|
-
|
|
151
|
-
if (this.browserClient) {
|
|
85
|
+
if (this.browserClient)
|
|
152
86
|
return this.browserClient;
|
|
153
|
-
|
|
154
|
-
// Use already-created managed client
|
|
155
|
-
if (this.managedBrowserClient) {
|
|
87
|
+
if (this.managedBrowserClient)
|
|
156
88
|
return this.managedBrowserClient;
|
|
157
|
-
}
|
|
158
|
-
// Try to create a browser client via factory
|
|
159
89
|
if (this.config.preferAgentBrowser) {
|
|
160
90
|
try {
|
|
161
91
|
const client = await getBrowserClientForUseCase('accessibility');
|
|
@@ -166,432 +96,73 @@ export class AccessibilityTesterService {
|
|
|
166
96
|
}
|
|
167
97
|
}
|
|
168
98
|
catch (error) {
|
|
169
|
-
// Non-critical: browser client acquisition failed, using Vibium
|
|
170
99
|
console.debug('[AccessibilityTester] Browser client error:', error instanceof Error ? error.message : error);
|
|
171
100
|
}
|
|
172
101
|
}
|
|
173
|
-
// Fall back to Vibium (return null, Vibium methods will be used)
|
|
174
102
|
return null;
|
|
175
103
|
}
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
isAgentBrowserClient(client) {
|
|
180
|
-
return client.tool === 'agent-browser' && 'getSnapshot' in client;
|
|
181
|
-
}
|
|
182
|
-
/**
|
|
183
|
-
* Run full accessibility audit
|
|
184
|
-
*
|
|
185
|
-
* Priority order for browser-based testing:
|
|
186
|
-
* 1. agent-browser (if preferAgentBrowser is true and available)
|
|
187
|
-
* 2. Vibium (if available and enabled via feature flags)
|
|
188
|
-
* 3. Heuristic mode (URL pattern analysis)
|
|
189
|
-
*
|
|
190
|
-
* @param url - URL to audit
|
|
191
|
-
* @param options - Audit configuration options
|
|
192
|
-
* @returns AccessibilityReport with violations, passes, and score
|
|
193
|
-
*/
|
|
104
|
+
// ============================================================================
|
|
105
|
+
// Core Audit Methods
|
|
106
|
+
// ============================================================================
|
|
194
107
|
async audit(url, options) {
|
|
195
108
|
try {
|
|
196
109
|
const wcagLevel = options?.wcagLevel || this.config.defaultWCAGLevel;
|
|
197
|
-
// Try browser-based audit if available
|
|
198
110
|
if (this.shouldUseBrowserMode()) {
|
|
199
|
-
// First, try agent-browser if available
|
|
200
111
|
const browserClient = await this.getBrowserClient();
|
|
201
112
|
if (browserClient) {
|
|
202
|
-
const browserResult = await
|
|
113
|
+
const browserResult = await auditWithBrowserClient(browserClient, url, wcagLevel, this.config.browserConfig, options);
|
|
203
114
|
if (browserResult.success) {
|
|
204
115
|
await this.storeReport(browserResult.value);
|
|
205
116
|
return browserResult;
|
|
206
117
|
}
|
|
207
|
-
const errorMsg =
|
|
118
|
+
const errorMsg = getErrorMessage(browserResult);
|
|
208
119
|
console.warn(`Browser client audit failed: ${errorMsg}`);
|
|
209
120
|
}
|
|
210
|
-
// Fall back to Vibium if available
|
|
211
121
|
if (this.vibiumClient && isBrowserModeEnabled() && isAxeCoreEnabled()) {
|
|
212
|
-
const vibiumResult = await this.
|
|
122
|
+
const vibiumResult = await auditWithVibium(this.vibiumClient, url, wcagLevel, this.config.browserConfig, options);
|
|
213
123
|
if (vibiumResult.success) {
|
|
214
124
|
await this.storeReport(vibiumResult.value);
|
|
215
125
|
return vibiumResult;
|
|
216
126
|
}
|
|
217
|
-
const errorMsg =
|
|
127
|
+
const errorMsg = getErrorMessage(vibiumResult);
|
|
218
128
|
console.warn(`Vibium audit failed, falling back to heuristic mode: ${errorMsg}`);
|
|
219
129
|
}
|
|
220
130
|
}
|
|
221
|
-
// Use heuristic-based audit
|
|
222
131
|
return this.auditWithHeuristics(url, wcagLevel, options);
|
|
223
132
|
}
|
|
224
133
|
catch (error) {
|
|
225
|
-
return err(
|
|
134
|
+
return err(toError(error));
|
|
226
135
|
}
|
|
227
136
|
}
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
*
|
|
235
|
-
* @param client - Browser client instance
|
|
236
|
-
* @param url - URL to audit
|
|
237
|
-
* @param wcagLevel - WCAG conformance level
|
|
238
|
-
* @param options - Audit options
|
|
239
|
-
* @returns AccessibilityReport from browser-based axe-core audit
|
|
240
|
-
*/
|
|
241
|
-
async auditWithBrowserClient(client, url, wcagLevel, options) {
|
|
242
|
-
try {
|
|
243
|
-
// Launch browser
|
|
244
|
-
const launchResult = await client.launch({
|
|
245
|
-
headless: this.config.browserConfig.headless,
|
|
246
|
-
});
|
|
247
|
-
if (!launchResult.success) {
|
|
248
|
-
return err(new Error(`Failed to launch browser: ${launchResult.error?.message ?? 'Unknown error'}`));
|
|
249
|
-
}
|
|
250
|
-
try {
|
|
251
|
-
// Navigate to URL
|
|
252
|
-
const navResult = await client.navigate(url);
|
|
253
|
-
if (!navResult.success) {
|
|
254
|
-
return err(new Error(`Failed to navigate to ${url}: ${navResult.error?.message ?? 'Unknown error'}`));
|
|
255
|
-
}
|
|
256
|
-
// For agent-browser, get snapshot for element context
|
|
257
|
-
if (this.isAgentBrowserClient(client)) {
|
|
258
|
-
const snapshotResult = await client.getSnapshot({ interactive: true });
|
|
259
|
-
if (snapshotResult.success) {
|
|
260
|
-
// Snapshot provides element refs that can be used for targeted testing
|
|
261
|
-
// Log element count for debugging
|
|
262
|
-
const elementCount = snapshotResult.value.interactiveElements.length;
|
|
263
|
-
console.debug(`[AccessibilityTester] Found ${elementCount} interactive elements`);
|
|
264
|
-
}
|
|
265
|
-
}
|
|
266
|
-
// Inject and run axe-core
|
|
267
|
-
const axeResult = await this.runAxeCore(client, wcagLevel, options);
|
|
268
|
-
if (!axeResult.success) {
|
|
269
|
-
return err(axeResult.error);
|
|
270
|
-
}
|
|
271
|
-
// Map axe-core result to AccessibilityReport
|
|
272
|
-
const report = this.mapAxeResultToReport(url, axeResult.value, wcagLevel);
|
|
273
|
-
return ok(report);
|
|
274
|
-
}
|
|
275
|
-
finally {
|
|
276
|
-
// Always clean up browser
|
|
277
|
-
await client.quit();
|
|
137
|
+
async auditElement(url, selector) {
|
|
138
|
+
if (this.shouldUseBrowserMode() && this.vibiumClient) {
|
|
139
|
+
const browserResult = await auditElementWithVibium(this.vibiumClient, url, selector, this.config.defaultWCAGLevel, this.config.browserConfig);
|
|
140
|
+
if (browserResult.success) {
|
|
141
|
+
await this.storeReport(browserResult.value);
|
|
142
|
+
return browserResult;
|
|
278
143
|
}
|
|
144
|
+
const errorMsg = getErrorMessage(browserResult);
|
|
145
|
+
console.warn(`Browser mode element audit failed, falling back to heuristic mode: ${errorMsg}`);
|
|
279
146
|
}
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
}
|
|
284
|
-
/**
|
|
285
|
-
* Inject and run axe-core in the browser context
|
|
286
|
-
*
|
|
287
|
-
* @param client - Browser client
|
|
288
|
-
* @param wcagLevel - WCAG conformance level
|
|
289
|
-
* @param options - Audit options
|
|
290
|
-
* @returns Axe-core results
|
|
291
|
-
*/
|
|
292
|
-
async runAxeCore(client, wcagLevel, options) {
|
|
293
|
-
// Build axe-core configuration based on WCAG level
|
|
294
|
-
const tags = this.getAxeTagsForWcagLevel(wcagLevel);
|
|
295
|
-
const excludeSelectors = options?.excludeSelectors ?? [];
|
|
296
|
-
// Inject axe-core and run accessibility checks
|
|
297
|
-
const axeScript = `
|
|
298
|
-
(async function() {
|
|
299
|
-
// Check if axe is already loaded
|
|
300
|
-
if (typeof axe === 'undefined') {
|
|
301
|
-
// Inject axe-core from CDN
|
|
302
|
-
const script = document.createElement('script');
|
|
303
|
-
script.src = 'https://cdnjs.cloudflare.com/ajax/libs/axe-core/4.8.4/axe.min.js';
|
|
304
|
-
script.crossOrigin = 'anonymous';
|
|
305
|
-
document.head.appendChild(script);
|
|
306
|
-
|
|
307
|
-
// Wait for script to load
|
|
308
|
-
await new Promise((resolve, reject) => {
|
|
309
|
-
script.onload = resolve;
|
|
310
|
-
script.onerror = () => reject(new Error('Failed to load axe-core'));
|
|
311
|
-
setTimeout(() => reject(new Error('Timeout loading axe-core')), 10000);
|
|
312
|
-
});
|
|
313
|
-
}
|
|
314
|
-
|
|
315
|
-
// Configure and run axe
|
|
316
|
-
const config = {
|
|
317
|
-
runOnly: {
|
|
318
|
-
type: 'tag',
|
|
319
|
-
values: ${JSON.stringify(tags)}
|
|
320
|
-
},
|
|
321
|
-
exclude: ${JSON.stringify(excludeSelectors.map(s => [s]))}
|
|
322
|
-
};
|
|
323
|
-
|
|
324
|
-
const results = await axe.run(document, config);
|
|
325
|
-
|
|
326
|
-
return JSON.stringify({
|
|
327
|
-
violations: results.violations.map(v => ({
|
|
328
|
-
id: v.id,
|
|
329
|
-
impact: v.impact,
|
|
330
|
-
description: v.description,
|
|
331
|
-
help: v.help,
|
|
332
|
-
helpUrl: v.helpUrl,
|
|
333
|
-
tags: v.tags,
|
|
334
|
-
nodes: v.nodes.map(n => ({
|
|
335
|
-
selector: n.target.join(' > '),
|
|
336
|
-
html: n.html,
|
|
337
|
-
target: n.target,
|
|
338
|
-
failureSummary: n.failureSummary
|
|
339
|
-
}))
|
|
340
|
-
})),
|
|
341
|
-
passes: results.passes.map(p => p.id),
|
|
342
|
-
incomplete: results.incomplete.map(i => i.id),
|
|
343
|
-
inapplicable: results.inapplicable.map(i => i.id)
|
|
147
|
+
return this.audit(url, {
|
|
148
|
+
excludeSelectors: [],
|
|
149
|
+
wcagLevel: this.config.defaultWCAGLevel,
|
|
344
150
|
});
|
|
345
|
-
})();
|
|
346
|
-
`;
|
|
347
|
-
const evalResult = await client.evaluate(axeScript);
|
|
348
|
-
if (!evalResult.success) {
|
|
349
|
-
return err(new Error(`Failed to run axe-core: ${evalResult.error?.message ?? 'Unknown error'}`));
|
|
350
|
-
}
|
|
351
|
-
try {
|
|
352
|
-
const parsed = JSON.parse(evalResult.value);
|
|
353
|
-
return ok(parsed);
|
|
354
|
-
}
|
|
355
|
-
catch (parseError) {
|
|
356
|
-
return err(new Error(`Failed to parse axe-core results: ${parseError}`));
|
|
357
|
-
}
|
|
358
|
-
}
|
|
359
|
-
/**
|
|
360
|
-
* Get axe-core tags for a WCAG conformance level
|
|
361
|
-
*/
|
|
362
|
-
getAxeTagsForWcagLevel(level) {
|
|
363
|
-
const baseTags = ['wcag2a', 'wcag21a', 'wcag22a', 'best-practice'];
|
|
364
|
-
if (level === 'A') {
|
|
365
|
-
return baseTags;
|
|
366
|
-
}
|
|
367
|
-
const aaTags = [...baseTags, 'wcag2aa', 'wcag21aa', 'wcag22aa'];
|
|
368
|
-
if (level === 'AA') {
|
|
369
|
-
return aaTags;
|
|
370
|
-
}
|
|
371
|
-
// AAA includes everything
|
|
372
|
-
return [...aaTags, 'wcag2aaa', 'wcag21aaa', 'wcag22aaa'];
|
|
373
|
-
}
|
|
374
|
-
/**
|
|
375
|
-
* Map axe-core result to AccessibilityReport
|
|
376
|
-
*/
|
|
377
|
-
mapAxeResultToReport(url, axeResult, wcagLevel) {
|
|
378
|
-
// Map violations
|
|
379
|
-
const violations = axeResult.violations.map(v => ({
|
|
380
|
-
id: v.id,
|
|
381
|
-
impact: this.mapImpactSeverity(v.impact ?? 'moderate'),
|
|
382
|
-
wcagCriteria: this.extractWcagCriteria(v.tags ?? [], wcagLevel),
|
|
383
|
-
description: v.description,
|
|
384
|
-
help: v.help,
|
|
385
|
-
helpUrl: v.helpUrl ?? `https://dequeuniversity.com/rules/axe/4.8/${v.id}`,
|
|
386
|
-
nodes: v.nodes.map(n => ({
|
|
387
|
-
selector: n.selector,
|
|
388
|
-
html: n.html,
|
|
389
|
-
target: n.target,
|
|
390
|
-
failureSummary: n.failureSummary ?? '',
|
|
391
|
-
})),
|
|
392
|
-
}));
|
|
393
|
-
// Map passed rules
|
|
394
|
-
const passes = axeResult.passes.map(ruleId => ({
|
|
395
|
-
id: ruleId,
|
|
396
|
-
description: `Rule ${ruleId} passed`,
|
|
397
|
-
nodes: 0,
|
|
398
|
-
}));
|
|
399
|
-
// Map incomplete checks
|
|
400
|
-
const incomplete = axeResult.incomplete.map(ruleId => ({
|
|
401
|
-
id: ruleId,
|
|
402
|
-
description: `Rule ${ruleId} requires manual review`,
|
|
403
|
-
reason: 'Could not automatically determine compliance',
|
|
404
|
-
nodes: [],
|
|
405
|
-
}));
|
|
406
|
-
// Calculate score
|
|
407
|
-
const totalRules = violations.length + passes.length + incomplete.length;
|
|
408
|
-
const failedWeight = violations.reduce((sum, v) => {
|
|
409
|
-
const weights = { critical: 4, serious: 3, moderate: 2, minor: 1 };
|
|
410
|
-
return sum + weights[v.impact];
|
|
411
|
-
}, 0);
|
|
412
|
-
const maxWeight = totalRules * 4;
|
|
413
|
-
const score = totalRules > 0
|
|
414
|
-
? Math.round(((maxWeight - failedWeight) / maxWeight) * 100)
|
|
415
|
-
: 100;
|
|
416
|
-
return {
|
|
417
|
-
url,
|
|
418
|
-
timestamp: new Date(),
|
|
419
|
-
violations,
|
|
420
|
-
passes,
|
|
421
|
-
incomplete,
|
|
422
|
-
score: Math.max(0, Math.min(100, score)),
|
|
423
|
-
wcagLevel,
|
|
424
|
-
};
|
|
425
|
-
}
|
|
426
|
-
/**
|
|
427
|
-
* Extract WCAG criteria from axe-core tags
|
|
428
|
-
*/
|
|
429
|
-
extractWcagCriteria(tags, defaultLevel) {
|
|
430
|
-
const criteria = [];
|
|
431
|
-
for (const tag of tags) {
|
|
432
|
-
// Match patterns like wcag111, wcag2111
|
|
433
|
-
const match = tag.match(/^wcag(\d)(\d)(\d)(\d)?$/);
|
|
434
|
-
if (match) {
|
|
435
|
-
const id = match[4]
|
|
436
|
-
? `${match[1]}.${match[2]}.${match[3]}${match[4]}`
|
|
437
|
-
: `${match[1]}.${match[2]}.${match[3]}`;
|
|
438
|
-
const existing = WCAG_CRITERIA[id];
|
|
439
|
-
if (existing) {
|
|
440
|
-
criteria.push(existing);
|
|
441
|
-
}
|
|
442
|
-
else {
|
|
443
|
-
criteria.push({
|
|
444
|
-
id,
|
|
445
|
-
level: defaultLevel,
|
|
446
|
-
title: `WCAG ${id}`,
|
|
447
|
-
});
|
|
448
|
-
}
|
|
449
|
-
}
|
|
450
|
-
}
|
|
451
|
-
return criteria;
|
|
452
151
|
}
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
* @param url - URL to audit
|
|
457
|
-
* @param wcagLevel - WCAG conformance level
|
|
458
|
-
* @param options - Audit options
|
|
459
|
-
* @returns AccessibilityReport from browser-based axe-core audit
|
|
460
|
-
*/
|
|
461
|
-
async auditWithBrowser(url, wcagLevel, options) {
|
|
462
|
-
if (!this.vibiumClient) {
|
|
463
|
-
return err(new Error('Vibium client not available'));
|
|
464
|
-
}
|
|
465
|
-
try {
|
|
466
|
-
// Launch browser
|
|
467
|
-
const launchResult = await this.vibiumClient.launch({
|
|
468
|
-
headless: this.config.browserConfig.headless,
|
|
469
|
-
});
|
|
470
|
-
if (!launchResult.success) {
|
|
471
|
-
return err(new Error(`Failed to launch browser: ${this.getErrorMessage(launchResult)}`));
|
|
472
|
-
}
|
|
473
|
-
try {
|
|
474
|
-
// Navigate to URL
|
|
475
|
-
const navResult = await this.vibiumClient.navigate({
|
|
476
|
-
url,
|
|
477
|
-
waitUntil: 'networkidle',
|
|
478
|
-
timeout: this.config.browserConfig.timeout,
|
|
479
|
-
});
|
|
480
|
-
if (!navResult.success) {
|
|
481
|
-
return err(new Error(`Failed to navigate to ${url}: ${this.getErrorMessage(navResult)}`));
|
|
482
|
-
}
|
|
483
|
-
// Run accessibility checks via Vibium
|
|
484
|
-
const a11yResult = await this.vibiumClient.checkAccessibility({
|
|
485
|
-
wcagLevel,
|
|
486
|
-
selector: options?.excludeSelectors?.[0], // Use first exclude selector if provided
|
|
487
|
-
});
|
|
488
|
-
if (!a11yResult.success) {
|
|
489
|
-
return err(new Error(`Accessibility check failed: ${this.getErrorMessage(a11yResult)}`));
|
|
490
|
-
}
|
|
491
|
-
// Map Vibium result to AccessibilityReport
|
|
492
|
-
const report = this.mapVibiumResultToReport(url, a11yResult.value, wcagLevel);
|
|
493
|
-
return ok(report);
|
|
494
|
-
}
|
|
495
|
-
finally {
|
|
496
|
-
// Always clean up browser
|
|
497
|
-
await this.vibiumClient.quit();
|
|
498
|
-
}
|
|
499
|
-
}
|
|
500
|
-
catch (error) {
|
|
501
|
-
return err(error instanceof Error ? error : new Error(String(error)));
|
|
502
|
-
}
|
|
503
|
-
}
|
|
504
|
-
/**
|
|
505
|
-
* Map Vibium accessibility result to our AccessibilityReport format
|
|
506
|
-
*/
|
|
507
|
-
mapVibiumResultToReport(url, vibiumResult, wcagLevel) {
|
|
508
|
-
// Map violations from Vibium format to our format
|
|
509
|
-
const violations = vibiumResult.violations.map((v) => ({
|
|
510
|
-
id: v.id,
|
|
511
|
-
impact: this.mapImpactSeverity(v.impact),
|
|
512
|
-
wcagCriteria: v.wcagCriterion
|
|
513
|
-
? [{ id: v.wcagCriterion, level: wcagLevel, title: v.rule }]
|
|
514
|
-
: [],
|
|
515
|
-
description: v.description,
|
|
516
|
-
help: v.help,
|
|
517
|
-
helpUrl: v.helpUrl ?? `https://www.w3.org/WAI/WCAG22/Understanding/`,
|
|
518
|
-
nodes: v.nodes.map((n) => ({
|
|
519
|
-
selector: n.selector,
|
|
520
|
-
html: n.html,
|
|
521
|
-
target: n.target,
|
|
522
|
-
failureSummary: n.failureSummary,
|
|
523
|
-
})),
|
|
524
|
-
}));
|
|
525
|
-
// Map passed rules
|
|
526
|
-
const passes = vibiumResult.passedRules.map((ruleId) => ({
|
|
527
|
-
id: ruleId,
|
|
528
|
-
description: `Rule ${ruleId} passed`,
|
|
529
|
-
nodes: 0, // Vibium doesn't provide node count for passed rules
|
|
530
|
-
}));
|
|
531
|
-
// Map incomplete checks
|
|
532
|
-
const incomplete = vibiumResult.incompleteRules.map((ruleId) => ({
|
|
533
|
-
id: ruleId,
|
|
534
|
-
description: `Rule ${ruleId} requires manual review`,
|
|
535
|
-
reason: 'Could not automatically determine compliance',
|
|
536
|
-
nodes: [],
|
|
537
|
-
}));
|
|
538
|
-
// Calculate score from violation severity weights
|
|
539
|
-
const totalRules = violations.length + passes.length + incomplete.length;
|
|
540
|
-
const failedWeight = violations.reduce((sum, v) => {
|
|
541
|
-
const weights = { critical: 4, serious: 3, moderate: 2, minor: 1 };
|
|
542
|
-
return sum + weights[v.impact];
|
|
543
|
-
}, 0);
|
|
544
|
-
const maxWeight = totalRules * 4; // Assume worst case all critical
|
|
545
|
-
const score = totalRules > 0
|
|
546
|
-
? Math.round(((maxWeight - failedWeight) / maxWeight) * 100)
|
|
547
|
-
: 100;
|
|
548
|
-
return {
|
|
549
|
-
url,
|
|
550
|
-
timestamp: new Date(),
|
|
551
|
-
violations,
|
|
552
|
-
passes,
|
|
553
|
-
incomplete,
|
|
554
|
-
score: Math.max(0, Math.min(100, score)),
|
|
555
|
-
wcagLevel,
|
|
556
|
-
};
|
|
557
|
-
}
|
|
558
|
-
/**
|
|
559
|
-
* Map Vibium Severity type to our impact type
|
|
560
|
-
*/
|
|
561
|
-
mapImpactSeverity(severity) {
|
|
562
|
-
const severityMap = {
|
|
563
|
-
critical: 'critical',
|
|
564
|
-
high: 'serious',
|
|
565
|
-
medium: 'moderate',
|
|
566
|
-
low: 'minor',
|
|
567
|
-
info: 'minor',
|
|
568
|
-
};
|
|
569
|
-
return severityMap[severity] ?? 'moderate';
|
|
570
|
-
}
|
|
571
|
-
/**
|
|
572
|
-
* Run accessibility audit using heuristic-based URL pattern analysis
|
|
573
|
-
*
|
|
574
|
-
* This is the fallback mode when browser automation is not available.
|
|
575
|
-
*
|
|
576
|
-
* @param url - URL to audit
|
|
577
|
-
* @param wcagLevel - WCAG conformance level
|
|
578
|
-
* @param options - Audit options
|
|
579
|
-
* @returns AccessibilityReport from heuristic analysis
|
|
580
|
-
*/
|
|
152
|
+
// ============================================================================
|
|
153
|
+
// Heuristic Audit
|
|
154
|
+
// ============================================================================
|
|
581
155
|
async auditWithHeuristics(url, wcagLevel, options) {
|
|
582
156
|
try {
|
|
583
157
|
const includeWarnings = options?.includeWarnings ?? this.config.includeWarnings;
|
|
584
|
-
// Filter rules based on WCAG level and warning preference
|
|
585
158
|
const applicableRules = includeWarnings
|
|
586
|
-
? this.
|
|
587
|
-
: this.
|
|
588
|
-
// Run each rule against the URL context
|
|
589
|
-
// Note: Without browser automation, rules use heuristic-based checks
|
|
159
|
+
? filterRulesByLevel(this.rules, wcagLevel)
|
|
160
|
+
: filterRulesByLevel(this.rules, wcagLevel).filter(r => r.impact !== 'minor');
|
|
590
161
|
const violations = [];
|
|
591
162
|
const passes = [];
|
|
592
163
|
const incomplete = [];
|
|
593
164
|
for (const rule of applicableRules) {
|
|
594
|
-
const result =
|
|
165
|
+
const result = runRule(rule, { url }, this.config.simulationMode, this.config.enableColorContrastCheck);
|
|
595
166
|
if (result.nodes.length > 0) {
|
|
596
167
|
violations.push({
|
|
597
168
|
id: rule.id,
|
|
@@ -619,7 +190,6 @@ export class AccessibilityTesterService {
|
|
|
619
190
|
});
|
|
620
191
|
}
|
|
621
192
|
}
|
|
622
|
-
// Calculate score (0-100)
|
|
623
193
|
const totalChecks = applicableRules.length;
|
|
624
194
|
const failedChecks = violations.length;
|
|
625
195
|
const score = Math.round(((totalChecks - failedChecks) / totalChecks) * 100);
|
|
@@ -632,247 +202,58 @@ export class AccessibilityTesterService {
|
|
|
632
202
|
score,
|
|
633
203
|
wcagLevel,
|
|
634
204
|
};
|
|
635
|
-
// Store report
|
|
636
205
|
await this.storeReport(report);
|
|
637
206
|
return ok(report);
|
|
638
207
|
}
|
|
639
208
|
catch (error) {
|
|
640
|
-
return err(
|
|
209
|
+
return err(toError(error));
|
|
641
210
|
}
|
|
642
211
|
}
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
* In browser mode, uses Vibium to audit a specific element.
|
|
647
|
-
* In heuristic mode, runs a full page audit.
|
|
648
|
-
*
|
|
649
|
-
* @param url - URL containing the element
|
|
650
|
-
* @param selector - CSS selector for the element to audit
|
|
651
|
-
* @returns AccessibilityReport for the specified element
|
|
652
|
-
*/
|
|
653
|
-
async auditElement(url, selector) {
|
|
654
|
-
// Try browser-based element audit if available
|
|
655
|
-
if (this.shouldUseBrowserMode()) {
|
|
656
|
-
const browserResult = await this.auditElementWithBrowser(url, selector);
|
|
657
|
-
if (browserResult.success) {
|
|
658
|
-
await this.storeReport(browserResult.value);
|
|
659
|
-
return browserResult;
|
|
660
|
-
}
|
|
661
|
-
// Fall back to heuristic mode
|
|
662
|
-
const errorMsg = this.getErrorMessage(browserResult);
|
|
663
|
-
console.warn(`Browser mode element audit failed, falling back to heuristic mode: ${errorMsg}`);
|
|
664
|
-
}
|
|
665
|
-
// For heuristic mode, we run a full page audit
|
|
666
|
-
// Selector is reserved for future element-specific heuristic auditing
|
|
667
|
-
return this.audit(url, {
|
|
668
|
-
excludeSelectors: [],
|
|
669
|
-
wcagLevel: this.config.defaultWCAGLevel,
|
|
670
|
-
});
|
|
671
|
-
}
|
|
672
|
-
/**
|
|
673
|
-
* Audit specific element using browser via Vibium
|
|
674
|
-
*/
|
|
675
|
-
async auditElementWithBrowser(url, selector) {
|
|
676
|
-
if (!this.vibiumClient) {
|
|
677
|
-
return err(new Error('Vibium client not available'));
|
|
678
|
-
}
|
|
679
|
-
try {
|
|
680
|
-
// Launch browser
|
|
681
|
-
const launchResult = await this.vibiumClient.launch({
|
|
682
|
-
headless: this.config.browserConfig.headless,
|
|
683
|
-
});
|
|
684
|
-
if (!launchResult.success) {
|
|
685
|
-
return err(new Error(`Failed to launch browser: ${this.getErrorMessage(launchResult)}`));
|
|
686
|
-
}
|
|
687
|
-
try {
|
|
688
|
-
// Navigate to URL
|
|
689
|
-
const navResult = await this.vibiumClient.navigate({
|
|
690
|
-
url,
|
|
691
|
-
waitUntil: 'networkidle',
|
|
692
|
-
timeout: this.config.browserConfig.timeout,
|
|
693
|
-
});
|
|
694
|
-
if (!navResult.success) {
|
|
695
|
-
return err(new Error(`Failed to navigate to ${url}: ${this.getErrorMessage(navResult)}`));
|
|
696
|
-
}
|
|
697
|
-
// Run accessibility checks on specific element via Vibium
|
|
698
|
-
const a11yResult = await this.vibiumClient.checkAccessibility({
|
|
699
|
-
wcagLevel: this.config.defaultWCAGLevel,
|
|
700
|
-
selector, // Target specific element
|
|
701
|
-
});
|
|
702
|
-
if (!a11yResult.success) {
|
|
703
|
-
return err(new Error(`Element accessibility check failed: ${this.getErrorMessage(a11yResult)}`));
|
|
704
|
-
}
|
|
705
|
-
// Map Vibium result to AccessibilityReport
|
|
706
|
-
const report = this.mapVibiumResultToReport(url, a11yResult.value, this.config.defaultWCAGLevel);
|
|
707
|
-
return ok(report);
|
|
708
|
-
}
|
|
709
|
-
finally {
|
|
710
|
-
// Always clean up browser
|
|
711
|
-
await this.vibiumClient.quit();
|
|
712
|
-
}
|
|
713
|
-
}
|
|
714
|
-
catch (error) {
|
|
715
|
-
return err(error instanceof Error ? error : new Error(String(error)));
|
|
716
|
-
}
|
|
717
|
-
}
|
|
718
|
-
/**
|
|
719
|
-
* Check color contrast
|
|
720
|
-
* Analyzes common page elements for WCAG 2.2 contrast compliance
|
|
721
|
-
*
|
|
722
|
-
* In browser mode, uses Vibium to run actual axe-core color contrast checks.
|
|
723
|
-
* In heuristic mode, provides estimated contrast analysis based on URL patterns.
|
|
724
|
-
*
|
|
725
|
-
* @param url - URL to check
|
|
726
|
-
* @returns Array of ContrastAnalysis for page elements
|
|
727
|
-
*/
|
|
212
|
+
// ============================================================================
|
|
213
|
+
// Contrast Analysis
|
|
214
|
+
// ============================================================================
|
|
728
215
|
async checkContrast(url) {
|
|
729
216
|
try {
|
|
730
|
-
|
|
731
|
-
const cacheKey = `visual-accessibility:contrast:${this.hashUrl(url)}`;
|
|
217
|
+
const cacheKey = `visual-accessibility:contrast:${hashUrl(url)}`;
|
|
732
218
|
const cached = await this.memory.get(cacheKey);
|
|
733
|
-
if (cached)
|
|
219
|
+
if (cached)
|
|
734
220
|
return ok(cached);
|
|
735
|
-
}
|
|
736
221
|
let analyses;
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
const browserResult = await this.checkContrastWithBrowser(url);
|
|
222
|
+
if (this.shouldUseBrowserMode() && this.vibiumClient) {
|
|
223
|
+
const browserResult = await checkContrastWithVibium(this.vibiumClient, url, this.config.defaultWCAGLevel, this.config.browserConfig);
|
|
740
224
|
if (browserResult.success) {
|
|
741
225
|
analyses = browserResult.value;
|
|
742
226
|
}
|
|
743
227
|
else {
|
|
744
|
-
|
|
745
|
-
const errorMsg = this.getErrorMessage(browserResult);
|
|
228
|
+
const errorMsg = getErrorMessage(browserResult);
|
|
746
229
|
console.warn(`Browser mode contrast check failed, falling back to heuristic mode: ${errorMsg}`);
|
|
747
|
-
analyses =
|
|
230
|
+
analyses = analyzeContrastForElements(url);
|
|
748
231
|
}
|
|
749
232
|
}
|
|
750
233
|
else {
|
|
751
|
-
|
|
752
|
-
analyses = this.analyzeContrastForElements(url);
|
|
234
|
+
analyses = analyzeContrastForElements(url);
|
|
753
235
|
}
|
|
754
|
-
|
|
755
|
-
await this.memory.set(cacheKey, analyses, {
|
|
756
|
-
namespace: 'visual-accessibility',
|
|
757
|
-
ttl: 3600,
|
|
758
|
-
});
|
|
236
|
+
await this.memory.set(cacheKey, analyses, { namespace: 'visual-accessibility', ttl: 3600 });
|
|
759
237
|
return ok(analyses);
|
|
760
238
|
}
|
|
761
239
|
catch (error) {
|
|
762
|
-
return err(
|
|
240
|
+
return err(toError(error));
|
|
763
241
|
}
|
|
764
242
|
}
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
* Runs axe-core color contrast checks against the actual rendered page
|
|
769
|
-
* to get accurate foreground/background color values and ratios.
|
|
770
|
-
*/
|
|
771
|
-
async checkContrastWithBrowser(url) {
|
|
772
|
-
if (!this.vibiumClient) {
|
|
773
|
-
return err(new Error('Vibium client not available'));
|
|
774
|
-
}
|
|
775
|
-
try {
|
|
776
|
-
// Launch browser
|
|
777
|
-
const launchResult = await this.vibiumClient.launch({
|
|
778
|
-
headless: this.config.browserConfig.headless,
|
|
779
|
-
});
|
|
780
|
-
if (!launchResult.success) {
|
|
781
|
-
return err(new Error(`Failed to launch browser: ${this.getErrorMessage(launchResult)}`));
|
|
782
|
-
}
|
|
783
|
-
try {
|
|
784
|
-
// Navigate to URL
|
|
785
|
-
const navResult = await this.vibiumClient.navigate({
|
|
786
|
-
url,
|
|
787
|
-
waitUntil: 'networkidle',
|
|
788
|
-
timeout: this.config.browserConfig.timeout,
|
|
789
|
-
});
|
|
790
|
-
if (!navResult.success) {
|
|
791
|
-
return err(new Error(`Failed to navigate to ${url}: ${this.getErrorMessage(navResult)}`));
|
|
792
|
-
}
|
|
793
|
-
// Run accessibility checks - focus on color-contrast rules
|
|
794
|
-
const a11yResult = await this.vibiumClient.checkAccessibility({
|
|
795
|
-
wcagLevel: this.config.defaultWCAGLevel,
|
|
796
|
-
rules: {
|
|
797
|
-
include: ['color-contrast'],
|
|
798
|
-
},
|
|
799
|
-
});
|
|
800
|
-
if (!a11yResult.success) {
|
|
801
|
-
return err(new Error(`Contrast check failed: ${this.getErrorMessage(a11yResult)}`));
|
|
802
|
-
}
|
|
803
|
-
// Extract contrast analysis from violations
|
|
804
|
-
const analyses = this.extractContrastFromVibiumResult(a11yResult.value);
|
|
805
|
-
return ok(analyses);
|
|
806
|
-
}
|
|
807
|
-
finally {
|
|
808
|
-
// Always clean up browser
|
|
809
|
-
await this.vibiumClient.quit();
|
|
810
|
-
}
|
|
811
|
-
}
|
|
812
|
-
catch (error) {
|
|
813
|
-
return err(error instanceof Error ? error : new Error(String(error)));
|
|
814
|
-
}
|
|
815
|
-
}
|
|
816
|
-
/**
|
|
817
|
-
* Extract contrast analysis from Vibium accessibility result
|
|
818
|
-
*/
|
|
819
|
-
extractContrastFromVibiumResult(vibiumResult) {
|
|
820
|
-
const analyses = [];
|
|
821
|
-
// Process contrast violations
|
|
822
|
-
for (const violation of vibiumResult.violations) {
|
|
823
|
-
if (violation.rule.includes('contrast') || violation.id.includes('contrast')) {
|
|
824
|
-
for (const node of violation.nodes) {
|
|
825
|
-
// Extract colors from failure summary if available
|
|
826
|
-
const colorMatch = node.failureSummary.match(/foreground:?\s*([#\w\d]+).*?background:?\s*([#\w\d]+)/i);
|
|
827
|
-
const ratioMatch = node.failureSummary.match(/ratio\s*[:\s]*(\d+\.?\d*)/i);
|
|
828
|
-
analyses.push({
|
|
829
|
-
element: node.selector,
|
|
830
|
-
foreground: colorMatch?.[1] || '#000000',
|
|
831
|
-
background: colorMatch?.[2] || '#ffffff',
|
|
832
|
-
ratio: ratioMatch ? parseFloat(ratioMatch[1]) : 1.0,
|
|
833
|
-
requiredRatio: this.config.defaultWCAGLevel === 'AAA' ? 7 : 4.5,
|
|
834
|
-
passes: false,
|
|
835
|
-
wcagLevel: this.config.defaultWCAGLevel,
|
|
836
|
-
});
|
|
837
|
-
}
|
|
838
|
-
}
|
|
839
|
-
}
|
|
840
|
-
// If no violations, add passing analyses for common elements
|
|
841
|
-
if (analyses.length === 0 && vibiumResult.passedRules.some(r => r.includes('contrast'))) {
|
|
842
|
-
const commonElements = ['h1', 'p', 'a', 'button'];
|
|
843
|
-
for (const element of commonElements) {
|
|
844
|
-
analyses.push({
|
|
845
|
-
element,
|
|
846
|
-
foreground: '#333333',
|
|
847
|
-
background: '#ffffff',
|
|
848
|
-
ratio: 12.63, // High contrast ratio for passing
|
|
849
|
-
requiredRatio: this.config.defaultWCAGLevel === 'AAA' ? 7 : 4.5,
|
|
850
|
-
passes: true,
|
|
851
|
-
wcagLevel: this.config.defaultWCAGLevel,
|
|
852
|
-
});
|
|
853
|
-
}
|
|
854
|
-
}
|
|
855
|
-
return analyses;
|
|
856
|
-
}
|
|
857
|
-
/**
|
|
858
|
-
* Validate against specific WCAG level
|
|
859
|
-
* Evaluates page compliance with WCAG 2.2 success criteria
|
|
860
|
-
*/
|
|
243
|
+
// ============================================================================
|
|
244
|
+
// WCAG Validation
|
|
245
|
+
// ============================================================================
|
|
861
246
|
async validateWCAGLevel(url, level) {
|
|
862
247
|
try {
|
|
863
|
-
// Get applicable criteria for level
|
|
864
248
|
const levelOrder = { A: 1, AA: 2, AAA: 3 };
|
|
865
249
|
const targetLevel = levelOrder[level];
|
|
866
250
|
const applicableCriteria = Object.values(WCAG_CRITERIA).filter((c) => levelOrder[c.level] <= targetLevel);
|
|
867
|
-
// Run rule-based validation for each criterion
|
|
868
251
|
const failedCriteria = [];
|
|
869
252
|
const passedCriteria = [];
|
|
870
|
-
|
|
871
|
-
const urlHash = this.hashUrl(url);
|
|
253
|
+
const urlHash = hashUrl(url);
|
|
872
254
|
const hashNum = parseInt(urlHash, 36);
|
|
873
255
|
for (const criterion of applicableCriteria) {
|
|
874
|
-
|
|
875
|
-
const ruleResult = this.validateCriterion(criterion, hashNum);
|
|
256
|
+
const ruleResult = validateCriterion(criterion, hashNum);
|
|
876
257
|
if (ruleResult.passed) {
|
|
877
258
|
passedCriteria.push(criterion);
|
|
878
259
|
}
|
|
@@ -882,814 +263,56 @@ export class AccessibilityTesterService {
|
|
|
882
263
|
}
|
|
883
264
|
const passed = failedCriteria.length === 0;
|
|
884
265
|
const score = Math.round((passedCriteria.length / applicableCriteria.length) * 100);
|
|
885
|
-
return ok({
|
|
886
|
-
level,
|
|
887
|
-
passed,
|
|
888
|
-
failedCriteria,
|
|
889
|
-
passedCriteria,
|
|
890
|
-
score,
|
|
891
|
-
});
|
|
266
|
+
return ok({ level, passed, failedCriteria, passedCriteria, score });
|
|
892
267
|
}
|
|
893
268
|
catch (error) {
|
|
894
|
-
return err(
|
|
269
|
+
return err(toError(error));
|
|
895
270
|
}
|
|
896
271
|
}
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
validateCriterion(criterion, urlHash) {
|
|
901
|
-
// Define common failure scenarios based on criterion
|
|
902
|
-
const criterionFailureRates = {
|
|
903
|
-
'1.1.1': 0.12, // Non-text content - missing alt text common
|
|
904
|
-
'1.3.1': 0.08, // Info and relationships - heading structure issues
|
|
905
|
-
'1.4.1': 0.05, // Use of color - rare issue
|
|
906
|
-
'1.4.3': 0.15, // Contrast - very common issue
|
|
907
|
-
'1.4.6': 0.25, // Enhanced contrast - stricter, more failures
|
|
908
|
-
'2.1.1': 0.10, // Keyboard - mouse-only interactions
|
|
909
|
-
'2.1.2': 0.03, // No keyboard trap - uncommon but critical
|
|
910
|
-
'2.4.1': 0.08, // Bypass blocks - skip links often missing
|
|
911
|
-
'2.4.3': 0.06, // Focus order - usually correct
|
|
912
|
-
'2.4.4': 0.10, // Link purpose - generic link text
|
|
913
|
-
'2.4.7': 0.12, // Focus visible - custom styles hide focus
|
|
914
|
-
'3.1.1': 0.04, // Language of page - usually present
|
|
915
|
-
'4.1.1': 0.02, // Parsing - HTML validation
|
|
916
|
-
'4.1.2': 0.09, // Name, role, value - ARIA issues
|
|
917
|
-
};
|
|
918
|
-
const failureRate = criterionFailureRates[criterion.id] ?? 0.1;
|
|
919
|
-
// Use hash to determine pass/fail deterministically
|
|
920
|
-
// Different criterion IDs should produce different results
|
|
921
|
-
const criterionHashOffset = criterion.id.charCodeAt(0) * 100;
|
|
922
|
-
const determinant = ((urlHash + criterionHashOffset) % 100) / 100;
|
|
923
|
-
const passed = determinant >= failureRate;
|
|
924
|
-
return {
|
|
925
|
-
passed,
|
|
926
|
-
reason: passed ? undefined : `Criterion ${criterion.id} (${criterion.title}) not fully satisfied`,
|
|
927
|
-
};
|
|
928
|
-
}
|
|
929
|
-
/**
|
|
930
|
-
* Check keyboard navigation
|
|
931
|
-
* Analyzes focusable elements, tab order, and potential focus traps
|
|
932
|
-
*
|
|
933
|
-
* In browser mode, uses Vibium to inspect actual focusable elements.
|
|
934
|
-
* In heuristic mode, provides estimated analysis based on URL patterns.
|
|
935
|
-
*
|
|
936
|
-
* @param url - URL to check
|
|
937
|
-
* @returns KeyboardNavigationReport with tab order and issues
|
|
938
|
-
*/
|
|
272
|
+
// ============================================================================
|
|
273
|
+
// Keyboard Navigation
|
|
274
|
+
// ============================================================================
|
|
939
275
|
async checkKeyboardNavigation(url) {
|
|
940
276
|
try {
|
|
941
|
-
|
|
942
|
-
const cacheKey = `visual-accessibility:keyboard:${this.hashUrl(url)}`;
|
|
277
|
+
const cacheKey = `visual-accessibility:keyboard:${hashUrl(url)}`;
|
|
943
278
|
const cached = await this.memory.get(cacheKey);
|
|
944
|
-
if (cached)
|
|
279
|
+
if (cached)
|
|
945
280
|
return ok(cached);
|
|
946
|
-
}
|
|
947
281
|
let report;
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
const browserResult = await this.checkKeyboardWithBrowser(url);
|
|
282
|
+
if (this.shouldUseBrowserMode() && this.config.enableKeyboardCheck && this.vibiumClient) {
|
|
283
|
+
const browserResult = await checkKeyboardWithVibium(this.vibiumClient, url, this.config.defaultWCAGLevel, this.config.browserConfig);
|
|
951
284
|
if (browserResult.success) {
|
|
952
285
|
report = browserResult.value;
|
|
953
286
|
}
|
|
954
287
|
else {
|
|
955
|
-
|
|
956
|
-
const errorMsg = this.getErrorMessage(browserResult);
|
|
288
|
+
const errorMsg = getErrorMessage(browserResult);
|
|
957
289
|
console.warn(`Browser mode keyboard check failed, falling back to heuristic mode: ${errorMsg}`);
|
|
958
|
-
report =
|
|
290
|
+
report = generateKeyboardReportWithHeuristics(url);
|
|
959
291
|
}
|
|
960
292
|
}
|
|
961
293
|
else {
|
|
962
|
-
|
|
963
|
-
report = this.generateKeyboardReportWithHeuristics(url);
|
|
294
|
+
report = generateKeyboardReportWithHeuristics(url);
|
|
964
295
|
}
|
|
965
|
-
|
|
966
|
-
await this.memory.set(cacheKey, report, {
|
|
967
|
-
namespace: 'visual-accessibility',
|
|
968
|
-
ttl: 3600,
|
|
969
|
-
});
|
|
296
|
+
await this.memory.set(cacheKey, report, { namespace: 'visual-accessibility', ttl: 3600 });
|
|
970
297
|
return ok(report);
|
|
971
298
|
}
|
|
972
299
|
catch (error) {
|
|
973
|
-
return err(
|
|
300
|
+
return err(toError(error));
|
|
974
301
|
}
|
|
975
302
|
}
|
|
976
|
-
/**
|
|
977
|
-
* Generate keyboard navigation report using heuristics
|
|
978
|
-
*/
|
|
979
|
-
generateKeyboardReportWithHeuristics(url) {
|
|
980
|
-
const urlHash = this.hashUrl(url);
|
|
981
|
-
const tabOrder = this.generateTabOrder(url, urlHash);
|
|
982
|
-
const issues = this.detectKeyboardIssues(tabOrder);
|
|
983
|
-
const traps = this.detectFocusTraps(url, urlHash);
|
|
984
|
-
return {
|
|
985
|
-
url,
|
|
986
|
-
focusableElements: tabOrder.length,
|
|
987
|
-
tabOrder,
|
|
988
|
-
issues,
|
|
989
|
-
traps,
|
|
990
|
-
};
|
|
991
|
-
}
|
|
992
|
-
/**
|
|
993
|
-
* Check keyboard navigation using browser via Vibium
|
|
994
|
-
*
|
|
995
|
-
* Uses Vibium to find focusable elements and analyze their tab order.
|
|
996
|
-
*/
|
|
997
|
-
async checkKeyboardWithBrowser(url) {
|
|
998
|
-
if (!this.vibiumClient) {
|
|
999
|
-
return err(new Error('Vibium client not available'));
|
|
1000
|
-
}
|
|
1001
|
-
try {
|
|
1002
|
-
// Launch browser
|
|
1003
|
-
const launchResult = await this.vibiumClient.launch({
|
|
1004
|
-
headless: this.config.browserConfig.headless,
|
|
1005
|
-
});
|
|
1006
|
-
if (!launchResult.success) {
|
|
1007
|
-
return err(new Error(`Failed to launch browser: ${this.getErrorMessage(launchResult)}`));
|
|
1008
|
-
}
|
|
1009
|
-
try {
|
|
1010
|
-
// Navigate to URL
|
|
1011
|
-
const navResult = await this.vibiumClient.navigate({
|
|
1012
|
-
url,
|
|
1013
|
-
waitUntil: 'networkidle',
|
|
1014
|
-
timeout: this.config.browserConfig.timeout,
|
|
1015
|
-
});
|
|
1016
|
-
if (!navResult.success) {
|
|
1017
|
-
return err(new Error(`Failed to navigate to ${url}: ${this.getErrorMessage(navResult)}`));
|
|
1018
|
-
}
|
|
1019
|
-
// Find all focusable elements
|
|
1020
|
-
const focusableSelector = 'a[href], button, input, select, textarea, [tabindex]:not([tabindex="-1"])';
|
|
1021
|
-
const elementsResult = await this.vibiumClient.findElements({
|
|
1022
|
-
selector: focusableSelector,
|
|
1023
|
-
visible: true,
|
|
1024
|
-
});
|
|
1025
|
-
if (!elementsResult.success) {
|
|
1026
|
-
return err(new Error(`Failed to find focusable elements: ${this.getErrorMessage(elementsResult)}`));
|
|
1027
|
-
}
|
|
1028
|
-
// Build tab order from found elements
|
|
1029
|
-
const tabOrder = elementsResult.value.map((elem, index) => ({
|
|
1030
|
-
index,
|
|
1031
|
-
selector: elem.selector,
|
|
1032
|
-
elementType: this.getElementType(elem.tagName),
|
|
1033
|
-
hasVisibleFocus: true, // Assume visible in browser mode (axe-core handles this)
|
|
1034
|
-
}));
|
|
1035
|
-
// Run accessibility checks for keyboard-related rules
|
|
1036
|
-
const a11yResult = await this.vibiumClient.checkAccessibility({
|
|
1037
|
-
wcagLevel: this.config.defaultWCAGLevel,
|
|
1038
|
-
rules: {
|
|
1039
|
-
include: ['keyboard', 'focus-order', 'focus-trap', 'bypass-blocks'],
|
|
1040
|
-
},
|
|
1041
|
-
});
|
|
1042
|
-
// Extract keyboard issues from accessibility results
|
|
1043
|
-
const issues = [];
|
|
1044
|
-
const traps = [];
|
|
1045
|
-
if (a11yResult.success) {
|
|
1046
|
-
for (const violation of a11yResult.value.violations) {
|
|
1047
|
-
if (violation.rule.includes('focus') || violation.rule.includes('keyboard')) {
|
|
1048
|
-
for (const node of violation.nodes) {
|
|
1049
|
-
if (violation.rule.includes('trap')) {
|
|
1050
|
-
traps.push({
|
|
1051
|
-
selector: node.selector,
|
|
1052
|
-
description: node.failureSummary,
|
|
1053
|
-
escapePath: 'Ensure Escape key or Tab can exit this element',
|
|
1054
|
-
});
|
|
1055
|
-
}
|
|
1056
|
-
else {
|
|
1057
|
-
issues.push({
|
|
1058
|
-
type: this.mapKeyboardIssueType(violation.rule),
|
|
1059
|
-
selector: node.selector,
|
|
1060
|
-
description: node.failureSummary,
|
|
1061
|
-
});
|
|
1062
|
-
}
|
|
1063
|
-
}
|
|
1064
|
-
}
|
|
1065
|
-
}
|
|
1066
|
-
}
|
|
1067
|
-
const report = {
|
|
1068
|
-
url,
|
|
1069
|
-
focusableElements: tabOrder.length,
|
|
1070
|
-
tabOrder,
|
|
1071
|
-
issues,
|
|
1072
|
-
traps,
|
|
1073
|
-
};
|
|
1074
|
-
return ok(report);
|
|
1075
|
-
}
|
|
1076
|
-
finally {
|
|
1077
|
-
// Always clean up browser
|
|
1078
|
-
await this.vibiumClient.quit();
|
|
1079
|
-
}
|
|
1080
|
-
}
|
|
1081
|
-
catch (error) {
|
|
1082
|
-
return err(error instanceof Error ? error : new Error(String(error)));
|
|
1083
|
-
}
|
|
1084
|
-
}
|
|
1085
|
-
/**
|
|
1086
|
-
* Get element type from tag name
|
|
1087
|
-
*/
|
|
1088
|
-
getElementType(tagName) {
|
|
1089
|
-
const tagMap = {
|
|
1090
|
-
a: 'link',
|
|
1091
|
-
button: 'button',
|
|
1092
|
-
input: 'input',
|
|
1093
|
-
select: 'input',
|
|
1094
|
-
textarea: 'input',
|
|
1095
|
-
};
|
|
1096
|
-
return tagMap[tagName.toLowerCase()] || 'other';
|
|
1097
|
-
}
|
|
1098
|
-
/**
|
|
1099
|
-
* Map violation rule to keyboard issue type
|
|
1100
|
-
*/
|
|
1101
|
-
mapKeyboardIssueType(rule) {
|
|
1102
|
-
if (rule.includes('focus-indicator') || rule.includes('visible')) {
|
|
1103
|
-
return 'no-focus-indicator';
|
|
1104
|
-
}
|
|
1105
|
-
if (rule.includes('skip') || rule.includes('bypass')) {
|
|
1106
|
-
return 'skip-link-missing';
|
|
1107
|
-
}
|
|
1108
|
-
if (rule.includes('order') || rule.includes('sequence')) {
|
|
1109
|
-
return 'incorrect-tab-order';
|
|
1110
|
-
}
|
|
1111
|
-
return 'non-interactive-focusable';
|
|
1112
|
-
}
|
|
1113
303
|
// ============================================================================
|
|
1114
|
-
//
|
|
304
|
+
// Storage
|
|
1115
305
|
// ============================================================================
|
|
1116
|
-
/**
|
|
1117
|
-
* Extract error message from a Result
|
|
1118
|
-
* Type-safe helper that checks success status and returns error message
|
|
1119
|
-
*/
|
|
1120
|
-
getErrorMessage(result) {
|
|
1121
|
-
if (result.success === false) {
|
|
1122
|
-
return result.error?.message ?? 'Unknown error';
|
|
1123
|
-
}
|
|
1124
|
-
return 'Unknown error';
|
|
1125
|
-
}
|
|
1126
|
-
initializeRules() {
|
|
1127
|
-
return [
|
|
1128
|
-
{
|
|
1129
|
-
id: 'image-alt',
|
|
1130
|
-
description: 'Images must have alternate text',
|
|
1131
|
-
wcagCriteria: ['1.1.1'],
|
|
1132
|
-
impact: 'critical',
|
|
1133
|
-
simulationFailureRate: 0.1,
|
|
1134
|
-
},
|
|
1135
|
-
{
|
|
1136
|
-
id: 'button-name',
|
|
1137
|
-
description: 'Buttons must have discernible text',
|
|
1138
|
-
wcagCriteria: ['4.1.2'],
|
|
1139
|
-
impact: 'critical',
|
|
1140
|
-
simulationFailureRate: 0.05,
|
|
1141
|
-
},
|
|
1142
|
-
{
|
|
1143
|
-
id: 'color-contrast',
|
|
1144
|
-
description: 'Elements must have sufficient color contrast',
|
|
1145
|
-
wcagCriteria: ['1.4.3'],
|
|
1146
|
-
impact: 'serious',
|
|
1147
|
-
simulationFailureRate: 0.15,
|
|
1148
|
-
},
|
|
1149
|
-
{
|
|
1150
|
-
id: 'html-lang',
|
|
1151
|
-
description: 'HTML element must have a lang attribute',
|
|
1152
|
-
wcagCriteria: ['3.1.1'],
|
|
1153
|
-
impact: 'serious',
|
|
1154
|
-
simulationFailureRate: 0.02,
|
|
1155
|
-
},
|
|
1156
|
-
{
|
|
1157
|
-
id: 'link-name',
|
|
1158
|
-
description: 'Links must have discernible text',
|
|
1159
|
-
wcagCriteria: ['2.4.4', '4.1.2'],
|
|
1160
|
-
impact: 'serious',
|
|
1161
|
-
simulationFailureRate: 0.08,
|
|
1162
|
-
},
|
|
1163
|
-
{
|
|
1164
|
-
id: 'focus-visible',
|
|
1165
|
-
description: 'Interactive elements must have visible focus indication',
|
|
1166
|
-
wcagCriteria: ['2.4.7'],
|
|
1167
|
-
impact: 'serious',
|
|
1168
|
-
simulationFailureRate: 0.12,
|
|
1169
|
-
},
|
|
1170
|
-
{
|
|
1171
|
-
id: 'bypass-blocks',
|
|
1172
|
-
description: 'Page must have means to bypass repeated blocks',
|
|
1173
|
-
wcagCriteria: ['2.4.1'],
|
|
1174
|
-
impact: 'moderate',
|
|
1175
|
-
simulationFailureRate: 0.1,
|
|
1176
|
-
},
|
|
1177
|
-
{
|
|
1178
|
-
id: 'label',
|
|
1179
|
-
description: 'Form elements must have labels',
|
|
1180
|
-
wcagCriteria: ['1.3.1', '4.1.2'],
|
|
1181
|
-
impact: 'critical',
|
|
1182
|
-
simulationFailureRate: 0.07,
|
|
1183
|
-
},
|
|
1184
|
-
{
|
|
1185
|
-
id: 'keyboard-trap',
|
|
1186
|
-
description: 'Focus must not be trapped',
|
|
1187
|
-
wcagCriteria: ['2.1.2'],
|
|
1188
|
-
impact: 'critical',
|
|
1189
|
-
simulationFailureRate: 0.02,
|
|
1190
|
-
},
|
|
1191
|
-
{
|
|
1192
|
-
id: 'focus-order',
|
|
1193
|
-
description: 'Focus order must be logical',
|
|
1194
|
-
wcagCriteria: ['2.4.3'],
|
|
1195
|
-
impact: 'moderate',
|
|
1196
|
-
simulationFailureRate: 0.05,
|
|
1197
|
-
},
|
|
1198
|
-
];
|
|
1199
|
-
}
|
|
1200
|
-
filterRulesByLevel(level) {
|
|
1201
|
-
const levelOrder = { A: 1, AA: 2, AAA: 3 };
|
|
1202
|
-
const targetLevel = levelOrder[level];
|
|
1203
|
-
return this.rules.filter((rule) => {
|
|
1204
|
-
return rule.wcagCriteria.some((criteriaId) => {
|
|
1205
|
-
const criterion = WCAG_CRITERIA[criteriaId];
|
|
1206
|
-
return criterion && levelOrder[criterion.level] <= targetLevel;
|
|
1207
|
-
});
|
|
1208
|
-
});
|
|
1209
|
-
}
|
|
1210
|
-
runRule(rule, context) {
|
|
1211
|
-
// Simulation mode: use deterministic results based on URL hash
|
|
1212
|
-
if (this.config.simulationMode) {
|
|
1213
|
-
const nodes = this.checkRuleDeterministic(rule, context);
|
|
1214
|
-
const checkedNodes = this.estimateCheckedNodes(rule, context);
|
|
1215
|
-
return {
|
|
1216
|
-
nodes,
|
|
1217
|
-
passed: nodes.length === 0,
|
|
1218
|
-
checkedNodes,
|
|
1219
|
-
};
|
|
1220
|
-
}
|
|
1221
|
-
// Production mode: perform heuristic-based WCAG rule checking
|
|
1222
|
-
// without browser automation (static analysis based on URL patterns)
|
|
1223
|
-
const nodes = this.checkRuleWithHeuristics(rule, context);
|
|
1224
|
-
const checkedNodes = this.estimateCheckedNodes(rule, context);
|
|
1225
|
-
return {
|
|
1226
|
-
nodes,
|
|
1227
|
-
passed: nodes.length === 0,
|
|
1228
|
-
checkedNodes,
|
|
1229
|
-
};
|
|
1230
|
-
}
|
|
1231
|
-
/**
|
|
1232
|
-
* Heuristic-based WCAG rule checking for production mode.
|
|
1233
|
-
* Analyzes URL patterns and common accessibility issues without browser automation.
|
|
1234
|
-
* This provides baseline checks; full auditing requires browser-based tools like axe-core.
|
|
1235
|
-
*/
|
|
1236
|
-
checkRuleWithHeuristics(rule, context) {
|
|
1237
|
-
const nodes = [];
|
|
1238
|
-
const url = context.url.toLowerCase();
|
|
1239
|
-
// Analyze URL patterns to identify likely accessibility issues
|
|
1240
|
-
switch (rule.id) {
|
|
1241
|
-
case 'image-alt':
|
|
1242
|
-
// Check for image-heavy pages that commonly have alt text issues
|
|
1243
|
-
if (this.isLikelyImageHeavyPage(url)) {
|
|
1244
|
-
nodes.push(...this.generateImageAltWarnings(context));
|
|
1245
|
-
}
|
|
1246
|
-
break;
|
|
1247
|
-
case 'button-name':
|
|
1248
|
-
// Check for interactive pages that may have unlabeled buttons
|
|
1249
|
-
if (this.isLikelyInteractivePage(url)) {
|
|
1250
|
-
nodes.push(...this.generateButtonNameWarnings(context));
|
|
1251
|
-
}
|
|
1252
|
-
break;
|
|
1253
|
-
case 'color-contrast':
|
|
1254
|
-
// Contrast issues are common - flag for manual review
|
|
1255
|
-
if (this.config.enableColorContrastCheck) {
|
|
1256
|
-
nodes.push(...this.generateContrastWarnings(context));
|
|
1257
|
-
}
|
|
1258
|
-
break;
|
|
1259
|
-
case 'html-lang':
|
|
1260
|
-
// Language attribute check based on URL patterns
|
|
1261
|
-
if (this.isLikelyMissingLang(url)) {
|
|
1262
|
-
nodes.push({
|
|
1263
|
-
selector: 'html',
|
|
1264
|
-
html: '<html>',
|
|
1265
|
-
target: ['html'],
|
|
1266
|
-
failureSummary: 'Page may be missing lang attribute',
|
|
1267
|
-
fixSuggestion: 'Add lang attribute to <html> element (e.g., <html lang="en">)',
|
|
1268
|
-
});
|
|
1269
|
-
}
|
|
1270
|
-
break;
|
|
1271
|
-
case 'link-name':
|
|
1272
|
-
// Check for pages with navigation that may have empty links
|
|
1273
|
-
if (this.hasNavigationPatterns(url)) {
|
|
1274
|
-
nodes.push(...this.generateLinkNameWarnings(context));
|
|
1275
|
-
}
|
|
1276
|
-
break;
|
|
1277
|
-
case 'focus-visible':
|
|
1278
|
-
// Focus visibility issues common in modern SPAs
|
|
1279
|
-
if (this.isLikelySPA(url)) {
|
|
1280
|
-
nodes.push(...this.generateFocusVisibleWarnings(context));
|
|
1281
|
-
}
|
|
1282
|
-
break;
|
|
1283
|
-
case 'bypass-blocks':
|
|
1284
|
-
// Skip links commonly missing
|
|
1285
|
-
if (!this.hasSkipLinkPattern(url)) {
|
|
1286
|
-
nodes.push({
|
|
1287
|
-
selector: 'body',
|
|
1288
|
-
html: '<body>',
|
|
1289
|
-
target: ['body'],
|
|
1290
|
-
failureSummary: 'Page may lack skip navigation mechanism',
|
|
1291
|
-
fixSuggestion: 'Add a skip link at the beginning of the page to bypass repeated content',
|
|
1292
|
-
});
|
|
1293
|
-
}
|
|
1294
|
-
break;
|
|
1295
|
-
case 'label':
|
|
1296
|
-
// Form label issues on form pages
|
|
1297
|
-
if (this.isFormPage(url)) {
|
|
1298
|
-
nodes.push(...this.generateFormLabelWarnings(context));
|
|
1299
|
-
}
|
|
1300
|
-
break;
|
|
1301
|
-
case 'keyboard-trap':
|
|
1302
|
-
// Modal/dialog patterns that may trap focus
|
|
1303
|
-
if (this.hasModalPatterns(url)) {
|
|
1304
|
-
nodes.push(...this.generateKeyboardTrapWarnings(context));
|
|
1305
|
-
}
|
|
1306
|
-
break;
|
|
1307
|
-
case 'focus-order':
|
|
1308
|
-
// Focus order issues in complex layouts
|
|
1309
|
-
if (this.hasComplexLayoutPatterns(url)) {
|
|
1310
|
-
nodes.push(...this.generateFocusOrderWarnings(context));
|
|
1311
|
-
}
|
|
1312
|
-
break;
|
|
1313
|
-
}
|
|
1314
|
-
return nodes;
|
|
1315
|
-
}
|
|
1316
|
-
// URL pattern detection helpers for heuristic analysis
|
|
1317
|
-
isLikelyImageHeavyPage(url) {
|
|
1318
|
-
return url.includes('gallery') || url.includes('photo') || url.includes('image') ||
|
|
1319
|
-
url.includes('product') || url.includes('portfolio') || url.includes('media');
|
|
1320
|
-
}
|
|
1321
|
-
isLikelyInteractivePage(url) {
|
|
1322
|
-
return url.includes('app') || url.includes('dashboard') || url.includes('editor') ||
|
|
1323
|
-
url.includes('tool') || url.includes('builder') || url.includes('widget');
|
|
1324
|
-
}
|
|
1325
|
-
isLikelyMissingLang(url) {
|
|
1326
|
-
// Static file servers and CDNs often miss lang attribute
|
|
1327
|
-
return url.includes('cdn') || url.includes('static') || url.includes('.html') ||
|
|
1328
|
-
url.includes('file://');
|
|
1329
|
-
}
|
|
1330
|
-
hasNavigationPatterns(url) {
|
|
1331
|
-
return url.includes('nav') || url.includes('menu') || url.includes('header') ||
|
|
1332
|
-
url.includes('sidebar') || url.includes('footer');
|
|
1333
|
-
}
|
|
1334
|
-
isLikelySPA(url) {
|
|
1335
|
-
return url.includes('app') || url.includes('dashboard') || url.includes('#/') ||
|
|
1336
|
-
url.includes('react') || url.includes('angular') || url.includes('vue');
|
|
1337
|
-
}
|
|
1338
|
-
hasSkipLinkPattern(url) {
|
|
1339
|
-
// Most well-designed sites include skip links
|
|
1340
|
-
return url.includes('gov') || url.includes('edu') || url.includes('a11y') ||
|
|
1341
|
-
url.includes('accessible');
|
|
1342
|
-
}
|
|
1343
|
-
isFormPage(url) {
|
|
1344
|
-
return url.includes('form') || url.includes('contact') || url.includes('register') ||
|
|
1345
|
-
url.includes('signup') || url.includes('login') || url.includes('checkout') ||
|
|
1346
|
-
url.includes('submit') || url.includes('search');
|
|
1347
|
-
}
|
|
1348
|
-
hasModalPatterns(url) {
|
|
1349
|
-
return url.includes('modal') || url.includes('dialog') || url.includes('popup') ||
|
|
1350
|
-
url.includes('overlay') || url.includes('lightbox');
|
|
1351
|
-
}
|
|
1352
|
-
hasComplexLayoutPatterns(url) {
|
|
1353
|
-
return url.includes('dashboard') || url.includes('admin') || url.includes('grid') ||
|
|
1354
|
-
url.includes('layout') || url.includes('multi');
|
|
1355
|
-
}
|
|
1356
|
-
// Warning generators for heuristic checks
|
|
1357
|
-
generateImageAltWarnings(context) {
|
|
1358
|
-
return [{
|
|
1359
|
-
selector: 'img',
|
|
1360
|
-
html: '<img src="...">',
|
|
1361
|
-
target: ['img'],
|
|
1362
|
-
failureSummary: 'Images should have descriptive alt text',
|
|
1363
|
-
fixSuggestion: 'Add alt attribute with meaningful description to all <img> elements',
|
|
1364
|
-
}];
|
|
1365
|
-
}
|
|
1366
|
-
generateButtonNameWarnings(context) {
|
|
1367
|
-
return [{
|
|
1368
|
-
selector: 'button:not([aria-label])',
|
|
1369
|
-
html: '<button>',
|
|
1370
|
-
target: ['button'],
|
|
1371
|
-
failureSummary: 'Buttons should have accessible names',
|
|
1372
|
-
fixSuggestion: 'Ensure buttons have visible text or aria-label attribute',
|
|
1373
|
-
}];
|
|
1374
|
-
}
|
|
1375
|
-
generateContrastWarnings(context) {
|
|
1376
|
-
return [{
|
|
1377
|
-
selector: '.text-content',
|
|
1378
|
-
html: '<div class="text-content">',
|
|
1379
|
-
target: ['.text-content'],
|
|
1380
|
-
failureSummary: 'Text elements should meet WCAG 2.2 AA contrast ratio (4.5:1)',
|
|
1381
|
-
fixSuggestion: 'Verify text color has sufficient contrast against background',
|
|
1382
|
-
}];
|
|
1383
|
-
}
|
|
1384
|
-
generateLinkNameWarnings(context) {
|
|
1385
|
-
return [{
|
|
1386
|
-
selector: 'a:not([aria-label])',
|
|
1387
|
-
html: '<a href="#">',
|
|
1388
|
-
target: ['a'],
|
|
1389
|
-
failureSummary: 'Links should have descriptive text',
|
|
1390
|
-
fixSuggestion: 'Add meaningful link text or aria-label attribute',
|
|
1391
|
-
}];
|
|
1392
|
-
}
|
|
1393
|
-
generateFocusVisibleWarnings(context) {
|
|
1394
|
-
return [{
|
|
1395
|
-
selector: ':focus',
|
|
1396
|
-
html: '<element>:focus',
|
|
1397
|
-
target: [':focus'],
|
|
1398
|
-
failureSummary: 'Interactive elements should have visible focus indicators',
|
|
1399
|
-
fixSuggestion: 'Do not remove outline on :focus; use :focus-visible for styling',
|
|
1400
|
-
}];
|
|
1401
|
-
}
|
|
1402
|
-
generateFormLabelWarnings(context) {
|
|
1403
|
-
return [{
|
|
1404
|
-
selector: 'input:not([aria-label]):not([id])',
|
|
1405
|
-
html: '<input type="text">',
|
|
1406
|
-
target: ['input'],
|
|
1407
|
-
failureSummary: 'Form inputs should have associated labels',
|
|
1408
|
-
fixSuggestion: 'Add <label for="id"> or aria-label to form inputs',
|
|
1409
|
-
}];
|
|
1410
|
-
}
|
|
1411
|
-
generateKeyboardTrapWarnings(context) {
|
|
1412
|
-
return [{
|
|
1413
|
-
selector: '[role="dialog"]',
|
|
1414
|
-
html: '<div role="dialog">',
|
|
1415
|
-
target: ['[role="dialog"]'],
|
|
1416
|
-
failureSummary: 'Modal dialogs should not trap keyboard focus',
|
|
1417
|
-
fixSuggestion: 'Ensure Escape key closes modal and Tab cycles within dialog',
|
|
1418
|
-
}];
|
|
1419
|
-
}
|
|
1420
|
-
generateFocusOrderWarnings(context) {
|
|
1421
|
-
return [{
|
|
1422
|
-
selector: '[tabindex]',
|
|
1423
|
-
html: '<div tabindex="...">',
|
|
1424
|
-
target: ['[tabindex]'],
|
|
1425
|
-
failureSummary: 'Focus order should follow logical reading sequence',
|
|
1426
|
-
fixSuggestion: 'Avoid positive tabindex values; use tabindex="0" or "-1"',
|
|
1427
|
-
}];
|
|
1428
|
-
}
|
|
1429
|
-
/**
|
|
1430
|
-
* Deterministic rule check for simulation mode only.
|
|
1431
|
-
* Uses URL hash to produce consistent results without Math.random().
|
|
1432
|
-
*/
|
|
1433
|
-
checkRuleDeterministic(rule, context) {
|
|
1434
|
-
const nodes = [];
|
|
1435
|
-
const urlHash = this.hashUrl(context.url);
|
|
1436
|
-
const hashNum = parseInt(urlHash, 36);
|
|
1437
|
-
// Use URL hash + rule ID to determine element count (1-10)
|
|
1438
|
-
const ruleIdHash = rule.id.split('').reduce((acc, c) => acc + c.charCodeAt(0), 0);
|
|
1439
|
-
const elementCount = 1 + ((hashNum + ruleIdHash) % 10);
|
|
1440
|
-
for (let i = 0; i < elementCount; i++) {
|
|
1441
|
-
// Deterministic failure based on hash, rule failure rate, and element index
|
|
1442
|
-
const determinant = ((hashNum + ruleIdHash + i * 100) % 100) / 100;
|
|
1443
|
-
if (determinant < rule.simulationFailureRate) {
|
|
1444
|
-
const selector = this.generateDeterministicSelector(rule.id, i);
|
|
1445
|
-
nodes.push({
|
|
1446
|
-
selector,
|
|
1447
|
-
html: `<element class="${rule.id}-element-${i}">Content</element>`,
|
|
1448
|
-
target: [selector],
|
|
1449
|
-
failureSummary: 'Element does not meet accessibility requirements',
|
|
1450
|
-
fixSuggestion: 'Review and update the element to meet WCAG guidelines',
|
|
1451
|
-
});
|
|
1452
|
-
}
|
|
1453
|
-
}
|
|
1454
|
-
return nodes;
|
|
1455
|
-
}
|
|
1456
|
-
/**
|
|
1457
|
-
* Generate a deterministic selector based on rule ID and index
|
|
1458
|
-
*/
|
|
1459
|
-
generateDeterministicSelector(ruleId, index) {
|
|
1460
|
-
const tagsByRule = {
|
|
1461
|
-
'image-alt': ['img'],
|
|
1462
|
-
'button-name': ['button'],
|
|
1463
|
-
'color-contrast': ['div', 'p', 'span'],
|
|
1464
|
-
'html-lang': ['html'],
|
|
1465
|
-
'link-name': ['a'],
|
|
1466
|
-
'focus-visible': ['button', 'a', 'input'],
|
|
1467
|
-
'bypass-blocks': ['main', 'nav'],
|
|
1468
|
-
'label': ['input', 'select', 'textarea'],
|
|
1469
|
-
'keyboard-trap': ['div', 'dialog'],
|
|
1470
|
-
'focus-order': ['button', 'a', 'input'],
|
|
1471
|
-
};
|
|
1472
|
-
const tags = tagsByRule[ruleId] || ['div'];
|
|
1473
|
-
const tag = tags[index % tags.length];
|
|
1474
|
-
const classes = ['content', 'widget', 'component', 'item', 'element'];
|
|
1475
|
-
const className = classes[index % classes.length];
|
|
1476
|
-
return `${tag}.${className}`;
|
|
1477
|
-
}
|
|
1478
|
-
/**
|
|
1479
|
-
* Estimate the number of elements checked based on rule category
|
|
1480
|
-
*/
|
|
1481
|
-
estimateCheckedNodes(rule, context) {
|
|
1482
|
-
// Base estimate on rule category - different rules check different element types
|
|
1483
|
-
const ruleId = rule.id.toLowerCase();
|
|
1484
|
-
// Image rules typically check fewer elements
|
|
1485
|
-
if (ruleId.includes('image') || ruleId.includes('alt')) {
|
|
1486
|
-
return 5 + (context.url.length % 10); // 5-14 elements
|
|
1487
|
-
}
|
|
1488
|
-
// Form rules check form elements
|
|
1489
|
-
if (ruleId.includes('form') || ruleId.includes('label') || ruleId.includes('input')) {
|
|
1490
|
-
return 8 + (context.url.length % 12); // 8-19 elements
|
|
1491
|
-
}
|
|
1492
|
-
// Link rules check all anchor elements
|
|
1493
|
-
if (ruleId.includes('link') || ruleId.includes('anchor')) {
|
|
1494
|
-
return 15 + (context.url.length % 20); // 15-34 elements
|
|
1495
|
-
}
|
|
1496
|
-
// Color/contrast rules check text elements
|
|
1497
|
-
if (ruleId.includes('color') || ruleId.includes('contrast')) {
|
|
1498
|
-
return 20 + (context.url.length % 15); // 20-34 elements
|
|
1499
|
-
}
|
|
1500
|
-
// Heading rules check heading hierarchy
|
|
1501
|
-
if (ruleId.includes('heading') || ruleId.includes('h1') || ruleId.includes('h2')) {
|
|
1502
|
-
return 6 + (context.url.length % 8); // 6-13 elements
|
|
1503
|
-
}
|
|
1504
|
-
// ARIA rules check interactive elements
|
|
1505
|
-
if (ruleId.includes('aria') || ruleId.includes('role')) {
|
|
1506
|
-
return 12 + (context.url.length % 18); // 12-29 elements
|
|
1507
|
-
}
|
|
1508
|
-
// Default: moderate number of elements
|
|
1509
|
-
return 10 + (context.url.length % 10); // 10-19 elements
|
|
1510
|
-
}
|
|
1511
|
-
/**
|
|
1512
|
-
* Analyze contrast for common UI elements
|
|
1513
|
-
*/
|
|
1514
|
-
analyzeContrastForElements(url) {
|
|
1515
|
-
const elements = ['h1', 'p', 'a', 'button', '.card-text', '.nav-link'];
|
|
1516
|
-
const analyses = [];
|
|
1517
|
-
const urlHash = this.hashUrl(url);
|
|
1518
|
-
const hashNum = parseInt(urlHash, 36);
|
|
1519
|
-
for (let i = 0; i < elements.length; i++) {
|
|
1520
|
-
const element = elements[i];
|
|
1521
|
-
// Calculate contrast ratio deterministically based on URL and element
|
|
1522
|
-
// Using common website patterns: most sites have decent contrast
|
|
1523
|
-
const baseRatio = 4.5 + ((hashNum + i * 1000) % 100) / 10; // 4.5 to 14.5
|
|
1524
|
-
const ratio = Math.round(baseRatio * 100) / 100;
|
|
1525
|
-
// Large text (h1, button) requires 3:1, normal text requires 4.5:1
|
|
1526
|
-
const isLargeText = element === 'h1' || element === 'button';
|
|
1527
|
-
const requiredRatio = isLargeText ? 3 : 4.5;
|
|
1528
|
-
const passes = ratio >= requiredRatio;
|
|
1529
|
-
// Generate representative colors based on hash (hex format for test compatibility)
|
|
1530
|
-
const fgValue = 20 + ((hashNum + i * 50) % 30); // 20-50 (dark, ~0x14-0x32)
|
|
1531
|
-
const bgValue = 200 + ((hashNum + i * 30) % 55); // 200-255 (light)
|
|
1532
|
-
const fgHex = fgValue.toString(16).padStart(2, '0');
|
|
1533
|
-
const bgHex = bgValue.toString(16).padStart(2, '0');
|
|
1534
|
-
analyses.push({
|
|
1535
|
-
element,
|
|
1536
|
-
foreground: `#${fgHex}${fgHex}${fgHex}`, // Grayscale hex
|
|
1537
|
-
background: `#${bgHex}${bgHex}${bgHex}`, // Grayscale hex
|
|
1538
|
-
ratio,
|
|
1539
|
-
requiredRatio,
|
|
1540
|
-
passes,
|
|
1541
|
-
wcagLevel: 'AA',
|
|
1542
|
-
});
|
|
1543
|
-
}
|
|
1544
|
-
return analyses;
|
|
1545
|
-
}
|
|
1546
|
-
/**
|
|
1547
|
-
* Generate tab order based on URL structure
|
|
1548
|
-
*/
|
|
1549
|
-
generateTabOrder(url, urlHash) {
|
|
1550
|
-
const items = [];
|
|
1551
|
-
const hashNum = parseInt(urlHash, 36);
|
|
1552
|
-
// Standard focusable elements in typical page structure
|
|
1553
|
-
const elements = [
|
|
1554
|
-
{ selector: '#skip-link', type: 'link' },
|
|
1555
|
-
{ selector: 'header nav a.logo', type: 'link' },
|
|
1556
|
-
{ selector: 'header nav a.menu-item', type: 'link' },
|
|
1557
|
-
{ selector: '#search-input', type: 'input' },
|
|
1558
|
-
{ selector: '#search-button', type: 'button' },
|
|
1559
|
-
{ selector: 'main a', type: 'link' },
|
|
1560
|
-
{ selector: 'main button', type: 'button' },
|
|
1561
|
-
{ selector: 'form input', type: 'input' },
|
|
1562
|
-
{ selector: 'form select', type: 'input' },
|
|
1563
|
-
{ selector: 'form button[type="submit"]', type: 'button' },
|
|
1564
|
-
{ selector: 'footer a', type: 'link' },
|
|
1565
|
-
];
|
|
1566
|
-
// Determine which elements have visible focus (deterministic based on URL)
|
|
1567
|
-
elements.forEach((elem, index) => {
|
|
1568
|
-
// Most elements should have visible focus, ~12% don't
|
|
1569
|
-
const focusVisibleDeterminant = (hashNum + index * 17) % 100;
|
|
1570
|
-
const hasVisibleFocus = focusVisibleDeterminant >= 12;
|
|
1571
|
-
items.push({
|
|
1572
|
-
index,
|
|
1573
|
-
selector: elem.selector,
|
|
1574
|
-
elementType: elem.type,
|
|
1575
|
-
hasVisibleFocus,
|
|
1576
|
-
});
|
|
1577
|
-
});
|
|
1578
|
-
return items;
|
|
1579
|
-
}
|
|
1580
|
-
detectKeyboardIssues(tabOrder) {
|
|
1581
|
-
const issues = [];
|
|
1582
|
-
// Check for missing focus indicators
|
|
1583
|
-
for (const item of tabOrder) {
|
|
1584
|
-
if (!item.hasVisibleFocus) {
|
|
1585
|
-
issues.push({
|
|
1586
|
-
type: 'no-focus-indicator',
|
|
1587
|
-
selector: item.selector,
|
|
1588
|
-
description: `Element ${item.selector} does not have a visible focus indicator`,
|
|
1589
|
-
});
|
|
1590
|
-
}
|
|
1591
|
-
}
|
|
1592
|
-
// Check for skip link
|
|
1593
|
-
if (!tabOrder.some((item) => item.selector.includes('skip'))) {
|
|
1594
|
-
issues.push({
|
|
1595
|
-
type: 'skip-link-missing',
|
|
1596
|
-
selector: 'body',
|
|
1597
|
-
description: 'Page is missing a skip navigation link',
|
|
1598
|
-
});
|
|
1599
|
-
}
|
|
1600
|
-
// Check for logical focus order issues
|
|
1601
|
-
const hasLogicalOrder = tabOrder.every((item, index) => {
|
|
1602
|
-
if (index === 0)
|
|
1603
|
-
return true;
|
|
1604
|
-
// Check that navigation elements come before main content
|
|
1605
|
-
const isNav = item.selector.includes('nav') || item.selector.includes('header');
|
|
1606
|
-
const prevIsMain = tabOrder[index - 1].selector.includes('main');
|
|
1607
|
-
return !(isNav && prevIsMain);
|
|
1608
|
-
});
|
|
1609
|
-
if (!hasLogicalOrder) {
|
|
1610
|
-
issues.push({
|
|
1611
|
-
type: 'incorrect-tab-order',
|
|
1612
|
-
selector: 'body',
|
|
1613
|
-
description: 'Focus order does not follow logical reading sequence',
|
|
1614
|
-
});
|
|
1615
|
-
}
|
|
1616
|
-
return issues;
|
|
1617
|
-
}
|
|
1618
|
-
/**
|
|
1619
|
-
* Detect focus traps based on URL patterns
|
|
1620
|
-
*/
|
|
1621
|
-
detectFocusTraps(url, urlHash) {
|
|
1622
|
-
const traps = [];
|
|
1623
|
-
const hashNum = parseInt(urlHash, 36);
|
|
1624
|
-
// Check for common focus trap patterns based on URL
|
|
1625
|
-
const hasModal = url.includes('modal') || url.includes('dialog') || url.includes('popup');
|
|
1626
|
-
const hasForm = url.includes('form') || url.includes('checkout') || url.includes('register');
|
|
1627
|
-
// 8% chance of focus trap issue for pages with modal-like patterns
|
|
1628
|
-
if (hasModal && hashNum % 100 < 8) {
|
|
1629
|
-
traps.push({
|
|
1630
|
-
selector: '.modal, [role="dialog"]',
|
|
1631
|
-
description: 'Modal dialog may trap focus without escape mechanism',
|
|
1632
|
-
escapePath: 'Ensure Escape key closes modal and focus returns to trigger element',
|
|
1633
|
-
});
|
|
1634
|
-
}
|
|
1635
|
-
// 5% chance of focus trap in complex forms
|
|
1636
|
-
if (hasForm && hashNum % 100 < 5) {
|
|
1637
|
-
traps.push({
|
|
1638
|
-
selector: 'form .autocomplete, form .datepicker',
|
|
1639
|
-
description: 'Form widget may trap keyboard focus',
|
|
1640
|
-
escapePath: 'Add keyboard navigation (Tab/Escape) to exit widget',
|
|
1641
|
-
});
|
|
1642
|
-
}
|
|
1643
|
-
return traps;
|
|
1644
|
-
}
|
|
1645
306
|
async storeReport(report) {
|
|
1646
307
|
const reportId = uuidv4();
|
|
1647
308
|
await this.memory.set(`visual-accessibility:report:${reportId}`, report, { namespace: 'visual-accessibility', persist: true });
|
|
1648
|
-
|
|
1649
|
-
await this.memory.set(`visual-accessibility:latest:${this.hashUrl(report.url)}`, report, { namespace: 'visual-accessibility', persist: true });
|
|
1650
|
-
}
|
|
1651
|
-
hashUrl(url) {
|
|
1652
|
-
let hash = 0;
|
|
1653
|
-
for (let i = 0; i < url.length; i++) {
|
|
1654
|
-
const char = url.charCodeAt(i);
|
|
1655
|
-
hash = (hash << 5) - hash + char;
|
|
1656
|
-
hash = hash & hash;
|
|
1657
|
-
}
|
|
1658
|
-
return Math.abs(hash).toString(36);
|
|
309
|
+
await this.memory.set(`visual-accessibility:latest:${hashUrl(report.url)}`, report, { namespace: 'visual-accessibility', persist: true });
|
|
1659
310
|
}
|
|
1660
311
|
// ============================================================================
|
|
1661
312
|
// EU Compliance Methods
|
|
1662
313
|
// ============================================================================
|
|
1663
|
-
/**
|
|
1664
|
-
* Validate EU compliance (EN 301 549 and EU Accessibility Act)
|
|
1665
|
-
*
|
|
1666
|
-
* This method performs a WCAG audit first, then maps the results to
|
|
1667
|
-
* European accessibility standards:
|
|
1668
|
-
* - EN 301 549 V3.2.1 (harmonized European standard)
|
|
1669
|
-
* - EU Accessibility Act (Directive 2019/882)
|
|
1670
|
-
*
|
|
1671
|
-
* @param url - URL to validate
|
|
1672
|
-
* @param options - EU compliance options
|
|
1673
|
-
* @returns Full EU compliance report with EN 301 549 and EAA results
|
|
1674
|
-
*
|
|
1675
|
-
* @example
|
|
1676
|
-
* ```typescript
|
|
1677
|
-
* const report = await service.validateEUCompliance('https://example.com', {
|
|
1678
|
-
* includeEAA: true,
|
|
1679
|
-
* productCategory: 'e-commerce',
|
|
1680
|
-
* en301549Version: '3.2.1',
|
|
1681
|
-
* });
|
|
1682
|
-
*
|
|
1683
|
-
* if (report.success) {
|
|
1684
|
-
* console.log(`EU Compliance Score: ${report.value.complianceScore}%`);
|
|
1685
|
-
* console.log(`Status: ${report.value.overallStatus}`);
|
|
1686
|
-
* console.log(`Certification Ready: ${report.value.certificationReady}`);
|
|
1687
|
-
* }
|
|
1688
|
-
* ```
|
|
1689
|
-
*/
|
|
1690
314
|
async validateEUCompliance(url, options) {
|
|
1691
315
|
try {
|
|
1692
|
-
// First, run a WCAG AA audit (EN 301 549 requires WCAG 2.1 AA)
|
|
1693
316
|
const wcagResult = await this.audit(url, {
|
|
1694
317
|
wcagLevel: 'AA',
|
|
1695
318
|
includeWarnings: true,
|
|
@@ -1697,36 +320,25 @@ export class AccessibilityTesterService {
|
|
|
1697
320
|
if (!wcagResult.success) {
|
|
1698
321
|
return err(new Error(`WCAG audit failed: ${wcagResult.error.message}`));
|
|
1699
322
|
}
|
|
1700
|
-
// Then validate EU compliance based on WCAG results
|
|
1701
323
|
const euResult = await this.euComplianceService.validateCompliance(wcagResult.value, options);
|
|
1702
324
|
return euResult;
|
|
1703
325
|
}
|
|
1704
326
|
catch (error) {
|
|
1705
|
-
return err(
|
|
327
|
+
return err(toError(error));
|
|
1706
328
|
}
|
|
1707
329
|
}
|
|
1708
|
-
/**
|
|
1709
|
-
* Get EN 301 549 clauses for reference
|
|
1710
|
-
*/
|
|
1711
330
|
getEN301549Clauses() {
|
|
1712
331
|
return this.euComplianceService.getEN301549Clauses();
|
|
1713
332
|
}
|
|
1714
|
-
/**
|
|
1715
|
-
* Get EU Accessibility Act requirements for reference
|
|
1716
|
-
*/
|
|
1717
333
|
getEAARequirements() {
|
|
1718
334
|
return this.euComplianceService.getEAARequirements();
|
|
1719
335
|
}
|
|
1720
|
-
/**
|
|
1721
|
-
* Get WCAG to EN 301 549 mapping table
|
|
1722
|
-
*/
|
|
1723
336
|
getWCAGtoEN301549Mapping() {
|
|
1724
337
|
return this.euComplianceService.getWCAGMapping();
|
|
1725
338
|
}
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
*/
|
|
339
|
+
// ============================================================================
|
|
340
|
+
// Lifecycle
|
|
341
|
+
// ============================================================================
|
|
1730
342
|
async dispose() {
|
|
1731
343
|
if (this.managedBrowserClient) {
|
|
1732
344
|
await this.managedBrowserClient.dispose();
|