Skip to content

Fix mermaid fullscreen overlay accessibility and add stable data-streamdown attribute#507

Open
aradhyacp wants to merge 2 commits intovercel:mainfrom
aradhyacp:mermaid-overlay-issue
Open

Fix mermaid fullscreen overlay accessibility and add stable data-streamdown attribute#507
aradhyacp wants to merge 2 commits intovercel:mainfrom
aradhyacp:mermaid-overlay-issue

Conversation

@aradhyacp
Copy link
Copy Markdown
Contributor

Description

This PR fixes accessibility and consistency issues in the mermaid fullscreen overlay by aligning it with the existing table fullscreen implementation. It also introduces a stable attribute for external styling and tooling.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Performance improvement
  • Refactoring (no functional changes)

Related Issues

Fixes #506
Closes #506
Related to #506

Changes Made

  • Added data-streamdown="mermaid-fullscreen" to the fullscreen overlay for stable CSS targeting
  • Updated overlay semantics from role="button" to role="dialog"
  • Added aria-modal="true" to improve screen reader modal behavior
  • Aligned mermaid fullscreen overlay behavior with table fullscreen implementation

Testing

  • All existing tests pass
  • Added new tests for the changes
  • Manually tested the changes

Test Coverage

N/A (UI-only accessibility and structural change)

Screenshots/Demos

Checklist

  • My code follows the project's code style
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings or errors
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have created a changeset (pnpm changeset)

Changeset

  • I have created a changeset for these changes

Additional Notes

This change brings parity between mermaid and table fullscreen overlays and improves accessibility compliance for modal behavior in screen readers.

@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Apr 16, 2026

@aradhyacp is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Mermaid fullscreen overlay missing data-streamdown attribute and accessibility attributes

1 participant