move dashboard script block content into own files with new classes to update, render to have a better code overview
Build and Push Docker Container / build-and-push (push) Successful in 3m55s

This commit is contained in:
2026-04-07 03:25:10 +02:00
parent 03968fecdf
commit 739c0520f9
11 changed files with 1261 additions and 1269 deletions
+14
View File
@@ -0,0 +1,14 @@
class MoveTable {
static buildScoresRows(reasoning) {
const scores = reasoning && typeof reasoning === "object" ? reasoning.scores : null;
const moveOrder = ["up", "down", "left", "right"];
return moveOrder.map((move) => {
const hasScore = scores
&& typeof scores === "object"
&& !Array.isArray(scores)
&& Object.prototype.hasOwnProperty.call(scores, move);
const value = hasScore ? scores[move] : "-";
return `<tr><td>${move}</td><td>${Utils.safeString(value)}</td></tr>`;
}).join("");
}
}