From 732b5661ea0074f419965e9c6f42b8e77dae8f6a Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Tue, 26 Sep 2023 10:54:02 -0700 Subject: [PATCH] tools: add navigation ARIA landmark to generated API ToC As an accessibility improvement, specify the navigation landmark for the element of our docs that contains the table of contents generated for the specific API page. Ref: https://www.w3.org/WAI/ARIA/apg/practices/landmark-regions/ Ref: https://www.w3.org/WAI/WCAG21/Techniques/aria/ARIA20.html PR-URL: https://github.com/nodejs/node/pull/49882 Reviewed-By: Luigi Pinca Reviewed-By: Claudio Wunder Reviewed-By: LiviaMedeiros --- tools/doc/html.mjs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/doc/html.mjs b/tools/doc/html.mjs index 168f68c1b03f21..95782efe03d554 100644 --- a/tools/doc/html.mjs +++ b/tools/doc/html.mjs @@ -467,7 +467,7 @@ export function buildToc({ filename, apilinks }) { .use(htmlStringify) .processSync(toc).toString(); - file.toc = `
Table of contents${inner}
`; + file.toc = ``; file.tocPicker = `
${inner}
`; } else { file.toc = file.tocPicker = '';