Explorar el Código

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 <[email protected]>

* Add alt attribute to docker/ui.php for accessibility

Co-authored-by: sstidl <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: sstidl <[email protected]>
Copilot hace 2 semanas
padre
commit
a3ed06699f
Se han modificado 3 ficheros con 3 adiciones y 0 borrados
  1. 1 0
      docker/ui.php
  2. 1 0
      examples/example-multipleServers-full.html
  3. 1 0
      index.html

+ 1 - 0
docker/ui.php

@@ -163,6 +163,7 @@ function startStop(){
                     if(testId!=null){
                     if(testId!=null){
                         var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId;
                         var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId;
                         I("resultsImg").src=shareURL;
                         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("resultsURL").value=shareURL;
                         I("testId").innerHTML=testId;
                         I("testId").innerHTML=testId;
                         I("shareArea").style.display="";
                         I("shareArea").style.display="";

+ 1 - 0
examples/example-multipleServers-full.html

@@ -147,6 +147,7 @@ function startStop(){
                     if(testId!=null){
                     if(testId!=null){
                         var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId;
                         var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId;
                         I("resultsImg").src=shareURL;
                         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("resultsURL").value=shareURL;
                         I("testId").innerHTML=testId;
                         I("testId").innerHTML=testId;
                         I("shareArea").style.display="";
                         I("shareArea").style.display="";

+ 1 - 0
index.html

@@ -155,6 +155,7 @@ function startStop(){
                     if(testId!=null){
                     if(testId!=null){
                         var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId;
                         var shareURL=window.location.href.substring(0,window.location.href.lastIndexOf("/"))+"/results/?id="+testId;
                         I("resultsImg").src=shareURL;
                         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("resultsURL").value=shareURL;
                         I("testId").innerHTML=testId;
                         I("testId").innerHTML=testId;
                         I("shareArea").style.display="";
                         I("shareArea").style.display="";