From a3ed06699fca657ce045dffa3a8ade5ff99012b0 Mon Sep 17 00:00:00 2001 From: Copilot <198982749+Copilot@users.noreply.github.com> Date: Sun, 7 Dec 2025 23:13:38 +0100 Subject: [PATCH] Add alt attribute to speed test results image for accessibility (#731) * Initial plan * Add ALT attribute to SpeedTest result image for accessibility Co-authored-by: sstidl <12804296+sstidl@users.noreply.github.com> * Add alt attribute to docker/ui.php for accessibility Co-authored-by: sstidl <12804296+sstidl@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: sstidl <12804296+sstidl@users.noreply.github.com> --- docker/ui.php | 1 + examples/example-multipleServers-full.html | 1 + index.html | 1 + 3 files changed, 3 insertions(+) diff --git a/docker/ui.php b/docker/ui.php index 4f2d697..7310d2a 100755 --- a/docker/ui.php +++ b/docker/ui.php @@ -163,6 +163,7 @@ function startStop(){ if(testId!=null){ var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId; I("resultsImg").src=shareURL; + I("resultsImg").alt="Download: "+uiData.dlStatus+" Mbps, Upload: "+uiData.ulStatus+" Mbps, Ping: "+uiData.pingStatus+" ms, Jitter: "+uiData.jitterStatus+" ms"; I("resultsURL").value=shareURL; I("testId").innerHTML=testId; I("shareArea").style.display=""; diff --git a/examples/example-multipleServers-full.html b/examples/example-multipleServers-full.html index ed59473..ddf23fc 100755 --- a/examples/example-multipleServers-full.html +++ b/examples/example-multipleServers-full.html @@ -147,6 +147,7 @@ function startStop(){ if(testId!=null){ var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId; I("resultsImg").src=shareURL; + I("resultsImg").alt="Download: "+uiData.dlStatus+" Mbps, Upload: "+uiData.ulStatus+" Mbps, Ping: "+uiData.pingStatus+" ms, Jitter: "+uiData.jitterStatus+" ms"; I("resultsURL").value=shareURL; I("testId").innerHTML=testId; I("shareArea").style.display=""; diff --git a/index.html b/index.html index 120ea56..660a7e2 100755 --- a/index.html +++ b/index.html @@ -155,6 +155,7 @@ function startStop(){ if(testId!=null){ var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId; I("resultsImg").src=shareURL; + I("resultsImg").alt="Download: "+uiData.dlStatus+" Mbps, Upload: "+uiData.ulStatus+" Mbps, Ping: "+uiData.pingStatus+" ms, Jitter: "+uiData.jitterStatus+" ms"; I("resultsURL").value=shareURL; I("testId").innerHTML=testId; I("shareArea").style.display="";