Skip to content

Commit a2f0a9e

Browse files
committed
Enhance diagram aspect ratio handling in Export-AbrDiagram function
1 parent 9126bae commit a2f0a9e

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

AsBuiltReport.System.Resources/Src/Private/Export-AbrDiagram.ps1

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,8 @@ function Export-AbrDiagram {
164164
$Graph = $DiagramObject
165165
$Diagram = New-AbrDiagram @DiagramParams -InputObject $Graph
166166
if ($Diagram) {
167-
$BestAspectRatio = Get-BestImageAspectRatio -GraphObj $Diagram -MaxWidth 600
167+
$BestAspectRatio = Get-BestImageAspectRatio -GraphObj $Diagram -MaxWidth 600 -MaxHeight 600
168+
PageBreak
168169
Section -Style Heading3 $MainDiagramLabel {
169170
Image -Base64 $Diagram -Text "$MainDiagramLabel Diagram" -Width $BestAspectRatio.Width -Height $BestAspectRatio.Height -Align Center
170171
}

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1616
- Bump AsBuiltReport.Diagram to version 1.0.5 to include latest diagramming features and improvements
1717
- Reorganize module structure - moved module files to AsBuiltReport.System.Resources/ subdirectory
1818
- Update zentered/bluesky-post-action to v0.4.0 for improved stability and performance
19+
- Enhance diagram aspect ratio handling in Export-AbrDiagram function
1920

2021
## [0.1.2] - 2026-02-22
2122

0 commit comments

Comments
 (0)