From 8d579c18cc9b57511509f24c369a586fd7b7fb8f Mon Sep 17 00:00:00 2001 From: konnorrogers Date: Fri, 1 Dec 2023 18:09:11 -0500 Subject: [PATCH] account for elements with tabbable controls --- src/components/dialog/dialog.component.ts | 4 +-- src/internal/modal.ts | 32 +++++++++++++++++++++-- src/internal/tabbable.ts | 2 +- 3 files changed, 33 insertions(+), 5 deletions(-) diff --git a/src/components/dialog/dialog.component.ts b/src/components/dialog/dialog.component.ts index 30afa3d5..6d31d02a 100644 --- a/src/components/dialog/dialog.component.ts +++ b/src/components/dialog/dialog.component.ts @@ -300,9 +300,9 @@ export default class SlDialog extends ShoelaceElement { ` : ''} ${ - '' /* The tabindex="-1" is here because the body is technically scrollable if overflowing. However, if there's no focusable elements inside, you won't actually be able to scroll it via keyboard. */ + '' /* The tabindex="-1" is here because the body is technically scrollable if overflowing. However, if there's no focusable elements inside, you won't actually be able to scroll it via keyboard. Previously this was just a , but tabindex="-1" on the slot causes children to not be focusable. https://github.com/shoelace-style/shoelace/issues/1753#issuecomment-1836803277 */ } - +