Files

56 lines
1.7 KiB
Plaintext

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Chess Game</title>
<style>
.chessboard {
display: grid;
grid-template-columns: repeat(8, minmax(0, 1fr));
grid-template-rows: repeat(8, minmax(0, 1fr));
width: 400px;
height: 400px;
border: 2px solid #333;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
margin: auto;
position: absolute;
top: 0; bottom: 0; left: 0; right: 0;
}
.square {
display: flex;
align-items: center;
justify-content: center;
font-size: 2rem;
width: 50px;
height: 50px;
}
.light { background-color: #f0d9b5; }
.dark { background-color: #b58863; }
.piece { position: relative; cursor: grab; }
.piece.white { color: white; text-shadow: 0 0 3px black; }
.piece.black { color: black; }
.flipped { transform: rotate(180deg); }
</style>
</head>
<body>
<div style="display: flex; justify-content: center;">
<h1 style="background-color: #18122b; color: #f0f0f0; padding: 10px 20px; border-radius: 5px;">
Chess game by 23NeuroBytes
</h1>
</div>
<div class="d-flex align-items-center justify-content-center vh-100">
<div class="chessboard"></div>
</div>
<script src="https://cdn.socket.io/4.7.5/socket.io.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/chess.js/0.10.3/chess.min.js"></script>
<script src="/js/chessGame.js"></script>
</body>
</html>