Skip to content

feat: rendering improvements and fullscreen mermaid diagrams#29863

Merged
MohamedH1998 merged 2 commits intoproductionfrom
feat/tweak-mermaid-diagram
Apr 15, 2026
Merged

feat: rendering improvements and fullscreen mermaid diagrams#29863
MohamedH1998 merged 2 commits intoproductionfrom
feat/tweak-mermaid-diagram

Conversation

@MohamedH1998
Copy link
Copy Markdown
Contributor

Summary

  • Adds a click-to-expand dialog for mermaid diagrams — hover to reveal the button, click to view the full diagram (with annotation footer and branding) in a full-viewport overlay. Animated open/close, keyboard/touch accessible.
  • Switches to linear edge curves, muted edge label text, and dynamic --sl-color-bg backgrounds on labels so they match the page exactly in both themes.
  • Skips all mermaid setup (including the ~2.5 MB bundle import) on pages without diagrams. Lazy-creates the dialog on first use. Adds per-diagram error handling so one broken diagram doesn't take out the rest.

Screenshots (optional)

Before
Screenshot 2026-04-14 at 21 24 36

After
Screenshot 2026-04-14 at 21 24 50
Screenshot 2026-04-14 at 21 25 02

Documentation checklist

  • Is there a changelog entry (guidelines)? If you don't add one for something awesome and new (however small) — how will our customers find out? Changelogs are automatically posted to RSS feeds, the Discord, and X.
  • The change adheres to the documentation style guide.
  • If a larger change - such as adding a new page- an issue has been opened in relation to any incorrect or out of date information that this PR fixes.
  • Files which have changed name or location have been allocated redirects.

@MohamedH1998 MohamedH1998 marked this pull request as ready for review April 14, 2026 20:25
@MohamedH1998 MohamedH1998 requested review from a team and kodster28 as code owners April 14, 2026 20:25
@github-actions
Copy link
Copy Markdown
Contributor

This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:

Pattern Owners
*.ts @cloudflare/content-engineering, @kodster28
* @cloudflare/pcx-technical-writing, @cloudflare/product-owners

@github-actions
Copy link
Copy Markdown
Contributor

@MohamedH1998 MohamedH1998 merged commit 18e417c into production Apr 15, 2026
13 checks passed
@MohamedH1998 MohamedH1998 deleted the feat/tweak-mermaid-diagram branch April 15, 2026 09:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants