Add dpi parameter to New-AbrDiagram and Icon size parameters to Add-HtmlNodeTable#27
Merged
Conversation
Expose the Graphviz dpi graph attribute so raster (PNG/JPG) output resolution can be set explicitly instead of being fixed at the Graphviz default of 96. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
The icon <TD> for a regular (non-subgraph) node had no width/height/fixedsize attribute, so its rendered size was derived purely from the source image's pixel count interpreted as Graphviz points. This made resizing the source PNG an unreliable way to control on-page icon size. Mirrors the existing SubgraphIconWidth/SubgraphIconHeight pattern.
|
PSScriptAnalyzer results: Errors: [0], Warnings: [53], Information: [6]
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds two small enhancements to the diagram engine, both needed to support higher-quality, properly-sized Management Group hierarchy diagrams in a downstream report module (AsBuiltReport.Microsoft.Azure):
Neither change alters default behaviour. Both parameters are optional and a no-op when omitted.
Related Issue
N/A. This is enhancement work identified while improving diagram quality in a consuming report module, not tied to a tracked issue.
Motivation and Context
A consuming report module (AsBuiltReport.Microsoft.Azure) renders a Management Group hierarchy diagram using Add-HtmlNodeTable and New-AbrDiagram. Two problems surfaced:
Both parameters give consumers explicit, predictable control over these two visual properties.
How Has This Been Tested?
Manual testing via direct module import and rendering (no automated Pester tests added, these are additive, optional parameters):
Screenshots (if appropriate):
Types of changes
Checklist: