diff --git a/ci/release/changelogs/next.md b/ci/release/changelogs/next.md
index ab1a84721..6d3818955 100644
--- a/ci/release/changelogs/next.md
+++ b/ci/release/changelogs/next.md
@@ -10,3 +10,4 @@
- Fixed an issue where text could overflow in sql_table shapes. [#458](https://github.com/terrastruct/d2/pull/458)
- Fixed an issue with elk layouts accounting for edge labels as if they were placed on the side of the edge. [#483](https://github.com/terrastruct/d2/pull/483)
- Fixed an issue where dagre layouts may not have enough spacing for all edge labels. [#484](https://github.com/terrastruct/d2/pull/484)
+- Fixed connections being clipped if they were at the very top or left edges of the diagram. [#493](https://github.com/terrastruct/d2/pull/493)
diff --git a/d2renderers/d2svg/d2svg.go b/d2renderers/d2svg/d2svg.go
index 41a0c63a6..5083005fd 100644
--- a/d2renderers/d2svg/d2svg.go
+++ b/d2renderers/d2svg/d2svg.go
@@ -383,32 +383,6 @@ func drawConnection(writer io.Writer, labelMaskID string, connection d2target.Co
labelTL.Y = math.Round(labelTL.Y)
if label.Position(connection.LabelPosition).IsOnEdge() {
- strokeWidth := float64(connection.StrokeWidth)
- tl, br := geo.Route(connection.Route).GetBoundingBox()
- tl.X -= strokeWidth
- tl.Y -= strokeWidth
- br.X += strokeWidth
- br.Y += strokeWidth
- if connection.SrcArrow != d2target.NoArrowhead {
- width, height := arrowheadDimensions(connection.SrcArrow, strokeWidth)
- tl.X -= width
- tl.Y -= height
- br.X += width
- br.Y += height
- }
- if connection.DstArrow != d2target.NoArrowhead {
- width, height := arrowheadDimensions(connection.DstArrow, strokeWidth)
- tl.X -= width
- tl.Y -= height
- br.X += width
- br.Y += height
- }
-
- tl.X = math.Min(tl.X, labelTL.X)
- tl.Y = math.Min(tl.Y, labelTL.Y)
- br.X = math.Max(br.X, labelTL.X+float64(connection.LabelWidth))
- br.Y = math.Max(br.Y, labelTL.Y+float64(connection.LabelHeight))
-
labelMask = makeLabelMask(labelTL, connection.LabelWidth, connection.LabelHeight)
}
}
@@ -1035,12 +1009,11 @@ func Render(diagram *d2target.Diagram, pad int) ([]byte, error) {
// Note: we always want this since we reference it on connections even if there end up being no masked labels
fmt.Fprint(buf, strings.Join([]string{
- fmt.Sprintf(``,
- labelMaskID, w, h,
+ fmt.Sprintf(``,
+ labelMaskID, -pad, -pad, w, h,
),
- fmt.Sprintf(``,
- w,
- h,
+ fmt.Sprintf(``,
+ -pad, -pad, w, h,
),
strings.Join(labelMasks, "\n"),
``,
diff --git a/e2etests/testdata/regression/dagre_edge_label_spacing/dagre/sketch.exp.svg b/e2etests/testdata/regression/dagre_edge_label_spacing/dagre/sketch.exp.svg
index fe87ffcc1..6da3ce848 100644
--- a/e2etests/testdata/regression/dagre_edge_label_spacing/dagre/sketch.exp.svg
+++ b/e2etests/testdata/regression/dagre_edge_label_spacing/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="2348" height="437" viewBox="-100 -100 2348 437">lambda-build.yamlPush to main branchGitHub ActionsS3TerraformAWSTriggersBuilds zip & pushes itPulls zip to deployChanges the live lambdas
-
+lambda-build.yamlPush to main branchGitHub ActionsS3TerraformAWSTriggersBuilds zip & pushes itPulls zip to deployChanges the live lambdas
+
diff --git a/e2etests/testdata/regression/dagre_edge_label_spacing/elk/sketch.exp.svg b/e2etests/testdata/regression/dagre_edge_label_spacing/elk/sketch.exp.svg
index 33be96f29..814c60100 100644
--- a/e2etests/testdata/regression/dagre_edge_label_spacing/elk/sketch.exp.svg
+++ b/e2etests/testdata/regression/dagre_edge_label_spacing/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="2093" height="487" viewBox="-88 -88 2093 487">lambda-build.yamlPush to main branchGitHub ActionsS3TerraformAWSTriggersBuilds zip & pushes itPulls zip to deployChanges the live lambdas
-
+lambda-build.yamlPush to main branchGitHub ActionsS3TerraformAWSTriggersBuilds zip & pushes itPulls zip to deployChanges the live lambdas
+
diff --git a/e2etests/testdata/regression/dagre_special_ids/dagre/sketch.exp.svg b/e2etests/testdata/regression/dagre_special_ids/dagre/sketch.exp.svg
index f7a7922d5..d5d44ead7 100644
--- a/e2etests/testdata/regression/dagre_special_ids/dagre/sketch.exp.svg
+++ b/e2etests/testdata/regression/dagre_special_ids/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1427" height="568" viewBox="-100 -100 1427 568">ninetynineeighty
eightseventy
sevena\yodetherea\"odea\node
-
+ninetynineeighty
eightseventy
sevena\yodetherea\"odea\node
+ninetynineeighty
eightseventy
sevena\yodetherea\"odea\node
-
+ninetynineeighty
eightseventy
sevena\yodetherea\"odea\node
+lambda-build.yamllambda-deploy.yamlapollo-deploy.yamlPush to main branchGitHub ActionsS3TerraformAWSManual TriggerGitHub ActionsAWSApollo RepoGitHub ActionsAWSTriggersBuilds zip and pushes itPulls zip to deployChanges live lambdasLaunchesBuilds zippushes them to S3.Deploys lambdasusing TerraformTriggered manually/push to master test test test test test test testtest
-
+lambda-build.yamllambda-deploy.yamlapollo-deploy.yamlPush to main branchGitHub ActionsS3TerraformAWSManual TriggerGitHub ActionsAWSApollo RepoGitHub ActionsAWSTriggersBuilds zip and pushes itPulls zip to deployChanges live lambdasLaunchesBuilds zippushes them to S3.Deploys lambdasusing TerraformTriggered manually/push to master test test test test test test testtest
+
diff --git a/e2etests/testdata/regression/elk_alignment/elk/sketch.exp.svg b/e2etests/testdata/regression/elk_alignment/elk/sketch.exp.svg
index 3d9ef5c63..487f8dc2a 100644
--- a/e2etests/testdata/regression/elk_alignment/elk/sketch.exp.svg
+++ b/e2etests/testdata/regression/elk_alignment/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1825" height="1299" viewBox="-88 -88 1825 1299">lambda-build.yamllambda-deploy.yamlapollo-deploy.yamlPush to main branchGitHub ActionsS3TerraformAWSManual TriggerGitHub ActionsAWSApollo RepoGitHub ActionsAWSTriggersBuilds zip and pushes itPulls zip to deployChanges live lambdasLaunchesBuilds zippushes them to S3.Deploys lambdasusing TerraformTriggered manually/push to master test test test test test test testtest
-
+lambda-build.yamllambda-deploy.yamlapollo-deploy.yamlPush to main branchGitHub ActionsS3TerraformAWSManual TriggerGitHub ActionsAWSApollo RepoGitHub ActionsAWSTriggersBuilds zip and pushes itPulls zip to deployChanges live lambdasLaunchesBuilds zippushes them to S3.Deploys lambdasusing TerraformTriggered manually/push to master test test test test test test testtest
+
diff --git a/e2etests/testdata/regression/empty_sequence/dagre/sketch.exp.svg b/e2etests/testdata/regression/empty_sequence/dagre/sketch.exp.svg
index 47c42c577..192e116cb 100644
--- a/e2etests/testdata/regression/empty_sequence/dagre/sketch.exp.svg
+++ b/e2etests/testdata/regression/empty_sequence/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="366" height="552" viewBox="-100 -100 366 552">hellogoodbye
-
+hellogoodbye
+hellogoodbye
-
+hellogoodbye
+foofoobarabcd
-
+foofoobarabcd
+foofoobarabcd
-
+foofoobarabcd
+AB
-
+AB
+AB
-
+AB
+b
-
+b
+b
-
+b
+abc
-
+abc
+abc
-
+abc
+ab
-
+ab
+ab
-
+ab
+acbd
-
+acbd
+acbd
-
+acbd
+abhello
-
+abhello
+abhello
-
+abhello
+
-
+
+
\ No newline at end of file
diff --git a/e2etests/testdata/sanity/empty/elk/sketch.exp.svg b/e2etests/testdata/sanity/empty/elk/sketch.exp.svg
index 20d55bdc1..243722dc6 100644
--- a/e2etests/testdata/sanity/empty/elk/sketch.exp.svg
+++ b/e2etests/testdata/sanity/empty/elk/sketch.exp.svg
@@ -18,7 +18,7 @@ width="200" height="200" viewBox="-100 -100 200 200">
-
+
+
\ No newline at end of file
diff --git a/e2etests/testdata/stable/all_shapes/dagre/sketch.exp.svg b/e2etests/testdata/stable/all_shapes/dagre/sketch.exp.svg
index 095790f60..0ff95d243 100644
--- a/e2etests/testdata/stable/all_shapes/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/all_shapes/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1539" height="824" viewBox="-100 -100 1539 824">rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
-
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
-
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
-
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
-
+rectanglesquarepageparallelogramdocumentcylinderqueuepackagestepcalloutstored_datapersondiamondovalcirclehexagoncloud
+cba*
-
+cba*
+cba*
-
+cba*
+abTo err is human, to moo bovine1*
-
+abTo err is human, to moo bovine1*
+abTo err is human, to moo bovine1*
-
+abTo err is human, to moo bovine1*
+abcdefghijklmno
-
+abcdefghijklmno
+abcdefghijklmno
-
+abcdefghijklmno
+aaadddeeebbbccc111222
-
+aaadddeeebbbccc111222
+aaadddeeebbbccc111222
-
+aaadddeeebbbccc111222
+aabbllmm
Lorem ipsum dolor sit amet, consectetur adipiscing elit,
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
-
-
+
+markdown
Lorem ipsum dolor sit amet, consectetur adipiscing elit,
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
-
-
+
+markdown
Lorem ipsum dolor sit amet, consectetur adipiscing elit,
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
-
-
+
+markdown
Lorem ipsum dolor sit amet, consectetur adipiscing elit,
sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
-
-
+
+
code
-
ab
-
+ab
+
code
-
ab
-
+ab
+thisgoesmultiple lines
-
+thisgoesmultiple lines
+thisgoesmultiple lines
-
+thisgoesmultiple lines
+abcdefghijklmnopqrstuvw
-
+abcdefghijklmnopqrstuvw
+abcdefghijklmnopqrstuvw
-
+abcdefghijklmnopqrstuvw
+abcdefghijklmnopqrstu
-
+abcdefghijklmnopqrstu
+abcdefghijklmnopqrstu
-
+abcdefghijklmnopqrstu
+Foo Baz12hello
-
+Foo Baz12hello
+Foo Baz12hello
-
+Foo Baz12hello
+acdefgbh
-
+acdefgbh
+acdefgbh
-
+acdefgbh
+topabcbottomstartend
-
+topabcbottomstartend
+topabcbottomstartend
-
+topabcbottomstartend
+rootcontainerrootleftrightrootinnerrootinnerleftrightleftrightto inner leftto inner rightto inner leftto inner rightto left container rootto right container root
-
+rootcontainerrootleftrightrootinnerrootinnerleftrightleftrightto inner leftto inner rightto inner leftto inner rightto left container rootto right container root
+
diff --git a/e2etests/testdata/stable/overlapping_image_container_labels/elk/sketch.exp.svg b/e2etests/testdata/stable/overlapping_image_container_labels/elk/sketch.exp.svg
index 38f4d6c73..d4f292cdf 100644
--- a/e2etests/testdata/stable/overlapping_image_container_labels/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/overlapping_image_container_labels/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1522" height="1503" viewBox="-88 -88 1522 1503">rootcontainerrootleftrightrootinnerrootinnerleftrightleftrightto inner leftto inner rightto inner leftto inner rightto left container rootto right container root
-
+rootcontainerrootleftrightrootinnerrootinnerleftrightleftrightto inner leftto inner rightto inner leftto inner rightto left container rootto right container root
+
diff --git a/e2etests/testdata/stable/p/dagre/sketch.exp.svg b/e2etests/testdata/stable/p/dagre/sketch.exp.svg
index 7fb9d6e30..840c8a89b 100644
--- a/e2etests/testdata/stable/p/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/p/dagre/sketch.exp.svg
@@ -778,8 +778,8 @@ width="2057" height="676" viewBox="-100 -100 2057 676">xyzhello
-
+xyzhello
+xyzhello
-
+xyzhello
+an actor with a really long label that will break everythinganactorwithareallylonglabelthatwillbreakeverythingsimplea short onefar awaywhat if there were no labels between this actor and the previous oneshortlong label for testing purposes and it must be really, really longshortthis should span many actors lifelines so we know how it will look like when redering a long label over many actorslong label for testing purposes and it must be really, really long
-
+an actor with a really long label that will break everythinganactorwithareallylonglabelthatwillbreakeverythingsimplea short onefar awaywhat if there were no labels between this actor and the previous oneshortlong label for testing purposes and it must be really, really longshortthis should span many actors lifelines so we know how it will look like when redering a long label over many actorslong label for testing purposes and it must be really, really long
+
diff --git a/e2etests/testdata/stable/sequence_diagram_actor_distance/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_actor_distance/elk/sketch.exp.svg
index b0be8b3b5..f0302fd8e 100644
--- a/e2etests/testdata/stable/sequence_diagram_actor_distance/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_actor_distance/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="2692" height="1396" viewBox="-76 -26 2692 1396">an actor with a really long label that will break everythinganactorwithareallylonglabelthatwillbreakeverythingsimplea short onefar awaywhat if there were no labels between this actor and the previous oneshortlong label for testing purposes and it must be really, really longshortthis should span many actors lifelines so we know how it will look like when redering a long label over many actorslong label for testing purposes and it must be really, really long
-
+an actor with a really long label that will break everythinganactorwithareallylonglabelthatwillbreakeverythingsimplea short onefar awaywhat if there were no labels between this actor and the previous oneshortlong label for testing purposes and it must be really, really longshortthis should span many actors lifelines so we know how it will look like when redering a long label over many actorslong label for testing purposes and it must be really, really long
+
diff --git a/e2etests/testdata/stable/sequence_diagram_all_shapes/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_all_shapes/dagre/sketch.exp.svg
index d5ef75817..c23490a3e 100644
--- a/e2etests/testdata/stable/sequence_diagram_all_shapes/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_all_shapes/dagre/sketch.exp.svg
@@ -28,8 +28,8 @@ width="5120" height="2984" viewBox="-76 -26 5120 2984">alicebobwhat does it mean to be well-adjustedThe ability to play bridge or golf as if they were games
-
+alicebobwhat does it mean to be well-adjustedThe ability to play bridge or golf as if they were games
+alicebobwhat does it mean to be well-adjustedThe ability to play bridge or golf as if they were games
-
+alicebobwhat does it mean to be well-adjustedThe ability to play bridge or golf as if they were games
+abcdggggroup 1group bchoonested guylalaeyokayokaywhat would arnold saythis note
-
+abcdggggroup 1group bchoonested guylalaeyokayokaywhat would arnold saythis note
+
diff --git a/e2etests/testdata/stable/sequence_diagram_groups/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_groups/elk/sketch.exp.svg
index cac917156..0afcfd18a 100644
--- a/e2etests/testdata/stable/sequence_diagram_groups/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_groups/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1147" height="2268" viewBox="-76 -26 1147 2268">abcdggggroup 1group bchoonested guylalaeyokayokaywhat would arnold saythis note
-
+abcdggggroup 1group bchoonested guylalaeyokayokaywhat would arnold saythis note
+
diff --git a/e2etests/testdata/stable/sequence_diagram_long_note/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_long_note/dagre/sketch.exp.svg
index 97b4c4e3f..8cc670b3d 100644
--- a/e2etests/testdata/stable/sequence_diagram_long_note/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_long_note/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="850" height="1162" viewBox="-263 -26 850 1162">baa note here to remember that padding must consider notes toojustalongnotehere
-
+baa note here to remember that padding must consider notes toojustalongnotehere
+baa note here to remember that padding must consider notes toojustalongnotehere
-
+baa note here to remember that padding must consider notes toojustalongnotehere
+abjust an actorthis is a message groupaltand this is a nested message groupcase 1case 2case 3case 4what about more nestingcrazy townwhoaa notea note here to remember that padding must consider notes toojustalongnotehere
-
+abjust an actorthis is a message groupaltand this is a nested message groupcase 1case 2case 3case 4what about more nestingcrazy townwhoaa notea note here to remember that padding must consider notes toojustalongnotehere
+
diff --git a/e2etests/testdata/stable/sequence_diagram_nested_groups/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_nested_groups/elk/sketch.exp.svg
index 7ca2f5d0f..0dbb0afaa 100644
--- a/e2etests/testdata/stable/sequence_diagram_nested_groups/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_nested_groups/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1116" height="2458" viewBox="-197 -26 1116 2458">abjust an actorthis is a message groupaltand this is a nested message groupcase 1case 2case 3case 4what about more nestingcrazy townwhoaa notea note here to remember that padding must consider notes toojustalongnotehere
-
+abjust an actorthis is a message groupaltand this is a nested message groupcase 1case 2case 3case 4what about more nestingcrazy townwhoaa notea note here to remember that padding must consider notes toojustalongnotehere
+
diff --git a/e2etests/testdata/stable/sequence_diagram_nested_span/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_nested_span/dagre/sketch.exp.svg
index 8db0ad5d1..9fb361e64 100644
--- a/e2etests/testdata/stable/sequence_diagram_nested_span/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_nested_span/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1624" height="1626" viewBox="-76 -26 1624 1626">scoreritemResponseitemessayRubricconceptitemOutcome
-
+scoreritemResponseitemessayRubricconceptitemOutcome
+scoreritemResponseitemessayRubricconceptitemOutcome
-
+scoreritemResponseitemessayRubricconceptitemOutcome
+abcdokayexplanationanother explanationSome one who believes imaginary things appear right before your i's.The earth is like a tiny grain of sand, only much, much heavier
-
+abcdokayexplanationanother explanationSome one who believes imaginary things appear right before your i's.The earth is like a tiny grain of sand, only much, much heavier
+abcdokayexplanationanother explanationSome one who believes imaginary things appear right before your i's.The earth is like a tiny grain of sand, only much, much heavier
-
+abcdokayexplanationanother explanationSome one who believes imaginary things appear right before your i's.The earth is like a tiny grain of sand, only much, much heavier
+How this is renderedCLId2astd2compilerd2layoutd2exporterd2themesd2rendererd2sequencelayoutd2dagrelayoutonly if root is not sequence'How this is rendered: {...}'tokenized ASTcompile ASTobjects and edgesrun layout enginesrun engine on shape: sequence_diagram, temporarily removerun core engine on restadd back in sequence diagramsdiagram with correct positions and dimensionsexport diagram with chosen theme and rendererget theme stylesrender to SVGresulting SVGmeasurements also take place
-
+How this is renderedCLId2astd2compilerd2layoutd2exporterd2themesd2rendererd2sequencelayoutd2dagrelayoutonly if root is not sequence'How this is rendered: {...}'tokenized ASTcompile ASTobjects and edgesrun layout enginesrun engine on shape: sequence_diagram, temporarily removerun core engine on restadd back in sequence diagramsdiagram with correct positions and dimensionsexport diagram with chosen theme and rendererget theme stylesrender to SVGresulting SVGmeasurements also take place
+
diff --git a/e2etests/testdata/stable/sequence_diagram_real/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_real/elk/sketch.exp.svg
index 0d904f1d9..364fb5549 100644
--- a/e2etests/testdata/stable/sequence_diagram_real/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_real/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="2447" height="2536" viewBox="-88 -88 2447 2536">How this is renderedCLId2astd2compilerd2layoutd2exporterd2themesd2rendererd2sequencelayoutd2dagrelayoutonly if root is not sequence'How this is rendered: {...}'tokenized ASTcompile ASTobjects and edgesrun layout enginesrun engine on shape: sequence_diagram, temporarily removerun core engine on restadd back in sequence diagramsdiagram with correct positions and dimensionsexport diagram with chosen theme and rendererget theme stylesrender to SVGresulting SVGmeasurements also take place
-
+How this is renderedCLId2astd2compilerd2layoutd2exporterd2themesd2rendererd2sequencelayoutd2dagrelayoutonly if root is not sequence'How this is rendered: {...}'tokenized ASTcompile ASTobjects and edgesrun layout enginesrun engine on shape: sequence_diagram, temporarily removerun core engine on restadd back in sequence diagramsdiagram with correct positions and dimensionsexport diagram with chosen theme and rendererget theme stylesrender to SVGresulting SVGmeasurements also take place
+
diff --git a/e2etests/testdata/stable/sequence_diagram_self_edges/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_self_edges/dagre/sketch.exp.svg
index b0d237070..f947663cd 100644
--- a/e2etests/testdata/stable/sequence_diagram_self_edges/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_self_edges/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="696" height="1366" viewBox="-76 -26 696 1366">aba self edge herebetween actorsto descendantto deeper descendantto parentactor
-
+aba self edge herebetween actorsto descendantto deeper descendantto parentactor
+
diff --git a/e2etests/testdata/stable/sequence_diagram_self_edges/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_self_edges/elk/sketch.exp.svg
index b0d237070..f947663cd 100644
--- a/e2etests/testdata/stable/sequence_diagram_self_edges/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_self_edges/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="696" height="1366" viewBox="-76 -26 696 1366">aba self edge herebetween actorsto descendantto deeper descendantto parentactor
-
+aba self edge herebetween actorsto descendantto deeper descendantto parentactor
+
diff --git a/e2etests/testdata/stable/sequence_diagram_simple/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_simple/dagre/sketch.exp.svg
index 608019d3a..d0e6006a2 100644
--- a/e2etests/testdata/stable/sequence_diagram_simple/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_simple/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1598" height="1868" viewBox="-76 -26 1598 1868">AlicelinebreakerBobdbqueueanoddservicewithanameinmultiple linesAuthentication Requestmake request for something that is quite far away and requires a really long label to take all the space between the objectsvalidate credentialsAuthentication ResponseAnother authentication Requestdo it laterstoredAnother authentication Response
-
+AlicelinebreakerBobdbqueueanoddservicewithanameinmultiple linesAuthentication Requestmake request for something that is quite far away and requires a really long label to take all the space between the objectsvalidate credentialsAuthentication ResponseAnother authentication Requestdo it laterstoredAnother authentication Response
+
diff --git a/e2etests/testdata/stable/sequence_diagram_simple/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_simple/elk/sketch.exp.svg
index 608019d3a..d0e6006a2 100644
--- a/e2etests/testdata/stable/sequence_diagram_simple/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_simple/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1598" height="1868" viewBox="-76 -26 1598 1868">AlicelinebreakerBobdbqueueanoddservicewithanameinmultiple linesAuthentication Requestmake request for something that is quite far away and requires a really long label to take all the space between the objectsvalidate credentialsAuthentication ResponseAnother authentication Requestdo it laterstoredAnother authentication Response
-
+AlicelinebreakerBobdbqueueanoddservicewithanameinmultiple linesAuthentication Requestmake request for something that is quite far away and requires a really long label to take all the space between the objectsvalidate credentialsAuthentication ResponseAnother authentication Requestdo it laterstoredAnother authentication Response
+
diff --git a/e2etests/testdata/stable/sequence_diagram_span/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_span/dagre/sketch.exp.svg
index 470d35fc6..aa3321ec2 100644
--- a/e2etests/testdata/stable/sequence_diagram_span/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_span/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1624" height="2146" viewBox="-76 -26 1624 2146">scoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
-
+scoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
+
diff --git a/e2etests/testdata/stable/sequence_diagram_span/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagram_span/elk/sketch.exp.svg
index 470d35fc6..aa3321ec2 100644
--- a/e2etests/testdata/stable/sequence_diagram_span/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagram_span/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="1624" height="2146" viewBox="-76 -26 1624 2146">scoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
-
+scoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
+
diff --git a/e2etests/testdata/stable/sequence_diagrams/dagre/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagrams/dagre/sketch.exp.svg
index 1a8465908..db69a01ce 100644
--- a/e2etests/testdata/stable/sequence_diagrams/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagrams/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="3402" height="4269" viewBox="-100 -100 3402 4269">a_shapea_sequenceanotherfinallysequencesequencesequencescoreritemResponseitemessayRubricconceptitemOutcomescorerconceptessayRubricitemitemOutcomeitemResponsescoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)getItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
-
+a_shapea_sequenceanotherfinallysequencesequencesequencescoreritemResponseitemessayRubricconceptitemOutcomescorerconceptessayRubricitemitemOutcomeitemResponsescoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)getItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
+
diff --git a/e2etests/testdata/stable/sequence_diagrams/elk/sketch.exp.svg b/e2etests/testdata/stable/sequence_diagrams/elk/sketch.exp.svg
index 938982dd1..8aaa9c058 100644
--- a/e2etests/testdata/stable/sequence_diagrams/elk/sketch.exp.svg
+++ b/e2etests/testdata/stable/sequence_diagrams/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="3324" height="4389" viewBox="-88 -88 3324 4389">a_shapea_sequenceanotherfinallysequencesequencesequencescoreritemResponseitemessayRubricconceptitemOutcomescorerconceptessayRubricitemitemOutcomeitemResponsescoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)getItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
-
+a_shapea_sequenceanotherfinallysequencesequencesequencescoreritemResponseitemessayRubricconceptitemOutcomescorerconceptessayRubricitemitemOutcomeitemResponsescoreritemResponseitemessayRubricconceptitemOutcomegetItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)getItem()itemgetRubric()rubricapplyTo(essayResp)match(essayResponse)scorenewgetNormalMinimum()getNormalMaximum()setScore(score)setFeedback(missingConcepts)
+
diff --git a/e2etests/testdata/stable/sql_tables/dagre/sketch.exp.svg b/e2etests/testdata/stable/sql_tables/dagre/sketch.exp.svg
index da45fa870..d6087ea8a 100644
--- a/e2etests/testdata/stable/sql_tables/dagre/sketch.exp.svg
+++ b/e2etests/testdata/stable/sql_tables/dagre/sketch.exp.svg
@@ -50,8 +50,8 @@ width="936" height="660" viewBox="-100 -100 936 660">acbl1l2c1l2c3l2c2l3c1l3c2l4bacacbabcc1c2c3abc
-
+acbl1l2c1l2c3l2c2l3c1l3c2l4bacacbabcc1c2c3abc
+acbl1l2c1l2c3l2c2l3c1l3c2l4bacacbabcc1c2c3abc
-
+acbl1l2c1l2c3l2c2l3c1l3c2l4bacacbabcc1c2c3abc
+
-cube
-
+cube
+
-cube
-
+cube
+AKHIALFLGAMSTNAZCANVNMUTARLAMOOKTXORCOKSNEWYCTMANYRIDEMDNJPANCSCIDMTWAILINIAMIKYWIOHMNSDVAWVMENHVTND
-
+AKHIALFLGAMSTNAZCANVNMUTARLAMOOKTXORCOKSNEWYCTMANYRIDEMDNJPANCSCIDMTWAILINIAMIKYWIOHMNSDVAWVMENHVTND
+AKHIALFLGAMSTNAZCANVNMUTARLAMOOKTXORCOKSNEWYCTMANYRIDEMDNJPANCSCIDMTWAILINIAMIKYWIOHMNSDVAWVMENHVTND
-
+AKHIALFLGAMSTNAZCANVNMUTARLAMOOKTXORCOKSNEWYCTMANYRIDEMDNJPANCSCIDMTWAILINIAMIKYWIOHMNSDVAWVMENHVTND
+containerfirstsecond1->2c->2
-
+containerfirstsecond1->2c->2
+containerfirstsecond1->2c->2
-
+containerfirstsecond1->2c->2
+ninety ninesixty fourthirty twosixteeneight
-
+ninety ninesixty fourthirty twosixteeneight
+ninety ninesixty fourthirty twosixteeneight
-
+ninety ninesixty fourthirty twosixteeneight
+eightsixteenthirty twosixty fourninety ninetwelvetwenty fourforty eighteighty one
-
+eightsixteenthirty twosixty fourninety ninetwelvetwenty fourforty eighteighty one
+
diff --git a/e2etests/testdata/todo/font_sizes_large/elk/sketch.exp.svg b/e2etests/testdata/todo/font_sizes_large/elk/sketch.exp.svg
index 0b46e8a15..2e9ecf429 100644
--- a/e2etests/testdata/todo/font_sizes_large/elk/sketch.exp.svg
+++ b/e2etests/testdata/todo/font_sizes_large/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="789" height="2014" viewBox="-88 -88 789 2014">eightsixteenthirty twosixty fourninety ninetwelvetwenty fourforty eighteighty one
-
+eightsixteenthirty twosixty fourninety ninetwelvetwenty fourforty eighteighty one
+
diff --git a/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/dagre/sketch.exp.svg b/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/dagre/sketch.exp.svg
index a2ac750ea..288cab1f2 100644
--- a/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/dagre/sketch.exp.svg
+++ b/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="921" height="1242" viewBox="-147 -26 921 1242">bacthis is a message groupand this is a nested message groupwhat about more nestingyoyo
-
+bacthis is a message groupand this is a nested message groupwhat about more nestingyoyo
+
diff --git a/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/elk/sketch.exp.svg b/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/elk/sketch.exp.svg
index a2ac750ea..288cab1f2 100644
--- a/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/elk/sketch.exp.svg
+++ b/e2etests/testdata/todo/sequence_diagram_actor_padding_nested_groups/elk/sketch.exp.svg
@@ -18,8 +18,8 @@ width="921" height="1242" viewBox="-147 -26 921 1242">bacthis is a message groupand this is a nested message groupwhat about more nestingyoyo
-
+bacthis is a message groupand this is a nested message groupwhat about more nestingyoyo
+
diff --git a/e2etests/testdata/todo/tall_edge_label/dagre/sketch.exp.svg b/e2etests/testdata/todo/tall_edge_label/dagre/sketch.exp.svg
index 619acbb99..e61e1a050 100644
--- a/e2etests/testdata/todo/tall_edge_label/dagre/sketch.exp.svg
+++ b/e2etests/testdata/todo/tall_edge_label/dagre/sketch.exp.svg
@@ -18,8 +18,8 @@ width="313" height="625" viewBox="-100 -100 313 625">abThereoncewasaverytalledgelabel
-
+abThereoncewasaverytalledgelabel
+abThereoncewasaverytalledgelabel
-
+abThereoncewasaverytalledgelabel
+