Skip to content

Mermaid diagrams: remove the yellow fill, add missing tutorial diagrams - #25

Merged
paolosalvatori merged 1 commit into
mainfrom
mermaid-diagrams
Aug 6, 2026
Merged

Mermaid diagrams: remove the yellow fill, add missing tutorial diagrams#25
paolosalvatori merged 1 commit into
mainfrom
mermaid-diagrams

Conversation

@paolosalvatori

Copy link
Copy Markdown
Collaborator

Motivation

Every mermaid diagram in the repository rendered its subgraphs with mermaid's default cluster fill, #ffffde, a pale yellow that looks wrong on GitHub in both light and dark themes.

Several tutorials also had no diagram at all, so the only way to understand their topology was to read the script list.

Changes

The yellow is gone. All five existing diagrams (three KEDA tutorials, the Terraform and Bicep tags/labels/taints tutorials) now carry one directive:

%%{init: {'themeVariables': {'clusterBkg': 'transparent', 'clusterBorder': '#8c8c8c'}}}%%

transparent rather than white on purpose: a subgraph then takes the page background, so it reads correctly in GitHub's dark theme as well, while keeping its border and label.

Two new diagrams, for the tutorials that had none:

  • tutorials/ccm/scripts: the cloud controller manager watching Service objects and reconciling the kubernetes and kubernetes-internal load balancers, the public IP and the NSG rule in the node resource group, then writing EXTERNAL-IP back.
  • tutorials/gateway-api/scripts: the managed add-on supplying only the CRDs, NGINX Gateway Fabric claiming the nginx GatewayClass and provisioning a per-Gateway data plane, and the request path through the port-forward to the echo-server Service.

Testing

Every mermaid block in the repository was extracted and rendered with the mermaid CLI before committing, because a diagram that does not compile is worse than no diagram. 7 of 7 render, and grepping the rendered SVGs for #ffffde now returns nothing (it returned 5 hits before).

The renderer runs in a container (minlag/mermaid-cli), since the host mmdc has no Chrome available.

More tutorial diagrams (the KEDA index, Key Vault CSI driver, and the network-policy tutorials) are on the way as follow-up commits to this branch.

Copilot AI lite review requested due to automatic review settings August 6, 2026 13:30
…API diagrams

Every subgraph rendered with mermaid's default cluster fill (#ffffde), a pale yellow that fights the
page in both GitHub themes. All five existing diagrams now set clusterBkg to transparent, so a
subgraph keeps its border and label and takes the page background in light and dark mode alike.

Adds diagrams to the two tutorials that had none: the cloud controller manager reconciling Services
into node-resource-group load balancers, public IPs and NSG rules, and the Gateway API tutorial where
the managed add-on supplies only the CRDs while NGINX Gateway Fabric claims the GatewayClass and
serves the traffic.

Every diagram in the repository was rendered with the mermaid CLI before committing: 7 of 7 render,
and no rendered SVG carries the yellow any more.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves tutorial documentation by standardizing Mermaid diagram styling to remove Mermaid’s default yellow subgraph fill (improving GitHub light/dark theme rendering) and by adding missing architecture diagrams to tutorials that previously lacked them.

Changes:

  • Added a Mermaid init directive to existing diagrams to make cluster backgrounds transparent and set a consistent cluster border color.
  • Added new “Architecture” sections with Mermaid diagrams to the CCM scripts tutorial and the Gateway API scripts tutorial.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tutorials/terraform/tags-labels-taints/README.md Adds Mermaid theme init directive to remove default cluster fill.
tutorials/keda/service-bus/README.md Adds Mermaid theme init directive to remove default cluster fill.
tutorials/keda/queue-storage/README.md Adds Mermaid theme init directive to remove default cluster fill.
tutorials/keda/event-hubs/README.md Adds Mermaid theme init directive to remove default cluster fill.
tutorials/gateway-api/scripts/README.md Adds an Architecture section with a new Mermaid diagram + theme init directive.
tutorials/ccm/scripts/README.md Adds an Architecture section with a new Mermaid diagram + theme init directive.
tutorials/bicep/tags-labels-taints/README.md Adds Mermaid theme init directive to remove default cluster fill.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@paolosalvatori
paolosalvatori merged commit e60e5ce into main Aug 6, 2026
1 check passed
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.

2 participants