This commit is contained in:
Maciej Caderek
2022-01-19 03:25:48 +01:00
parent 707d673557
commit 5d750f1a5b
2 changed files with 4 additions and 4 deletions

View File

@@ -65,7 +65,7 @@ class Board {
flip() {
this.flipped = !this.flipped;
// this.render(this.boardData, this.lastMove);
this.render(this.boardData, this.lastMove);
return this;
}

View File

@@ -5,7 +5,7 @@ import styles from "./board/styles-board";
import Game from "./game/Game";
import pgns from "./test-data/pgns";
import createSimpleGIF from "./gif/createSimpleGIF";
import { decompressPGN } from "./game/PGNHelpers";
// import { decompressPGN } from "./game/PGNHelpers";
const $app = document.querySelector<HTMLImageElement>("#app");
@@ -54,8 +54,8 @@ const main = async () => {
window.location.hash =
"#QiBEdWtlIEthcmwgLyBDb3VudCBJc291YXJkCkQgMTg1OC4/Py4/PwpFIFBhcmlzClIgMS0wClMgUGFyaXMgRlJBClcgUGF1bCBNb3JwaHkKCmU0IGU1IE5mMyBkNiBkNCBCZzQgZHhlNSBCeGYzIFF4ZjMgZHhlNSBCYzQgTmY2IFFiMyBRZTcgTmMzIGM2IEJnNSBiNSBOeGI1IGN4YjUgQnhiNSsgTmJkNyBPLU8tTyBSZDggUnhkNyBSeGQ3IFJkMSBRZTYgQnhkNysgTnhkNyBRYjgrIE54YjggUmQ4Iw==";
const hash = window.location.hash;
const pgn = hash === "" ? null : decompressPGN(hash.slice(1));
// const hash = window.location.hash;
// const pgn = hash === "" ? null : decompressPGN(hash.slice(1));
const board = new Board(8).setStyle(style).setSize(720).showBorder();
$app?.appendChild(board.canvas);