apply font-size to rendered code blocks
This commit is contained in:
parent
f35ba8e86b
commit
65d03f2ffc
1 changed files with 3 additions and 1 deletions
|
|
@ -1267,7 +1267,9 @@ func drawShape(writer, appendixWriter io.Writer, diagramHash string, targetShape
|
||||||
if !isLight {
|
if !isLight {
|
||||||
class = "dark-code"
|
class = "dark-code"
|
||||||
}
|
}
|
||||||
fmt.Fprintf(writer, `<g transform="translate(%f %f)" class="%s">`, box.TopLeft.X, box.TopLeft.Y, class)
|
fmt.Fprintf(writer, `<g transform="translate(%f %f)" class="%s" style="font-size:%v">`,
|
||||||
|
box.TopLeft.X, box.TopLeft.Y, class, targetShape.FontSize,
|
||||||
|
)
|
||||||
rectEl := d2themes.NewThemableElement("rect")
|
rectEl := d2themes.NewThemableElement("rect")
|
||||||
rectEl.Width = float64(targetShape.Width)
|
rectEl.Width = float64(targetShape.Width)
|
||||||
rectEl.Height = float64(targetShape.Height)
|
rectEl.Height = float64(targetShape.Height)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue