diff --git a/ci/release/changelogs/next.md b/ci/release/changelogs/next.md index 196c9227e2..823e8dd45a 100644 --- a/ci/release/changelogs/next.md +++ b/ci/release/changelogs/next.md @@ -9,3 +9,4 @@ #### Bugfixes ⛑️ - Fixes edge case in compiler using dots in quotes [#1401](https://github.com/terrastruct/d2/pull/1401) +- Fixes grid label font size for TALA [#1412](https://github.com/terrastruct/d2/pull/1412) diff --git a/d2graph/d2graph.go b/d2graph/d2graph.go index 76046e3773..409e59cf05 100644 --- a/d2graph/d2graph.go +++ b/d2graph/d2graph.go @@ -584,7 +584,8 @@ func (obj *Object) Text() *d2target.MText { } if obj.OuterSequenceDiagram() == nil { - if obj.IsContainer() && obj.Shape.Value != "text" { + // Note: during grid layout when children are temporarily removed `IsContainer` is false + if (obj.IsContainer() || obj.IsGridDiagram()) && obj.Shape.Value != "text" { fontSize = obj.Level().LabelSize() } } else {