- parseFen(fen) {
- const fenParts = fen.split(" ");
- return {
- position: fenParts[0],
- marks: fenParts[1],
- orientation: fenParts[2],
- shadow: fenParts[3]
- };
- },
- // Method to replace diagrams in loaded HTML
- replaceByDiag: function(match, p1, p2) {
- const args = this.parseFen(p2);
- return getDiagram(args);
- },