Updated the `HealthCheckHtmlGenerator` class to change the HTML auto-refresh countdown display from 10 seconds to 3 seconds. Adjusted the `countdown` variable in `health-ui.js` to initialize with 3 seconds, ensuring consistency between the frontend logic and the displayed countdown timer.
16 lines
288 B
JavaScript
16 lines
288 B
JavaScript
let countdown = 3;
|
|
|
|
function updateCountdown() {
|
|
document.getElementById('countdown').innerText = countdown;
|
|
countdown--;
|
|
if (countdown < 0) {
|
|
location.reload();
|
|
}
|
|
}
|
|
|
|
function autoRefresh() {
|
|
setInterval(updateCountdown, 1000);
|
|
}
|
|
|
|
window.onload = autoRefresh;
|