feat : new move classification icons
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 2.4 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 2.2 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 2.3 KiB |
|
Before Width: | Height: | Size: 2.1 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.8 KiB |
@@ -32,6 +32,8 @@ if (
|
|||||||
"AbortError: The user aborted a request.",
|
"AbortError: The user aborted a request.",
|
||||||
"Failed to fetch",
|
"Failed to fetch",
|
||||||
"Fetch is aborted",
|
"Fetch is aborted",
|
||||||
|
"The operation was aborted.",
|
||||||
|
"AbortError: AbortError",
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,16 +1,16 @@
|
|||||||
import { EngineName, MoveClassification } from "./types/enums";
|
import { EngineName, MoveClassification } from "./types/enums";
|
||||||
|
|
||||||
export const CLASSIFICATION_COLORS: Record<MoveClassification, string> = {
|
export const CLASSIFICATION_COLORS: Record<MoveClassification, string> = {
|
||||||
[MoveClassification.Book]: "#d5a47d",
|
[MoveClassification.Book]: "#dbac86",
|
||||||
[MoveClassification.Forced]: "#d5a47d",
|
[MoveClassification.Forced]: "#dbac86",
|
||||||
[MoveClassification.Brilliant]: "#26c2a3",
|
[MoveClassification.Brilliant]: "#19d4af",
|
||||||
[MoveClassification.Great]: "#4099ed",
|
[MoveClassification.Great]: "#3894eb",
|
||||||
[MoveClassification.Best]: "#3aab18",
|
[MoveClassification.Best]: "#22ac38",
|
||||||
[MoveClassification.Excellent]: "#3aab18",
|
[MoveClassification.Excellent]: "#22ac38",
|
||||||
[MoveClassification.Good]: "#81b64c",
|
[MoveClassification.Good]: "#74b038",
|
||||||
[MoveClassification.Inaccuracy]: "#f7c631",
|
[MoveClassification.Inaccuracy]: "#f2be1f",
|
||||||
[MoveClassification.Mistake]: "#ffa459",
|
[MoveClassification.Mistake]: "#e69f00",
|
||||||
[MoveClassification.Blunder]: "#fa412d",
|
[MoveClassification.Blunder]: "#df5353",
|
||||||
};
|
};
|
||||||
|
|
||||||
export const DEFAULT_ENGINE: EngineName = EngineName.Stockfish17Lite;
|
export const DEFAULT_ENGINE: EngineName = EngineName.Stockfish17Lite;
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ export default function GameDatabase() {
|
|||||||
if (typeof id !== "number") {
|
if (typeof id !== "number") {
|
||||||
throw new Error("Unable to copy game");
|
throw new Error("Unable to copy game");
|
||||||
}
|
}
|
||||||
await navigator.clipboard.writeText(games[id - 1].pgn);
|
await navigator.clipboard?.writeText?.(games[id - 1].pgn);
|
||||||
},
|
},
|
||||||
[games]
|
[games]
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -71,7 +71,7 @@ export default function PanelToolBar() {
|
|||||||
<IconButton
|
<IconButton
|
||||||
disabled={game.history().length === 0}
|
disabled={game.history().length === 0}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
navigator.clipboard.writeText(game.pgn());
|
navigator.clipboard?.writeText?.(game.pgn());
|
||||||
}}
|
}}
|
||||||
sx={{ paddingX: 1.2, paddingY: 0.5 }}
|
sx={{ paddingX: 1.2, paddingY: 0.5 }}
|
||||||
>
|
>
|
||||||
|
|||||||