Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ export const EnableFocusWrapWithoutSentinels = (args) => {
<span>
This story is rendered with{' '}
<LinkTo title="Getting Started/Feature Flags" name="Overview">
enable-preview-focus-wrap-without-sentinels
enable-focus-wrap-without-sentinels
</LinkTo>{' '}
enabled
</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -613,6 +613,7 @@ const ComposedModalDialog = React.forwardRef<
{/* Non-translatable: Focus-wrap code makes this `<button>` not actually read by screen readers */}
{!focusTrapWithoutSentinels && (
<button
aria-hidden="true"
type="button"
ref={startSentinel}
className={`${prefix}--visually-hidden`}>
Expand All @@ -634,6 +635,7 @@ const ComposedModalDialog = React.forwardRef<
{/* Non-translatable: Focus-wrap code makes this `<button>` not actually read by screen readers */}
{!focusTrapWithoutSentinels && (
<button
aria-hidden="true"
type="button"
ref={endSentinel}
className={`${prefix}--visually-hidden`}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export const EnableFocusWrapWithoutSentinels = () => {
<span>
This story is rendered with{' '}
<LinkTo title="Getting Started/Feature Flags" name="Overview">
enable-preview-focus-wrap-without-sentinels
enable-focus-wrap-without-sentinels
</LinkTo>{' '}
enabled
</span>
Expand Down
2 changes: 2 additions & 0 deletions packages/react/src/components/Modal/Modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -770,6 +770,7 @@ const ModalDialog = React.forwardRef(function ModalDialog(
{/* Non-translatable: Focus-wrap code makes this `<span>` not actually read by screen readers */}
{!enableDialogElement && !focusTrapWithoutSentinels && (
<span
aria-hidden="true"
ref={startTrap}
tabIndex={0}
role="link"
Expand Down Expand Up @@ -865,6 +866,7 @@ const ModalDialog = React.forwardRef(function ModalDialog(
{/* Non-translatable: Focus-wrap code makes this `<span>` not actually read by screen readers */}
{!enableDialogElement && !focusTrapWithoutSentinels && (
<span
aria-hidden="true"
ref={endTrap}
tabIndex={0}
role="link"
Expand Down
2 changes: 2 additions & 0 deletions packages/react/src/components/Notification/Notification.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1046,6 +1046,7 @@ export function ActionableNotification({
onKeyDown={focusTrapWithoutSentinels ? handleKeyDown : () => {}}>
{!focusTrapWithoutSentinels && (
<span
aria-hidden="true"
ref={startTrap}
tabIndex={0}
role="link"
Expand Down Expand Up @@ -1110,6 +1111,7 @@ export function ActionableNotification({
</div>
{!focusTrapWithoutSentinels && (
<span
aria-hidden="true"
ref={endTrap}
tabIndex={0}
role="link"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ exports[`ActionableNotification should render 1`] = `
role="alertdialog"
>
<span
aria-hidden="true"
class="cds--visually-hidden"
role="link"
tabindex="0"
Expand Down Expand Up @@ -81,6 +82,7 @@ exports[`ActionableNotification should render 1`] = `
</button>
</div>
<span
aria-hidden="true"
class="cds--visually-hidden"
role="link"
tabindex="0"
Expand Down
2 changes: 2 additions & 0 deletions packages/react/src/internal/FloatingMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,7 @@ export const FloatingMenu = ({
{/* Non-translatable: Focus management code makes this `<span>` not actually read by screen readers */}
{!focusTrapWithoutSentinels && (
<span
aria-hidden="true"
ref={startSentinelRef}
tabIndex={0}
role="link"
Expand All @@ -531,6 +532,7 @@ export const FloatingMenu = ({
{/* Non-translatable: Focus management code makes this `<span>` not actually read by screen readers */}
{!focusTrapWithoutSentinels && (
<span
aria-hidden="true"
ref={endSentinelRef}
tabIndex={0}
role="link"
Expand Down
Loading