Bugfixes and tooltips for full-calc ui.
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 49s
All checks were successful
Build and Push Docker Image / build-and-push (push) Successful in 49s
This commit is contained in:
@@ -38,11 +38,11 @@ func GetScoreByPlayerID(c *gin.Context) {
|
||||
case 200:
|
||||
c.String(200, fmt.Sprintf("%.2f", score))
|
||||
case 404:
|
||||
c.String(200, "<i class=\"bi bi-person-x-fill me-2 text-danger fs-5\" style=\"margin-left: 0.69rem;\"></i>")
|
||||
c.String(200, "<i class=\"bi bi-person-x-fill me-2 text-danger fs-5\" style=\"margin-left: 0.69rem;\" data-bs-action=\"tooltip\" data-bs-title=\"Spieler nicht gefunden\"></i>")
|
||||
case 503, 504:
|
||||
c.String(statusCode, "<i class=\"bi bi-cloud-slash-fill me-2 text-danger fs-5\" style=\"margin-left: 0.69rem;\"></i>")
|
||||
c.String(statusCode, "<i class=\"bi bi-cloud-slash-fill me-2 text-danger fs-5\" style=\"margin-left: 0.69rem;\"data-bs-action=\"tooltip\" data-bs-title=\"Tracker nicht erreichbar\"></i>")
|
||||
default:
|
||||
c.String(statusCode, "<i class=\"bi bi-exclamation-circle-fill me-2 text-danger fs-5\" style=\"margin-left: 0.69rem;\"></i>")
|
||||
c.String(statusCode, "<i class=\"bi bi-exclamation-circle-fill me-2 text-danger fs-5\" style=\"margin-left: 0.69rem;\" data-bs-action=\"tooltip\" data-bs-title=\"Unbekannter Fehler\"></i>")
|
||||
utils.Logger.Warnf("[SCORE] Invalid request! Player: %s, Score: %f", player.Name, score)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,19 +23,19 @@
|
||||
</div>
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-3 text-center fs-5 me-4 ps-0">
|
||||
<img src="../static/icons/average.svg" alt="Avg" class="img-fluid me-1 align-top" style="height: 1.8rem; filter: invert(0.85);"/>
|
||||
<img src="../static/icons/average.svg" alt="Avg" class="img-fluid me-1 align-top" style="height: 1.8rem; filter: invert(0.85);" data-bs-action="tooltip" data-bs-title="Durchschnitt Heim-Team" />
|
||||
<span id="home-avg-score" class="text-warning">
|
||||
<i class="spinner-grow spinner-grow-sm text-secondary align-baseline mx-2" role="status"></i>
|
||||
</span>
|
||||
</div>
|
||||
<div class="col-2 text-center fs-5">
|
||||
<i class="bi bi-plus-slash-minus me-2"></i>
|
||||
<i class="bi bi-plus-slash-minus me-2" data-bs-action="tooltip" data-bs-title="Differenz der Durchschnitte" ></i>
|
||||
<span id="diff-score" class="text-warning">
|
||||
<i class="spinner-grow spinner-grow-sm text-secondary align-baseline mx-2" role="status"></i>
|
||||
</span>
|
||||
</div>
|
||||
<div class="col-3 text-center fs-5 ms-4 pe-0">
|
||||
<img src="../static/icons/average.svg" alt="Avg" class="img-fluid me-1 align-top" style="height: 1.8rem; filter: invert(0.85);"/>
|
||||
<img src="../static/icons/average.svg" alt="Avg" class="img-fluid me-1 align-top" style="height: 1.8rem; filter: invert(0.85);" data-bs-action="tooltip" data-bs-title="Durchschnitt Gegner-Team" />
|
||||
<span id="opp-avg-score" class="text-warning">
|
||||
<i class="spinner-grow spinner-grow-sm text-secondary align-baseline mx-2" role="status"></i>
|
||||
</span>
|
||||
@@ -47,7 +47,7 @@
|
||||
<div class="progress w-100" style="height: 30px;" id="fullCalcProgressbar" role="progressbar">
|
||||
<div class="progress-bar progress-bar-striped progress-bar-animated" style="width: 0">Lade...</div>
|
||||
</div>
|
||||
<button type="submit" name="submit" class="btn btn-lg btn-outline-primary" onclick="downloadScreenshot()" hidden>
|
||||
<button type="submit" name="submit" class="btn btn-lg btn-outline-primary" onclick="downloadScreenshot()" data-bs-action="tooltip" data-bs-title="Als Bild herunterladen" hidden>
|
||||
<i class="bi bi-download"></i>
|
||||
</button>
|
||||
</div>
|
||||
@@ -85,6 +85,8 @@
|
||||
score.innerHTML = text;
|
||||
if (!isNaN(parseFloat(text)))
|
||||
score.previousElementSibling.hidden = false;
|
||||
else
|
||||
initTooltips(score);
|
||||
return text;
|
||||
});
|
||||
}
|
||||
@@ -239,7 +241,7 @@
|
||||
}
|
||||
|
||||
function cleanupStatistic(statisticField) {
|
||||
if (statisticField.innerHTML === spinnerGrow)
|
||||
if (statisticField.innerHTML.trim() === spinnerGrow)
|
||||
statisticField.innerHTML = dash;
|
||||
}
|
||||
|
||||
@@ -299,11 +301,15 @@
|
||||
|
||||
Promise.all(promises).then(_ => {
|
||||
let liItems = homeClanResults.querySelectorAll('li');
|
||||
liItems[liItems.length - 1].classList.remove('border-bottom');
|
||||
liItems[liItems.length - 2].classList.remove('border-bottom');
|
||||
if (liItems.length > 1) {
|
||||
liItems[liItems.length - 1].classList.remove('border-bottom');
|
||||
liItems[liItems.length - 2].classList.remove('border-bottom');
|
||||
}
|
||||
liItems = oppClanResults.querySelectorAll('li');
|
||||
liItems[liItems.length - 1].classList.remove('border-bottom');
|
||||
liItems[liItems.length - 2].classList.remove('border-bottom');
|
||||
if (liItems.length > 1) {
|
||||
liItems[liItems.length - 1].classList.remove('border-bottom');
|
||||
liItems[liItems.length - 2].classList.remove('border-bottom');
|
||||
}
|
||||
|
||||
setSquadNumbers();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user