cm-chessboard 5.2.5 → 5.2.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -315,10 +315,12 @@ To allow easy removing of the marker, you have to define the marker type in your
315
315
  const myMarkerType = {class: "myMarkerCssClass", slice: "myMarkerIdInSvg"}
316
316
  // add
317
317
  chessboard.addMarker(myMarkerType, "e4")
318
- // remove
318
+ // remove a specific marker
319
319
  chessboard.removeMarkers(myMarkerType, "e4")
320
320
  // remove all "myMarkerType"
321
- chessboard.removeMarkers(myMarkerType, undefined)
321
+ chessboard.removeMarkers(myMarkerType)
322
+ // remove all markers
323
+ chessboard.removeMarkers()
322
324
  ```
323
325
 
324
326
  ## Extensions
@@ -32,10 +32,11 @@ const chessboard = new Chessboard(document.getElementById("board"), {
32
32
 
33
33
  }]
34
34
  })
35
- chessboard.addArrow(ARROW_TYPE.default, "f3", "d5");
36
- chessboard.addArrow(ARROW_TYPE.default, "b8", "c6");
37
- chessboard.addArrow(ARROW_TYPE.pointy, "d2", "d3");
38
- chessboard.addArrow(ARROW_TYPE.danger, "g5", "e6");
35
+ chessboard.addArrow(ARROW_TYPE.default, "f3", "d5")
36
+ chessboard.addArrow(ARROW_TYPE.default, "b8", "c6")
37
+ chessboard.addArrow(ARROW_TYPE.pointy, "d2", "d3")
38
+ chessboard.addArrow(ARROW_TYPE.danger, "g5", "e6")
39
+ console.log(chessboard.getArrows())
39
40
  </pre>
40
41
  <h2>Methods</h2>
41
42
  <h3><code>addArrow(type, from, to)</code></h3>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cm-chessboard",
3
- "version": "5.2.5",
3
+ "version": "5.2.7",
4
4
  "description": "A JavaScript chessboard which is lightweight, ES6 module based, responsive, SVG rendered and without dependencies.",
5
5
  "keywords": [
6
6
  "chess",