diff --git a/d2renderers/d2svg/github-markdown.css b/d2renderers/d2svg/github-markdown.css index 49e1dfaa8..587fdfd84 100644 --- a/d2renderers/d2svg/github-markdown.css +++ b/d2renderers/d2svg/github-markdown.css @@ -258,9 +258,6 @@ .md kbd { display: inline-block; padding: 3px 5px; - font: 11px ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, - monospace; - line-height: 10px; color: var(--color-fg-default); vertical-align: middle; background-color: var(--color-canvas-subtle); @@ -345,15 +342,9 @@ margin-left: 0; } -/* .md tt, -.md code { - font-size: 12px; -} */ - .md pre { margin-top: 0; margin-bottom: 0; - /* font-size: 12px; */ word-wrap: normal; } diff --git a/d2renderers/textmeasure/markdown.go b/d2renderers/textmeasure/markdown.go index 69474d92f..3b538759b 100644 --- a/d2renderers/textmeasure/markdown.go +++ b/d2renderers/textmeasure/markdown.go @@ -242,11 +242,8 @@ func (ruler *Ruler) measureNode(depth int, n *html.Node, font d2fonts.Font) (wid w *= FontSize_pre_code_em h *= FontSize_pre_code_em } - // fmt.Printf("%d:'%s' width %v (%v) height %v fontStyle %s fontSize %v family %v\n", depth, n.Data, w, w+spaceWidths, h, font.Style, font.Size, font.Family) - return w + spaceWidths, h, 0, 0 case html.ElementNode: - // fmt.Printf("%d: %v node\n", depth, n.Data) switch n.Data { case "h1", "h2", "h3", "h4", "h5", "h6": font = HeaderFonts[n.Data] @@ -352,7 +349,6 @@ func (ruler *Ruler) measureNode(depth int, n *html.Node, font d2fonts.Font) (wid if height > 0 && height < MarkdownLineHeightPx { height = MarkdownLineHeightPx } - // fmt.Printf("%d:%s width %v height %v mt %v mb %v\n", depth, n.Data, width, height, marginTop, marginBottom) } return width, height, marginTop, marginBottom } diff --git a/e2etests/testdata/stable/chaos2/sketch.exp.svg b/e2etests/testdata/stable/chaos2/sketch.exp.svg index baabef123..2eed01a57 100644 --- a/e2etests/testdata/stable/chaos2/sketch.exp.svg +++ b/e2etests/testdata/stable/chaos2/sketch.exp.svg @@ -272,9 +272,6 @@ width="1317" height="1854" viewBox="-100 -100 1317 1854">