Files
Ferrous-Solitaire/solitaire_server/web/index.html
T
funman300 a9285ccb41
Build and Deploy / build-and-push (push) Successful in 3m47s
feat(web): add step-back to replay viewer
The "⏮ Restart" button now steps back one move at a time instead of
resetting to the beginning. Re-creates the ReplayPlayer and fast-forwards
to (step_idx - 1) without rendering intermediate frames; the CSS transform
transition then animates each card back to its previous position.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-15 17:21:32 -07:00

49 lines
1.6 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Ferrous Solitaire — Replay</title>
<link rel="stylesheet" href="/web/replay.css">
<!-- Matomo -->
<script>
var _paq = window._paq = window._paq || [];
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u = "https://analytics.aleshym.co/";
_paq.push(['setTrackerUrl', u + 'matomo.php']);
_paq.push(['setSiteId', '1']);
var d = document, g = d.createElement('script'), s = d.getElementsByTagName('script')[0];
g.async = true; g.src = u + 'matomo.js'; s.parentNode.insertBefore(g, s);
})();
</script>
<!-- End Matomo -->
</head>
<body>
<header>
<h1>Ferrous Solitaire <span class="muted">— Replay</span></h1>
<div id="caption" class="muted">Loading…</div>
</header>
<main>
<section id="board"></section>
<section id="controls">
<button id="btn-prev" disabled>◀ Back</button>
<button id="btn-play">▶ Play</button>
<button id="btn-step">⏭ Step</button>
<span id="progress" class="muted">step 0 / 0</span>
</section>
<section id="status" class="muted">
<span id="score">Score 0</span>
<span id="moves">Moves 0</span>
<span id="result"></span>
</section>
</main>
<script type="module" src="/web/replay.js"></script>
</body>
</html>