The current entry of the table of contents has no `aria-current`
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 80/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- javascript
- Área
- accessibility, frontend
Línea de trabajo
Empieza por el código de seguimiento del desplazamiento en src/resources/formats/html/quarto.js, en las líneas enlazadas, y luego revisa la representación de la tabla de contenidos y sus pruebas. Reproduce el comportamiento descrito con el documento de Quarto de dos secciones y comprueba que, al desplazarse, se actualice aria-current="location" junto con la entrada activa. La tarea está terminada cuando la entrada actual tiene el atributo y las demás entradas no.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
I have:
- searched the issue tracker for similar issues
- installed the latest version of Quarto CLI
- formatted my issue following the Bug Reports guide
Bug description
In the table of contents, Quarto marks the entry for the section in view with class="active" only.
A screen reader cannot tell which entry is current.
The class gives this information to sighted users only, which fails WCAG 4.1.2 Name, Role, Value (Level A).
The scroll tracking only adds and removes the class:
The navbar already sets aria-current="page", and #15190 reports the same gap for the sidebar link of the current page.
The table of contents needs the same, for example aria-current="location" on the active entry.
Steps to reproduce
---
title: TOC
format:
html:
toc: true
---
## One
Text.
## Two
Text.
In the rendered page, read the attributes of the entries:
[...document.querySelectorAll("#TOC .nav-link")].map((a) => [a.className, a.getAttribute("aria-current")]);
Actual behavior
[["nav-link active", null], ["nav-link", null]]
Expected behavior
The active entry has aria-current="location", and the other entries have no aria-current.
The attribute follows the active class when the reader scrolls.
Your environment
- Quarto: 99.9.9 (development build, commit 83432c0).
- Browser: Chromium (Playwright).
- OS: macOS 27.2.1.
Quarto check output
Quarto 99.9.9
[✓] Checking versions of quarto binary dependencies...
Pandoc version 3.13.0: OK
Dart Sass version 1.107.1: OK
Deno version 2.9.8: OK
Typst version 0.15.1: OK
[✓] Checking Quarto installation......OK
Version: 99.9.9
commit: 83432c028f6c07167c23f948da7067b37fe8a18b
- Lenguaje dominante
- JavaScript
- Estrellas
- 6.2k
- Forks
- 492
- Merge medio
- 13 h 51 min
- PR fusionados (30 d)
- 82
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de quarto-dev/quarto-cli
-
accessibility bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
quarto-dev/quarto-cli#15440 ·
Los mantenedores suelen responder en 1 día
-
accessibility bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
quarto-dev/quarto-cli#15439 ·
Los mantenedores suelen responder en 1 día
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
quarto-dev/quarto-cli#15431 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
-
bootstrap enhancement themes
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
quarto-dev/quarto-cli#15421 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 85/100
quarto-dev/quarto-cli#15408 ·
Los mantenedores suelen responder en 1 día
Todos los issues de quarto-dev/quarto-cli
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
crxjs/chrome-extension-tools#1261 ·
-
support
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
01 type: bug
Dificultad 1/5 Menos de una hora Aptitud para principiantes 76/100
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 1-3 horas Aptitud para principiantes 88/100
conorbronsdon/avoid-ai-writing#559 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 75/100
agentregistry-dev/website#69 ·