From be1098269d04fc0ed0a30317b4957e029994d1cb Mon Sep 17 00:00:00 2001 From: Noah Burroughs <49932437+noahsb@users.noreply.github.com> Date: Wed, 30 Nov 2022 12:37:17 -0800 Subject: [PATCH] [docs] Update Drawer accessibility section (#3087) Describe new aria-* attribute support from #3027 --- docs/src/docs/core/Drawer.mdx | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/docs/src/docs/core/Drawer.mdx b/docs/src/docs/core/Drawer.mdx index d714e986b99..fdf466f62f5 100644 --- a/docs/src/docs/core/Drawer.mdx +++ b/docs/src/docs/core/Drawer.mdx @@ -64,21 +64,8 @@ By default: - When drawer is opened focus is trapped inside and document.body scroll is locked in current position - When user clicks on overlay or presses escape drawer is closed - Drawer transitions use disabled when user prefers to reduce motion -- Drawer body has `aria-modal` and `role="dialog"` attributes - -Add [aria-labelledby](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-labelledby), [aria-describedby](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-describedby) -and `closeButtonLabel` props for better screen readers support: - -```tsx - -

Title

-
Body
-
-``` +- Drawer wrapper has `aria-modal="true"` and `role="dialog"` attributes +- Drawer wrapper has `aria-labelledby` and `aria-describedby` pointing to drawer title and body ## Initial focus