Add Sittuyin + Doublemove2. A few fixes. TODO: fix Ambiguous bugs and playing on...
[vchess.git] / client / src / components / Board.vue
index e6a0aaf..c7c3789 100644 (file)
@@ -60,8 +60,10 @@ export default {
     if (!!lm) {
       if (!Array.isArray(lm)) lm = [lm];
       lm.forEach(m => {
-        lmHighlights[m.start.x + sizeX * m.start.y] = true;
-        lmHighlights[m.end.x + sizeX * m.end.y] = true;
+        if (V.OnBoard(m.start.x, m.start.y))
+          lmHighlights[m.start.x + sizeX * m.start.y] = true;
+        if (V.OnBoard(m.end.x, m.end.y))
+          lmHighlights[m.end.x + sizeX * m.end.y] = true;
       });
     }
     const showLight = (
@@ -709,6 +711,8 @@ export default {
 </script>
 
 <style lang="sass" scoped>
+@import "@/styles/_board_squares_img.sass";
+
 // NOTE: no variants with reserve of size != 8
 .game.reserve-div
   margin-bottom: 18px
@@ -802,5 +806,4 @@ img.ghost
   background-color: #9f9fff
 .dark-square.chesstempo.highlight-dark
   background-color: #557fff
-
 </style>