Playable.

This commit is contained in:
AnduinXue
2023-11-27 13:00:27 +00:00
parent 7f97861568
commit f63a5ecea3
43 changed files with 20401 additions and 6 deletions
@@ -0,0 +1,29 @@
@model int
@{
Layout = null;
}
<!DOCTYPE html>
<html lang="en">
<head>
<title>Game HTML</title>
<meta charset="utf-8"/>
<link href="~/chessboardjs/css/chessboard-1.0.0.min.css" rel="stylesheet"/>
</head>
<body>
<div id="board" style="width: 400px"></div>
<button id="refresh" style="margin-top: 5px">Refresh</button>
<p id="status"></p>
<p id="fen"></p>
<p id="pgn"></p>
<script type="module" src="~/chess.js/dist/esm/chess.js"></script>
<script src="~/jquery/dist/jquery.min.js"></script>
<script src="~/chessboardjs/js/chessboard-1.0.0.min.js"></script>
<script type="module" src="~/site.js"></script>
<script type="module">
// Ask the user to enter w or b:
import initGameBoard from "/site.js";
const player = prompt("Please enter your color (w or b):");
initGameBoard(player, @Model);
</script>
</body>
</html>