main: Don't render board containers in renderPDF
cc @berniexie
This commit is contained in:
parent
e4fac7840f
commit
65437b954d
2 changed files with 28 additions and 25 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -6,3 +6,4 @@
|
|||
e2e_report.html
|
||||
bin
|
||||
out
|
||||
d2
|
||||
|
|
|
|||
2
main.go
2
main.go
|
|
@ -457,6 +457,7 @@ func renderPDF(ctx context.Context, ms *xmain.State, plugin d2plugin.Plugin, ske
|
|||
currBoardPath = append(boardPath, diagram.Name)
|
||||
}
|
||||
|
||||
if !diagram.BoardContainer {
|
||||
svg, err = d2svg.Render(diagram, &d2svg.RenderOpts{
|
||||
Pad: int(pad),
|
||||
Sketch: sketch,
|
||||
|
|
@ -487,6 +488,7 @@ func renderPDF(ctx context.Context, ms *xmain.State, plugin d2plugin.Plugin, ske
|
|||
if err != nil {
|
||||
return svg, err
|
||||
}
|
||||
}
|
||||
|
||||
for _, dl := range diagram.Layers {
|
||||
_, err := renderPDF(ctx, ms, plugin, sketch, pad, "", page, ruler, dl, pdf, currBoardPath)
|
||||
|
|
|
|||
Loading…
Reference in a new issue