]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-125933: Add ARIA labels to select elements in the version switcher (#125934)
authorKerim Kabirov <the.privat33r+gh@pm.me>
Thu, 24 Oct 2024 20:52:21 +0000 (22:52 +0200)
committerGitHub <noreply@github.com>
Thu, 24 Oct 2024 20:52:21 +0000 (23:52 +0300)
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Doc/tools/static/rtd_switcher.js

index f5dc7045a0dbc4ec53e2b203c3751695b03e542e..2bf01a002db90c856d7fe96ed104eefad59391bc 100644 (file)
@@ -7,7 +7,7 @@
  document.addEventListener("readthedocs-addons-data-ready", function(event) {
    const config = event.detail.data()
    const versionSelect = `
-   <select id="version_select">
+   <select id="version_select" aria-label="Python version">
    ${ config.versions.active.map(
        (version) => `
        <option
@@ -25,7 +25,7 @@
    languages = languages.sort((a, b) => a.language.name.localeCompare(b.language.name));
 
    const languageSelect = `
-   <select id="language_select">
+   <select id="language_select" aria-label="Language">
    ${ languages.map(
        (translation) => `
        <option