Commit 049e06c9 authored by Mahmoud Aglan's avatar Mahmoud Aglan

feat(chess): Chess.com-style Game Review with full move analysis

New screen: Game Review (chess-review)
- Analyzes EVERY move with Stockfish (depth 12)
- Shows progress bar while analyzing
- Eval graph: canvas-rendered white/black area chart with mistake dots
- Accuracy comparison: player vs opponent percentage with colored bars
- Move classification breakdown table:
  !! Brilliant, ! Great, ★ Best, ✓ Good, 📖 Book,
  ?! Inaccuracy, ? Mistake, ?? Blunder
- Counts per player side-by-side (like Chess.com)
- Opening name displayed
- Links to detailed analysis (timeline scrubber)
Co-Authored-By: 's avatarClaude Opus 4.6 <noreply@anthropic.com>
parent 1b3088ab
......@@ -3,8 +3,10 @@ import { mountGame } from './scenes/game.js';
import { mountResult } from './scenes/result.js';
import { mountAnalysis } from './scenes/analysis.js';
import { mountHistory } from './scenes/history.js';
import { mountReview } from './scenes/review.js';
scene.register('chess-game', mountGame);
scene.register('chess-result', mountResult);
scene.register('chess-analysis', mountAnalysis);
scene.register('chess-history', mountHistory);
scene.register('chess-review', mountReview);
......@@ -127,7 +127,7 @@ export function mountResult(el, params) {
el.querySelector('#btn-analyze').addEventListener('click', () => {
audio.play('click');
juice.hapticLight();
scene.push('chess-analysis', { pgn, moveHistory, finalFen: params.finalFen });
scene.push('chess-review', { moveHistory, playerColor: params.playerColor || 'w', botId, result });
});
el.querySelector('#btn-back').addEventListener('click', () => {
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment