Files
gsd-framework/index.html
T
tiennm99 f63bb9c8ed test(04-04): add previous score display tests and HTML element
- Added tests for previous-score-display element existence and styling
- Added previous-score-display div to HTML with score-container wrapper
- Element initially hidden with display: none
- Follows existing score-display pattern for consistency


🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-03-11 08:28:07 +00:00

88 lines
2.2 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Pikachu Match Game</title>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
display: flex;
justify-content: center;
align-items: center;
min-height: 100vh;
background-color: #1a1a2e;
}
#game {
border-radius: 8px;
}
#score-display {
position: absolute;
top: 20px;
right: 20px;
background-color: rgba(26, 26, 70, 0.9);
color: #eaeaea;
padding: 16px 24px;
border-radius: 8px;
font-size: 24px;
font-weight: bold;
z-index: 100;
}
#game-over-overlay {
display: none;
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-color: rgba(0, 0, 0, 0.8);
justify-content: center;
align-items: center;
z-index: 1000;
}
#overlay-content {
background-color: rgba(26, 26, 70, 0.95);
padding: 40px;
border-radius: 12px;
text-align: center;
}
#game-over-message {
font-size: 48px;
color: #eaeaea;
margin-bottom: 24px;
}
#restart-button {
padding: 16px 32px;
font-size: 24px;
background-color: #e94560;
color: white;
border: none;
border-radius: 8px;
cursor: pointer;
transition: background-color 0.2s;
}
#restart-button:hover {
background-color: #d63850;
}
</style>
</head>
<body>
<canvas id="game"></canvas>
<div id="score-container">
<div id="score-display">Score: 0</div>
<div id="previous-score-display" style="display: none;">Previous: 0</div>
</div>
<div id="game-over-overlay">
<div id="overlay-content">
<h1 id="game-over-message"></h1>
<button id="restart-button">Play Again</button>
</div>
</div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>