From 5abda40ca651f3625f8a01ffc23614fa470dabe1 Mon Sep 17 00:00:00 2001 From: Alexander Wang Date: Wed, 10 Apr 2024 08:50:51 -0700 Subject: [PATCH] allow minimum dimensions to be less than label dimensions --- ci/release/changelogs/next.md | 1 + d2graph/d2graph.go | 33 ++- d2layouts/d2dagrelayout/layout.go | 8 + d2layouts/d2elklayout/layout.go | 8 + .../glob_dimensions/dagre/board.exp.json | 150 ++++++------- .../glob_dimensions/dagre/sketch.exp.svg | 198 +++++++++--------- .../glob_dimensions/elk/board.exp.json | 106 +++++----- .../glob_dimensions/elk/sketch.exp.svg | 198 +++++++++--------- .../just-width/dagre/board.exp.json | 4 +- .../just-width/dagre/sketch.exp.svg | 156 +++++++------- .../regression/just-width/elk/board.exp.json | 4 +- .../regression/just-width/elk/sketch.exp.svg | 156 +++++++------- .../simple_grid_edges/dagre/board.exp.json | 18 +- .../simple_grid_edges/dagre/sketch.exp.svg | 176 ++++++++-------- .../simple_grid_edges/elk/board.exp.json | 18 +- .../simple_grid_edges/elk/sketch.exp.svg | 176 ++++++++-------- e2etests/testdata/txtar.txt | 7 + .../dagre/board.exp.json | 89 ++++++++ .../dagre/sketch.exp.svg | 95 +++++++++ .../elk/board.exp.json | 89 ++++++++ .../elk/sketch.exp.svg | 95 +++++++++ 21 files changed, 1094 insertions(+), 691 deletions(-) create mode 100644 e2etests/testdata/txtar/width-smaller-than-label/dagre/board.exp.json create mode 100644 e2etests/testdata/txtar/width-smaller-than-label/dagre/sketch.exp.svg create mode 100644 e2etests/testdata/txtar/width-smaller-than-label/elk/board.exp.json create mode 100644 e2etests/testdata/txtar/width-smaller-than-label/elk/sketch.exp.svg diff --git a/ci/release/changelogs/next.md b/ci/release/changelogs/next.md index 3ce0badec..69ef0268b 100644 --- a/ci/release/changelogs/next.md +++ b/ci/release/changelogs/next.md @@ -5,6 +5,7 @@ #### Improvements 🧹 +- Dimensions can be set less than label dimensions [#1901](https://github.com/terrastruct/d2/pull/1901) - Boards no longer inherit `label` fields from parents [#1838](https://github.com/terrastruct/d2/pull/1838) - Prevents `near` targeting a child of a special object like grid cells, which wasn't doing anything [#1851](https://github.com/terrastruct/d2/pull/1851) diff --git a/d2graph/d2graph.go b/d2graph/d2graph.go index 39394035a..da808ecfd 100644 --- a/d2graph/d2graph.go +++ b/d2graph/d2graph.go @@ -1048,15 +1048,6 @@ func (obj *Object) GetDefaultSize(mtexts []*d2target.MText, ruler *textmeasure.R // resizes the object to fit content of the given width and height in its inner box with the given padding. // this accounts for the shape of the object, and if there is a desired width or height set for the object func (obj *Object) SizeToContent(contentWidth, contentHeight, paddingX, paddingY float64) { - var desiredWidth int - var desiredHeight int - if obj.WidthAttr != nil { - desiredWidth, _ = strconv.Atoi(obj.WidthAttr.Value) - } - if obj.HeightAttr != nil { - desiredHeight, _ = strconv.Atoi(obj.HeightAttr.Value) - } - dslShape := strings.ToLower(obj.Shape.Value) shapeType := d2target.DSL_SHAPE_TO_SHAPE_TYPE[dslShape] s := shape.NewShape(shapeType, geo.NewBox(geo.NewPoint(0, 0), contentWidth, contentHeight)) @@ -1068,8 +1059,28 @@ func (obj *Object) SizeToContent(contentWidth, contentHeight, paddingX, paddingY } else { fitWidth, fitHeight = s.GetDimensionsToFit(contentWidth, contentHeight, paddingX, paddingY) } - obj.Width = math.Max(float64(desiredWidth), fitWidth) - obj.Height = math.Max(float64(desiredHeight), fitHeight) + + var desiredWidth int + if obj.WidthAttr != nil { + desiredWidth, _ = strconv.Atoi(obj.WidthAttr.Value) + obj.Width = float64(desiredWidth) + } else { + obj.Width = fitWidth + } + + var desiredHeight int + if obj.HeightAttr != nil { + desiredHeight, _ = strconv.Atoi(obj.HeightAttr.Value) + obj.Height = float64(desiredHeight) + } else { + obj.Height = fitHeight + } + + if obj.SQLTable != nil || obj.Class != nil || obj.Language != "" { + obj.Width = math.Max(float64(desiredWidth), fitWidth) + obj.Height = math.Max(float64(desiredHeight), fitHeight) + } + if s.AspectRatio1() { sideLength := math.Max(obj.Width, obj.Height) obj.Width = sideLength diff --git a/d2layouts/d2dagrelayout/layout.go b/d2layouts/d2dagrelayout/layout.go index b367e404c..29653c9a1 100644 --- a/d2layouts/d2dagrelayout/layout.go +++ b/d2layouts/d2dagrelayout/layout.go @@ -571,6 +571,14 @@ func positionLabelsIcons(obj *d2graph.Object) { obj.LabelPosition = go2.Pointer(label.InsideMiddleCenter.String()) } } + + if float64(obj.LabelDimensions.Width) > obj.Width || float64(obj.LabelDimensions.Height) > obj.Height { + if len(obj.ChildrenArray) > 0 { + obj.LabelPosition = go2.Pointer(label.OutsideTopCenter.String()) + } else { + obj.LabelPosition = go2.Pointer(label.OutsideBottomCenter.String()) + } + } } func getRanks(g *d2graph.Graph, isHorizontal bool) (ranks [][]*d2graph.Object, objectRanks, startingParentRanks, endingParentRanks map[*d2graph.Object]int) { diff --git a/d2layouts/d2elklayout/layout.go b/d2layouts/d2elklayout/layout.go index 2c0b45a9f..5dfe0c607 100644 --- a/d2layouts/d2elklayout/layout.go +++ b/d2layouts/d2elklayout/layout.go @@ -1149,4 +1149,12 @@ func positionLabelsIcons(obj *d2graph.Object) { obj.LabelPosition = go2.Pointer(label.InsideMiddleCenter.String()) } } + + if float64(obj.LabelDimensions.Width) > obj.Width || float64(obj.LabelDimensions.Height) > obj.Height { + if len(obj.ChildrenArray) > 0 { + obj.LabelPosition = go2.Pointer(label.OutsideTopCenter.String()) + } else { + obj.LabelPosition = go2.Pointer(label.OutsideBottomCenter.String()) + } + } } diff --git a/e2etests/testdata/regression/glob_dimensions/dagre/board.exp.json b/e2etests/testdata/regression/glob_dimensions/dagre/board.exp.json index fb2291435..bb38e0c9f 100644 --- a/e2etests/testdata/regression/glob_dimensions/dagre/board.exp.json +++ b/e2etests/testdata/regression/glob_dimensions/dagre/board.exp.json @@ -7,11 +7,11 @@ "id": "start", "type": "oval", "pos": { - "x": 138, + "x": 148, "y": 0 }, - "width": 30, - "height": 30, + "width": 10, + "height": 10, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -40,7 +40,7 @@ "underline": false, "labelWidth": 9, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 1 }, @@ -49,10 +49,10 @@ "type": "rectangle", "pos": { "x": 18, - "y": 150 + "y": 130 }, "width": 259, - "height": 548, + "height": 509, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -89,11 +89,11 @@ "id": "Check PIN.start", "type": "oval", "pos": { - "x": 138, - "y": 180 + "x": 148, + "y": 160 }, - "width": 30, - "height": 30, + "width": 10, + "height": 10, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -122,7 +122,7 @@ "underline": false, "labelWidth": 9, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 2 }, @@ -131,7 +131,7 @@ "type": "rectangle", "pos": { "x": 98, - "y": 310 + "y": 270 }, "width": 111, "height": 66, @@ -172,7 +172,7 @@ "type": "diamond", "pos": { "x": 143, - "y": 497 + "y": 457 }, "width": 20, "height": 20, @@ -211,11 +211,11 @@ "id": "Check PIN.end", "type": "oval", "pos": { - "x": 138, - "y": 638 + "x": 148, + "y": 598 }, - "width": 30, - "height": 30, + "width": 10, + "height": 10, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -244,7 +244,7 @@ "underline": false, "labelWidth": 9, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 2 }, @@ -253,7 +253,7 @@ "type": "rectangle", "pos": { "x": 133, - "y": 839 + "y": 779 }, "width": 159, "height": 66, @@ -294,7 +294,7 @@ "type": "rectangle", "pos": { "x": 227, - "y": 1026 + "y": 966 }, "width": 89, "height": 66, @@ -335,7 +335,7 @@ "type": "rectangle", "pos": { "x": 119, - "y": 1213 + "y": 1153 }, "width": 68, "height": 66, @@ -399,19 +399,19 @@ "route": [ { "x": 153, - "y": 30 + "y": 36 }, { "x": 153, - "y": 70 + "y": 55.20000076293945 }, { "x": 153, - "y": 85.80000305175781 + "y": 65.80000305175781 }, { "x": 153, - "y": 109 + "y": 89 } ], "isCurve": true, @@ -446,19 +446,19 @@ "route": [ { "x": 153, - "y": 210 + "y": 196 }, { "x": 153, - "y": 250 + "y": 215.1999969482422 + }, + { + "x": 153, + "y": 230 }, { "x": 153, "y": 270 - }, - { - "x": 153, - "y": 310 } ], "isCurve": true, @@ -493,19 +493,19 @@ "route": [ { "x": 127.75, - "y": 375.5 + "y": 335.5 }, { "x": 90.1500015258789, - "y": 424.29998779296875 + "y": 384.29998779296875 }, { "x": 94.19999694824219, - "y": 449.6000061035156 + "y": 409.6000061035156 }, { "x": 148, - "y": 502 + "y": 462 } ], "isCurve": true, @@ -540,19 +540,19 @@ "route": [ { "x": 158, - "y": 502 + "y": 462 }, { "x": 200, - "y": 449.6000061035156 + "y": 409.6000061035156 }, { "x": 203.10000610351562, - "y": 424.29998779296875 + "y": 384.29998779296875 }, { "x": 173.5, - "y": 375.5 + "y": 335.5 } ], "isCurve": true, @@ -587,19 +587,19 @@ "route": [ { "x": 153, - "y": 517 + "y": 477 }, { "x": 153, - "y": 565.4000244140625 + "y": 525.4000244140625 }, { "x": 153, - "y": 589.5999755859375 + "y": 549.5999755859375 }, { "x": 153, - "y": 638 + "y": 598 } ], "isCurve": true, @@ -634,19 +634,19 @@ "route": [ { "x": 212.75, - "y": 697.5 + "y": 638.5 }, { "x": 212.75, - "y": 762.2999877929688 + "y": 702.5 }, { "x": 212.75, - "y": 790.7000122070312 + "y": 730.7000122070312 }, { "x": 212.75, - "y": 839.5 + "y": 779.5 } ], "isCurve": true, @@ -681,19 +681,19 @@ "route": [ { "x": 233.5, - "y": 904.5 + "y": 844.5 }, { "x": 263.8999938964844, - "y": 953.2999877929688 + "y": 893.2999877929688 }, { "x": 271.5, - "y": 977.7000122070312 + "y": 917.7000122070312 }, { "x": 271.5, - "y": 1026.5 + "y": 966.5 } ], "isCurve": true, @@ -728,55 +728,55 @@ "route": [ { "x": 67.75, - "y": 697.5 + "y": 638.5 }, { "x": 67.75, - "y": 762.2999877929688 + "y": 702.5 }, { "x": 67.75, - "y": 797.2000122070312 + "y": 737.2000122070312 }, { "x": 67.75, - "y": 825.25 + "y": 765.25 }, { "x": 67.75, - "y": 853.2999877929688 + "y": 793.2999877929688 }, { "x": 67.75, - "y": 890.7000122070312 + "y": 830.7000122070312 }, { "x": 67.75, - "y": 918.75 + "y": 858.75 }, { "x": 67.75, - "y": 946.7999877929688 + "y": 886.7999877929688 }, { "x": 67.75, - "y": 984.2000122070312 + "y": 924.2000122070312 }, { "x": 67.75, - "y": 1012.25 + "y": 952.25 }, { "x": 67.75, - "y": 1040.300048828125 + "y": 980.2999877929688 }, { "x": 78.75, - "y": 1164.699951171875 + "y": 1104.699951171875 }, { "x": 122.75, - "y": 1213.5 + "y": 1153.5 } ], "isCurve": true, @@ -811,31 +811,31 @@ "route": [ { "x": 192, - "y": 904.5 + "y": 844.5 }, { "x": 161.60000610351562, - "y": 953.2999877929688 + "y": 893.2999877929688 }, { "x": 154, - "y": 984.2000122070312 + "y": 924.2000122070312 }, { "x": 154, - "y": 1012.25 + "y": 952.25 }, { "x": 154, - "y": 1040.300048828125 + "y": 980.2999877929688 }, { "x": 153.8000030517578, - "y": 1164.699951171875 + "y": 1104.699951171875 }, { "x": 153, - "y": 1213.5 + "y": 1153.5 } ], "isCurve": true, @@ -870,19 +870,19 @@ "route": [ { "x": 271.5, - "y": 1091.5 + "y": 1031.5 }, { "x": 271.5, - "y": 1140.300048828125 + "y": 1080.300048828125 }, { "x": 254.5, - "y": 1165.9000244140625 + "y": 1105.9000244140625 }, { "x": 186.5, - "y": 1219.5 + "y": 1159.5 } ], "isCurve": true, diff --git a/e2etests/testdata/regression/glob_dimensions/dagre/sketch.exp.svg b/e2etests/testdata/regression/glob_dimensions/dagre/sketch.exp.svg index 5952fed42..2032a09f1 100644 --- a/e2etests/testdata/regression/glob_dimensions/dagre/sketch.exp.svg +++ b/e2etests/testdata/regression/glob_dimensions/dagre/sketch.exp.svg @@ -1,23 +1,23 @@ -⬤Check PINSearch NetworkReadyOff⬤Enter PIN⬤ /check PIN[pin invalid][pin OK][pin OK]network foundpower offpower offpower off - - - - - - - - - - - - - - - - - + .d2-4250727366 .fill-N1{fill:#0A0F25;} + .d2-4250727366 .fill-N2{fill:#676C7E;} + .d2-4250727366 .fill-N3{fill:#9499AB;} + .d2-4250727366 .fill-N4{fill:#CFD2DD;} + .d2-4250727366 .fill-N5{fill:#DEE1EB;} + .d2-4250727366 .fill-N6{fill:#EEF1F8;} + .d2-4250727366 .fill-N7{fill:#FFFFFF;} + .d2-4250727366 .fill-B1{fill:#0D32B2;} + .d2-4250727366 .fill-B2{fill:#0D32B2;} + .d2-4250727366 .fill-B3{fill:#E3E9FD;} + .d2-4250727366 .fill-B4{fill:#E3E9FD;} + .d2-4250727366 .fill-B5{fill:#EDF0FD;} + .d2-4250727366 .fill-B6{fill:#F7F8FE;} + .d2-4250727366 .fill-AA2{fill:#4A6FF3;} + .d2-4250727366 .fill-AA4{fill:#EDF0FD;} + .d2-4250727366 .fill-AA5{fill:#F7F8FE;} + .d2-4250727366 .fill-AB4{fill:#EDF0FD;} + .d2-4250727366 .fill-AB5{fill:#F7F8FE;} + .d2-4250727366 .stroke-N1{stroke:#0A0F25;} + .d2-4250727366 .stroke-N2{stroke:#676C7E;} + .d2-4250727366 .stroke-N3{stroke:#9499AB;} + .d2-4250727366 .stroke-N4{stroke:#CFD2DD;} + .d2-4250727366 .stroke-N5{stroke:#DEE1EB;} + .d2-4250727366 .stroke-N6{stroke:#EEF1F8;} + .d2-4250727366 .stroke-N7{stroke:#FFFFFF;} + .d2-4250727366 .stroke-B1{stroke:#0D32B2;} + .d2-4250727366 .stroke-B2{stroke:#0D32B2;} + .d2-4250727366 .stroke-B3{stroke:#E3E9FD;} + .d2-4250727366 .stroke-B4{stroke:#E3E9FD;} + .d2-4250727366 .stroke-B5{stroke:#EDF0FD;} + .d2-4250727366 .stroke-B6{stroke:#F7F8FE;} + .d2-4250727366 .stroke-AA2{stroke:#4A6FF3;} + .d2-4250727366 .stroke-AA4{stroke:#EDF0FD;} + .d2-4250727366 .stroke-AA5{stroke:#F7F8FE;} + .d2-4250727366 .stroke-AB4{stroke:#EDF0FD;} + .d2-4250727366 .stroke-AB5{stroke:#F7F8FE;} + .d2-4250727366 .background-color-N1{background-color:#0A0F25;} + .d2-4250727366 .background-color-N2{background-color:#676C7E;} + .d2-4250727366 .background-color-N3{background-color:#9499AB;} + .d2-4250727366 .background-color-N4{background-color:#CFD2DD;} + .d2-4250727366 .background-color-N5{background-color:#DEE1EB;} + .d2-4250727366 .background-color-N6{background-color:#EEF1F8;} + .d2-4250727366 .background-color-N7{background-color:#FFFFFF;} + .d2-4250727366 .background-color-B1{background-color:#0D32B2;} + .d2-4250727366 .background-color-B2{background-color:#0D32B2;} + .d2-4250727366 .background-color-B3{background-color:#E3E9FD;} + .d2-4250727366 .background-color-B4{background-color:#E3E9FD;} + .d2-4250727366 .background-color-B5{background-color:#EDF0FD;} + .d2-4250727366 .background-color-B6{background-color:#F7F8FE;} + .d2-4250727366 .background-color-AA2{background-color:#4A6FF3;} + .d2-4250727366 .background-color-AA4{background-color:#EDF0FD;} + .d2-4250727366 .background-color-AA5{background-color:#F7F8FE;} + .d2-4250727366 .background-color-AB4{background-color:#EDF0FD;} + .d2-4250727366 .background-color-AB5{background-color:#F7F8FE;} + .d2-4250727366 .color-N1{color:#0A0F25;} + .d2-4250727366 .color-N2{color:#676C7E;} + .d2-4250727366 .color-N3{color:#9499AB;} + .d2-4250727366 .color-N4{color:#CFD2DD;} + .d2-4250727366 .color-N5{color:#DEE1EB;} + .d2-4250727366 .color-N6{color:#EEF1F8;} + .d2-4250727366 .color-N7{color:#FFFFFF;} + .d2-4250727366 .color-B1{color:#0D32B2;} + .d2-4250727366 .color-B2{color:#0D32B2;} + .d2-4250727366 .color-B3{color:#E3E9FD;} + .d2-4250727366 .color-B4{color:#E3E9FD;} + .d2-4250727366 .color-B5{color:#EDF0FD;} + .d2-4250727366 .color-B6{color:#F7F8FE;} + .d2-4250727366 .color-AA2{color:#4A6FF3;} + .d2-4250727366 .color-AA4{color:#EDF0FD;} + .d2-4250727366 .color-AA5{color:#F7F8FE;} + .d2-4250727366 .color-AB4{color:#EDF0FD;} + .d2-4250727366 .color-AB5{color:#F7F8FE;}.appendix text.text{fill:#0A0F25}.md{--color-fg-default:#0A0F25;--color-fg-muted:#676C7E;--color-fg-subtle:#9499AB;--color-canvas-default:#FFFFFF;--color-canvas-subtle:#EEF1F8;--color-border-default:#0D32B2;--color-border-muted:#0D32B2;--color-neutral-muted:#EEF1F8;--color-accent-fg:#0D32B2;--color-accent-emphasis:#0D32B2;--color-attention-subtle:#676C7E;--color-danger-fg:red;}.sketch-overlay-B1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B2{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B3{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-AA4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-N2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-N3{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N4{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N7{fill:url(#streaks-bright);mix-blend-mode:darken}.light-code{display: block}.dark-code{display: none}]]>⬤Check PINSearch NetworkReadyOff⬤Enter PIN⬤ /check PIN[pin invalid][pin OK][pin OK]network foundpower offpower offpower off + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/e2etests/testdata/regression/glob_dimensions/elk/board.exp.json b/e2etests/testdata/regression/glob_dimensions/elk/board.exp.json index aec42cecc..61b314cc0 100644 --- a/e2etests/testdata/regression/glob_dimensions/elk/board.exp.json +++ b/e2etests/testdata/regression/glob_dimensions/elk/board.exp.json @@ -7,11 +7,11 @@ "id": "start", "type": "oval", "pos": { - "x": 153, + "x": 163, "y": 12 }, - "width": 30, - "height": 30, + "width": 10, + "height": 10, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -40,7 +40,7 @@ "underline": false, "labelWidth": 9, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 1 }, @@ -49,10 +49,10 @@ "type": "rectangle", "pos": { "x": 37, - "y": 112 + "y": 118 }, "width": 262, - "height": 658, + "height": 670, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -89,11 +89,11 @@ "id": "Check PIN.start", "type": "oval", "pos": { - "x": 151, - "y": 162 + "x": 161, + "y": 168 }, - "width": 30, - "height": 30, + "width": 10, + "height": 10, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -122,7 +122,7 @@ "underline": false, "labelWidth": 9, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 2 }, @@ -131,7 +131,7 @@ "type": "rectangle", "pos": { "x": 111, - "y": 262 + "y": 274 }, "width": 111, "height": 66, @@ -172,7 +172,7 @@ "type": "diamond", "pos": { "x": 156, - "y": 509 + "y": 521 }, "width": 20, "height": 20, @@ -211,11 +211,11 @@ "id": "Check PIN.end", "type": "oval", "pos": { - "x": 151, - "y": 690 + "x": 161, + "y": 702 }, - "width": 30, - "height": 30, + "width": 10, + "height": 10, "opacity": 1, "strokeDash": 0, "strokeWidth": 2, @@ -244,7 +244,7 @@ "underline": false, "labelWidth": 9, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 2 }, @@ -253,7 +253,7 @@ "type": "rectangle", "pos": { "x": 29, - "y": 941 + "y": 959 }, "width": 159, "height": 66, @@ -294,7 +294,7 @@ "type": "rectangle", "pos": { "x": 15, - "y": 1178 + "y": 1196 }, "width": 89, "height": 66, @@ -335,7 +335,7 @@ "type": "rectangle", "pos": { "x": 95, - "y": 1415 + "y": 1433 }, "width": 120, "height": 66, @@ -398,12 +398,12 @@ "labelPercentage": 0, "route": [ { - "x": 169, - "y": 42 + "x": 168.5, + "y": 48 }, { - "x": 168, - "y": 112 + "x": 168.5, + "y": 118 } ], "animated": false, @@ -436,12 +436,12 @@ "labelPercentage": 0, "route": [ { - "x": 167, - "y": 192 + "x": 166.5, + "y": 204 }, { - "x": 166, - "y": 262 + "x": 166.5, + "y": 274 } ], "animated": false, @@ -475,19 +475,19 @@ "route": [ { "x": 123.5, - "y": 328 + "y": 340 }, { "x": 123.5, - "y": 469 + "y": 481 }, { "x": 163.16600036621094, - "y": 469 + "y": 481 }, { "x": 163, - "y": 512 + "y": 524 } ], "animated": false, @@ -521,19 +521,19 @@ "route": [ { "x": 170, - "y": 513 + "y": 525 }, { "x": 169.83299255371094, - "y": 469 + "y": 481 }, { "x": 209.5, - "y": 469 + "y": 481 }, { "x": 209.5, - "y": 328 + "y": 340 } ], "animated": false, @@ -567,11 +567,11 @@ "route": [ { "x": 166, - "y": 528 + "y": 540 }, { "x": 167, - "y": 690 + "y": 702 } ], "animated": false, @@ -605,11 +605,11 @@ "route": [ { "x": 108.75, - "y": 770 + "y": 788 }, { "x": 108.75, - "y": 941 + "y": 959 } ], "animated": false, @@ -643,11 +643,11 @@ "route": [ { "x": 60, - "y": 1007 + "y": 1025 }, { "x": 60, - "y": 1178 + "y": 1196 } ], "animated": false, @@ -681,19 +681,19 @@ "route": [ { "x": 240.99899291992188, - "y": 770 + "y": 788 }, { "x": 240.99899291992188, - "y": 1375 + "y": 1393 }, { "x": 185.25, - "y": 1375 + "y": 1393 }, { "x": 185.25, - "y": 1415 + "y": 1433 } ], "animated": false, @@ -727,11 +727,11 @@ "route": [ { "x": 157.5, - "y": 1007 + "y": 1025 }, { "x": 157.5, - "y": 1415 + "y": 1433 } ], "animated": false, @@ -765,19 +765,19 @@ "route": [ { "x": 60, - "y": 1244 + "y": 1262 }, { "x": 60, - "y": 1375 + "y": 1393 }, { "x": 125.25, - "y": 1375 + "y": 1393 }, { "x": 125.25, - "y": 1415 + "y": 1433 } ], "animated": false, diff --git a/e2etests/testdata/regression/glob_dimensions/elk/sketch.exp.svg b/e2etests/testdata/regression/glob_dimensions/elk/sketch.exp.svg index d834ef015..7e94b6ce3 100644 --- a/e2etests/testdata/regression/glob_dimensions/elk/sketch.exp.svg +++ b/e2etests/testdata/regression/glob_dimensions/elk/sketch.exp.svg @@ -1,23 +1,23 @@ -⬤Check PINSearch NetworkReadyOff⬤Enter PIN⬤ /check PIN[pin invalid][pin OK][pin OK]network foundpower offpower offpower off - - - - - - - - - - - - - - - - - + .d2-2779426373 .fill-N1{fill:#0A0F25;} + .d2-2779426373 .fill-N2{fill:#676C7E;} + .d2-2779426373 .fill-N3{fill:#9499AB;} + .d2-2779426373 .fill-N4{fill:#CFD2DD;} + .d2-2779426373 .fill-N5{fill:#DEE1EB;} + .d2-2779426373 .fill-N6{fill:#EEF1F8;} + .d2-2779426373 .fill-N7{fill:#FFFFFF;} + .d2-2779426373 .fill-B1{fill:#0D32B2;} + .d2-2779426373 .fill-B2{fill:#0D32B2;} + .d2-2779426373 .fill-B3{fill:#E3E9FD;} + .d2-2779426373 .fill-B4{fill:#E3E9FD;} + .d2-2779426373 .fill-B5{fill:#EDF0FD;} + .d2-2779426373 .fill-B6{fill:#F7F8FE;} + .d2-2779426373 .fill-AA2{fill:#4A6FF3;} + .d2-2779426373 .fill-AA4{fill:#EDF0FD;} + .d2-2779426373 .fill-AA5{fill:#F7F8FE;} + .d2-2779426373 .fill-AB4{fill:#EDF0FD;} + .d2-2779426373 .fill-AB5{fill:#F7F8FE;} + .d2-2779426373 .stroke-N1{stroke:#0A0F25;} + .d2-2779426373 .stroke-N2{stroke:#676C7E;} + .d2-2779426373 .stroke-N3{stroke:#9499AB;} + .d2-2779426373 .stroke-N4{stroke:#CFD2DD;} + .d2-2779426373 .stroke-N5{stroke:#DEE1EB;} + .d2-2779426373 .stroke-N6{stroke:#EEF1F8;} + .d2-2779426373 .stroke-N7{stroke:#FFFFFF;} + .d2-2779426373 .stroke-B1{stroke:#0D32B2;} + .d2-2779426373 .stroke-B2{stroke:#0D32B2;} + .d2-2779426373 .stroke-B3{stroke:#E3E9FD;} + .d2-2779426373 .stroke-B4{stroke:#E3E9FD;} + .d2-2779426373 .stroke-B5{stroke:#EDF0FD;} + .d2-2779426373 .stroke-B6{stroke:#F7F8FE;} + .d2-2779426373 .stroke-AA2{stroke:#4A6FF3;} + .d2-2779426373 .stroke-AA4{stroke:#EDF0FD;} + .d2-2779426373 .stroke-AA5{stroke:#F7F8FE;} + .d2-2779426373 .stroke-AB4{stroke:#EDF0FD;} + .d2-2779426373 .stroke-AB5{stroke:#F7F8FE;} + .d2-2779426373 .background-color-N1{background-color:#0A0F25;} + .d2-2779426373 .background-color-N2{background-color:#676C7E;} + .d2-2779426373 .background-color-N3{background-color:#9499AB;} + .d2-2779426373 .background-color-N4{background-color:#CFD2DD;} + .d2-2779426373 .background-color-N5{background-color:#DEE1EB;} + .d2-2779426373 .background-color-N6{background-color:#EEF1F8;} + .d2-2779426373 .background-color-N7{background-color:#FFFFFF;} + .d2-2779426373 .background-color-B1{background-color:#0D32B2;} + .d2-2779426373 .background-color-B2{background-color:#0D32B2;} + .d2-2779426373 .background-color-B3{background-color:#E3E9FD;} + .d2-2779426373 .background-color-B4{background-color:#E3E9FD;} + .d2-2779426373 .background-color-B5{background-color:#EDF0FD;} + .d2-2779426373 .background-color-B6{background-color:#F7F8FE;} + .d2-2779426373 .background-color-AA2{background-color:#4A6FF3;} + .d2-2779426373 .background-color-AA4{background-color:#EDF0FD;} + .d2-2779426373 .background-color-AA5{background-color:#F7F8FE;} + .d2-2779426373 .background-color-AB4{background-color:#EDF0FD;} + .d2-2779426373 .background-color-AB5{background-color:#F7F8FE;} + .d2-2779426373 .color-N1{color:#0A0F25;} + .d2-2779426373 .color-N2{color:#676C7E;} + .d2-2779426373 .color-N3{color:#9499AB;} + .d2-2779426373 .color-N4{color:#CFD2DD;} + .d2-2779426373 .color-N5{color:#DEE1EB;} + .d2-2779426373 .color-N6{color:#EEF1F8;} + .d2-2779426373 .color-N7{color:#FFFFFF;} + .d2-2779426373 .color-B1{color:#0D32B2;} + .d2-2779426373 .color-B2{color:#0D32B2;} + .d2-2779426373 .color-B3{color:#E3E9FD;} + .d2-2779426373 .color-B4{color:#E3E9FD;} + .d2-2779426373 .color-B5{color:#EDF0FD;} + .d2-2779426373 .color-B6{color:#F7F8FE;} + .d2-2779426373 .color-AA2{color:#4A6FF3;} + .d2-2779426373 .color-AA4{color:#EDF0FD;} + .d2-2779426373 .color-AA5{color:#F7F8FE;} + .d2-2779426373 .color-AB4{color:#EDF0FD;} + .d2-2779426373 .color-AB5{color:#F7F8FE;}.appendix text.text{fill:#0A0F25}.md{--color-fg-default:#0A0F25;--color-fg-muted:#676C7E;--color-fg-subtle:#9499AB;--color-canvas-default:#FFFFFF;--color-canvas-subtle:#EEF1F8;--color-border-default:#0D32B2;--color-border-muted:#0D32B2;--color-neutral-muted:#EEF1F8;--color-accent-fg:#0D32B2;--color-accent-emphasis:#0D32B2;--color-attention-subtle:#676C7E;--color-danger-fg:red;}.sketch-overlay-B1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B2{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B3{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-AA4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-N2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-N3{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N4{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N7{fill:url(#streaks-bright);mix-blend-mode:darken}.light-code{display: block}.dark-code{display: none}]]>⬤Check PINSearch NetworkReadyOff⬤Enter PIN⬤ /check PIN[pin invalid][pin OK][pin OK]network foundpower offpower offpower off + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/e2etests/testdata/regression/just-width/dagre/board.exp.json b/e2etests/testdata/regression/just-width/dagre/board.exp.json index c1f63d1f6..d7d37e01c 100644 --- a/e2etests/testdata/regression/just-width/dagre/board.exp.json +++ b/e2etests/testdata/regression/just-width/dagre/board.exp.json @@ -10,7 +10,7 @@ "x": 0, "y": 0 }, - "width": 262, + "width": 100, "height": 61, "opacity": 1, "strokeDash": 0, @@ -40,7 +40,7 @@ "underline": false, "labelWidth": 262, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 1 } diff --git a/e2etests/testdata/regression/just-width/dagre/sketch.exp.svg b/e2etests/testdata/regression/just-width/dagre/sketch.exp.svg index 7133b6e3f..de3a16878 100644 --- a/e2etests/testdata/regression/just-width/dagre/sketch.exp.svg +++ b/e2etests/testdata/regression/just-width/dagre/sketch.exp.svg @@ -1,9 +1,9 @@ -teamwork: having someone to blame - - + .d2-3251595454 .fill-N1{fill:#0A0F25;} + .d2-3251595454 .fill-N2{fill:#676C7E;} + .d2-3251595454 .fill-N3{fill:#9499AB;} + .d2-3251595454 .fill-N4{fill:#CFD2DD;} + .d2-3251595454 .fill-N5{fill:#DEE1EB;} + .d2-3251595454 .fill-N6{fill:#EEF1F8;} + .d2-3251595454 .fill-N7{fill:#FFFFFF;} + .d2-3251595454 .fill-B1{fill:#0D32B2;} + .d2-3251595454 .fill-B2{fill:#0D32B2;} + .d2-3251595454 .fill-B3{fill:#E3E9FD;} + .d2-3251595454 .fill-B4{fill:#E3E9FD;} + .d2-3251595454 .fill-B5{fill:#EDF0FD;} + .d2-3251595454 .fill-B6{fill:#F7F8FE;} + .d2-3251595454 .fill-AA2{fill:#4A6FF3;} + .d2-3251595454 .fill-AA4{fill:#EDF0FD;} + .d2-3251595454 .fill-AA5{fill:#F7F8FE;} + .d2-3251595454 .fill-AB4{fill:#EDF0FD;} + .d2-3251595454 .fill-AB5{fill:#F7F8FE;} + .d2-3251595454 .stroke-N1{stroke:#0A0F25;} + .d2-3251595454 .stroke-N2{stroke:#676C7E;} + .d2-3251595454 .stroke-N3{stroke:#9499AB;} + .d2-3251595454 .stroke-N4{stroke:#CFD2DD;} + .d2-3251595454 .stroke-N5{stroke:#DEE1EB;} + .d2-3251595454 .stroke-N6{stroke:#EEF1F8;} + .d2-3251595454 .stroke-N7{stroke:#FFFFFF;} + .d2-3251595454 .stroke-B1{stroke:#0D32B2;} + .d2-3251595454 .stroke-B2{stroke:#0D32B2;} + .d2-3251595454 .stroke-B3{stroke:#E3E9FD;} + .d2-3251595454 .stroke-B4{stroke:#E3E9FD;} + .d2-3251595454 .stroke-B5{stroke:#EDF0FD;} + .d2-3251595454 .stroke-B6{stroke:#F7F8FE;} + .d2-3251595454 .stroke-AA2{stroke:#4A6FF3;} + .d2-3251595454 .stroke-AA4{stroke:#EDF0FD;} + .d2-3251595454 .stroke-AA5{stroke:#F7F8FE;} + .d2-3251595454 .stroke-AB4{stroke:#EDF0FD;} + .d2-3251595454 .stroke-AB5{stroke:#F7F8FE;} + .d2-3251595454 .background-color-N1{background-color:#0A0F25;} + .d2-3251595454 .background-color-N2{background-color:#676C7E;} + .d2-3251595454 .background-color-N3{background-color:#9499AB;} + .d2-3251595454 .background-color-N4{background-color:#CFD2DD;} + .d2-3251595454 .background-color-N5{background-color:#DEE1EB;} + .d2-3251595454 .background-color-N6{background-color:#EEF1F8;} + .d2-3251595454 .background-color-N7{background-color:#FFFFFF;} + .d2-3251595454 .background-color-B1{background-color:#0D32B2;} + .d2-3251595454 .background-color-B2{background-color:#0D32B2;} + .d2-3251595454 .background-color-B3{background-color:#E3E9FD;} + .d2-3251595454 .background-color-B4{background-color:#E3E9FD;} + .d2-3251595454 .background-color-B5{background-color:#EDF0FD;} + .d2-3251595454 .background-color-B6{background-color:#F7F8FE;} + .d2-3251595454 .background-color-AA2{background-color:#4A6FF3;} + .d2-3251595454 .background-color-AA4{background-color:#EDF0FD;} + .d2-3251595454 .background-color-AA5{background-color:#F7F8FE;} + .d2-3251595454 .background-color-AB4{background-color:#EDF0FD;} + .d2-3251595454 .background-color-AB5{background-color:#F7F8FE;} + .d2-3251595454 .color-N1{color:#0A0F25;} + .d2-3251595454 .color-N2{color:#676C7E;} + .d2-3251595454 .color-N3{color:#9499AB;} + .d2-3251595454 .color-N4{color:#CFD2DD;} + .d2-3251595454 .color-N5{color:#DEE1EB;} + .d2-3251595454 .color-N6{color:#EEF1F8;} + .d2-3251595454 .color-N7{color:#FFFFFF;} + .d2-3251595454 .color-B1{color:#0D32B2;} + .d2-3251595454 .color-B2{color:#0D32B2;} + .d2-3251595454 .color-B3{color:#E3E9FD;} + .d2-3251595454 .color-B4{color:#E3E9FD;} + .d2-3251595454 .color-B5{color:#EDF0FD;} + .d2-3251595454 .color-B6{color:#F7F8FE;} + .d2-3251595454 .color-AA2{color:#4A6FF3;} + .d2-3251595454 .color-AA4{color:#EDF0FD;} + .d2-3251595454 .color-AA5{color:#F7F8FE;} + .d2-3251595454 .color-AB4{color:#EDF0FD;} + .d2-3251595454 .color-AB5{color:#F7F8FE;}.appendix text.text{fill:#0A0F25}.md{--color-fg-default:#0A0F25;--color-fg-muted:#676C7E;--color-fg-subtle:#9499AB;--color-canvas-default:#FFFFFF;--color-canvas-subtle:#EEF1F8;--color-border-default:#0D32B2;--color-border-muted:#0D32B2;--color-neutral-muted:#EEF1F8;--color-accent-fg:#0D32B2;--color-accent-emphasis:#0D32B2;--color-attention-subtle:#676C7E;--color-danger-fg:red;}.sketch-overlay-B1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B2{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B3{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-AA4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-N2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-N3{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N4{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N7{fill:url(#streaks-bright);mix-blend-mode:darken}.light-code{display: block}.dark-code{display: none}]]>teamwork: having someone to blame + + \ No newline at end of file diff --git a/e2etests/testdata/regression/just-width/elk/board.exp.json b/e2etests/testdata/regression/just-width/elk/board.exp.json index f88d632ff..90db64280 100644 --- a/e2etests/testdata/regression/just-width/elk/board.exp.json +++ b/e2etests/testdata/regression/just-width/elk/board.exp.json @@ -10,7 +10,7 @@ "x": 12, "y": 12 }, - "width": 262, + "width": 100, "height": 61, "opacity": 1, "strokeDash": 0, @@ -40,7 +40,7 @@ "underline": false, "labelWidth": 262, "labelHeight": 21, - "labelPosition": "INSIDE_MIDDLE_CENTER", + "labelPosition": "OUTSIDE_BOTTOM_CENTER", "zIndex": 0, "level": 1 } diff --git a/e2etests/testdata/regression/just-width/elk/sketch.exp.svg b/e2etests/testdata/regression/just-width/elk/sketch.exp.svg index 4125f4e3f..3856d882c 100644 --- a/e2etests/testdata/regression/just-width/elk/sketch.exp.svg +++ b/e2etests/testdata/regression/just-width/elk/sketch.exp.svg @@ -1,9 +1,9 @@ -teamwork: having someone to blame - - + .d2-1014957270 .fill-N1{fill:#0A0F25;} + .d2-1014957270 .fill-N2{fill:#676C7E;} + .d2-1014957270 .fill-N3{fill:#9499AB;} + .d2-1014957270 .fill-N4{fill:#CFD2DD;} + .d2-1014957270 .fill-N5{fill:#DEE1EB;} + .d2-1014957270 .fill-N6{fill:#EEF1F8;} + .d2-1014957270 .fill-N7{fill:#FFFFFF;} + .d2-1014957270 .fill-B1{fill:#0D32B2;} + .d2-1014957270 .fill-B2{fill:#0D32B2;} + .d2-1014957270 .fill-B3{fill:#E3E9FD;} + .d2-1014957270 .fill-B4{fill:#E3E9FD;} + .d2-1014957270 .fill-B5{fill:#EDF0FD;} + .d2-1014957270 .fill-B6{fill:#F7F8FE;} + .d2-1014957270 .fill-AA2{fill:#4A6FF3;} + .d2-1014957270 .fill-AA4{fill:#EDF0FD;} + .d2-1014957270 .fill-AA5{fill:#F7F8FE;} + .d2-1014957270 .fill-AB4{fill:#EDF0FD;} + .d2-1014957270 .fill-AB5{fill:#F7F8FE;} + .d2-1014957270 .stroke-N1{stroke:#0A0F25;} + .d2-1014957270 .stroke-N2{stroke:#676C7E;} + .d2-1014957270 .stroke-N3{stroke:#9499AB;} + .d2-1014957270 .stroke-N4{stroke:#CFD2DD;} + .d2-1014957270 .stroke-N5{stroke:#DEE1EB;} + .d2-1014957270 .stroke-N6{stroke:#EEF1F8;} + .d2-1014957270 .stroke-N7{stroke:#FFFFFF;} + .d2-1014957270 .stroke-B1{stroke:#0D32B2;} + .d2-1014957270 .stroke-B2{stroke:#0D32B2;} + .d2-1014957270 .stroke-B3{stroke:#E3E9FD;} + .d2-1014957270 .stroke-B4{stroke:#E3E9FD;} + .d2-1014957270 .stroke-B5{stroke:#EDF0FD;} + .d2-1014957270 .stroke-B6{stroke:#F7F8FE;} + .d2-1014957270 .stroke-AA2{stroke:#4A6FF3;} + .d2-1014957270 .stroke-AA4{stroke:#EDF0FD;} + .d2-1014957270 .stroke-AA5{stroke:#F7F8FE;} + .d2-1014957270 .stroke-AB4{stroke:#EDF0FD;} + .d2-1014957270 .stroke-AB5{stroke:#F7F8FE;} + .d2-1014957270 .background-color-N1{background-color:#0A0F25;} + .d2-1014957270 .background-color-N2{background-color:#676C7E;} + .d2-1014957270 .background-color-N3{background-color:#9499AB;} + .d2-1014957270 .background-color-N4{background-color:#CFD2DD;} + .d2-1014957270 .background-color-N5{background-color:#DEE1EB;} + .d2-1014957270 .background-color-N6{background-color:#EEF1F8;} + .d2-1014957270 .background-color-N7{background-color:#FFFFFF;} + .d2-1014957270 .background-color-B1{background-color:#0D32B2;} + .d2-1014957270 .background-color-B2{background-color:#0D32B2;} + .d2-1014957270 .background-color-B3{background-color:#E3E9FD;} + .d2-1014957270 .background-color-B4{background-color:#E3E9FD;} + .d2-1014957270 .background-color-B5{background-color:#EDF0FD;} + .d2-1014957270 .background-color-B6{background-color:#F7F8FE;} + .d2-1014957270 .background-color-AA2{background-color:#4A6FF3;} + .d2-1014957270 .background-color-AA4{background-color:#EDF0FD;} + .d2-1014957270 .background-color-AA5{background-color:#F7F8FE;} + .d2-1014957270 .background-color-AB4{background-color:#EDF0FD;} + .d2-1014957270 .background-color-AB5{background-color:#F7F8FE;} + .d2-1014957270 .color-N1{color:#0A0F25;} + .d2-1014957270 .color-N2{color:#676C7E;} + .d2-1014957270 .color-N3{color:#9499AB;} + .d2-1014957270 .color-N4{color:#CFD2DD;} + .d2-1014957270 .color-N5{color:#DEE1EB;} + .d2-1014957270 .color-N6{color:#EEF1F8;} + .d2-1014957270 .color-N7{color:#FFFFFF;} + .d2-1014957270 .color-B1{color:#0D32B2;} + .d2-1014957270 .color-B2{color:#0D32B2;} + .d2-1014957270 .color-B3{color:#E3E9FD;} + .d2-1014957270 .color-B4{color:#E3E9FD;} + .d2-1014957270 .color-B5{color:#EDF0FD;} + .d2-1014957270 .color-B6{color:#F7F8FE;} + .d2-1014957270 .color-AA2{color:#4A6FF3;} + .d2-1014957270 .color-AA4{color:#EDF0FD;} + .d2-1014957270 .color-AA5{color:#F7F8FE;} + .d2-1014957270 .color-AB4{color:#EDF0FD;} + .d2-1014957270 .color-AB5{color:#F7F8FE;}.appendix text.text{fill:#0A0F25}.md{--color-fg-default:#0A0F25;--color-fg-muted:#676C7E;--color-fg-subtle:#9499AB;--color-canvas-default:#FFFFFF;--color-canvas-subtle:#EEF1F8;--color-border-default:#0D32B2;--color-border-muted:#0D32B2;--color-neutral-muted:#EEF1F8;--color-accent-fg:#0D32B2;--color-accent-emphasis:#0D32B2;--color-attention-subtle:#676C7E;--color-danger-fg:red;}.sketch-overlay-B1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B2{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B3{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-AA4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-N2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-N3{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N4{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N7{fill:url(#streaks-bright);mix-blend-mode:darken}.light-code{display: block}.dark-code{display: none}]]>teamwork: having someone to blame + + \ No newline at end of file diff --git a/e2etests/testdata/stable/simple_grid_edges/dagre/board.exp.json b/e2etests/testdata/stable/simple_grid_edges/dagre/board.exp.json index 3247aa247..52e639ce5 100644 --- a/e2etests/testdata/stable/simple_grid_edges/dagre/board.exp.json +++ b/e2etests/testdata/stable/simple_grid_edges/dagre/board.exp.json @@ -192,7 +192,7 @@ "x": 480, "y": 0 }, - "width": 120, + "width": 100, "height": 60, "opacity": 1, "strokeDash": 0, @@ -408,7 +408,7 @@ "x": 480, "y": 65 }, - "width": 120, + "width": 100, "height": 30, "opacity": 1, "strokeDash": 0, @@ -632,7 +632,7 @@ "x": 480, "y": 100 }, - "width": 120, + "width": 100, "height": 60, "opacity": 1, "strokeDash": 0, @@ -852,7 +852,7 @@ "x": 480, "y": 165 }, - "width": 120, + "width": 100, "height": 30, "opacity": 1, "strokeDash": 0, @@ -1188,7 +1188,7 @@ "x": 480, "y": 200 }, - "width": 120, + "width": 100, "height": 60, "opacity": 1, "strokeDash": 0, @@ -1539,11 +1539,11 @@ "labelPercentage": 0, "route": [ { - "x": 540, + "x": 530, "y": 100 }, { - "x": 540, + "x": 530, "y": 60 } ], @@ -1580,11 +1580,11 @@ "labelPercentage": 0, "route": [ { - "x": 540, + "x": 530, "y": 160 }, { - "x": 540, + "x": 530, "y": 200 } ], diff --git a/e2etests/testdata/stable/simple_grid_edges/dagre/sketch.exp.svg b/e2etests/testdata/stable/simple_grid_edges/dagre/sketch.exp.svg index a6635f2aa..31595c534 100644 --- a/e2etests/testdata/stable/simple_grid_edges/dagre/sketch.exp.svg +++ b/e2etests/testdata/stable/simple_grid_edges/dagre/sketch.exp.svg @@ -1,23 +1,23 @@ -npm i -g@forge/cliSet up anAtlassian siteView the helloworld appforgetunnelforgeloginforgecreateforgedeployforgeinstallHot reloadchanges?Step 1Step 2Step 3Step 4forgedeploy⬤ Forge CLI⬤ Required⬤ Optional YesNo - + .d2-29674933 .fill-N1{fill:#0A0F25;} + .d2-29674933 .fill-N2{fill:#676C7E;} + .d2-29674933 .fill-N3{fill:#9499AB;} + .d2-29674933 .fill-N4{fill:#CFD2DD;} + .d2-29674933 .fill-N5{fill:#DEE1EB;} + .d2-29674933 .fill-N6{fill:#EEF1F8;} + .d2-29674933 .fill-N7{fill:#FFFFFF;} + .d2-29674933 .fill-B1{fill:#0D32B2;} + .d2-29674933 .fill-B2{fill:#0D32B2;} + .d2-29674933 .fill-B3{fill:#E3E9FD;} + .d2-29674933 .fill-B4{fill:#E3E9FD;} + .d2-29674933 .fill-B5{fill:#EDF0FD;} + .d2-29674933 .fill-B6{fill:#F7F8FE;} + .d2-29674933 .fill-AA2{fill:#4A6FF3;} + .d2-29674933 .fill-AA4{fill:#EDF0FD;} + .d2-29674933 .fill-AA5{fill:#F7F8FE;} + .d2-29674933 .fill-AB4{fill:#EDF0FD;} + .d2-29674933 .fill-AB5{fill:#F7F8FE;} + .d2-29674933 .stroke-N1{stroke:#0A0F25;} + .d2-29674933 .stroke-N2{stroke:#676C7E;} + .d2-29674933 .stroke-N3{stroke:#9499AB;} + .d2-29674933 .stroke-N4{stroke:#CFD2DD;} + .d2-29674933 .stroke-N5{stroke:#DEE1EB;} + .d2-29674933 .stroke-N6{stroke:#EEF1F8;} + .d2-29674933 .stroke-N7{stroke:#FFFFFF;} + .d2-29674933 .stroke-B1{stroke:#0D32B2;} + .d2-29674933 .stroke-B2{stroke:#0D32B2;} + .d2-29674933 .stroke-B3{stroke:#E3E9FD;} + .d2-29674933 .stroke-B4{stroke:#E3E9FD;} + .d2-29674933 .stroke-B5{stroke:#EDF0FD;} + .d2-29674933 .stroke-B6{stroke:#F7F8FE;} + .d2-29674933 .stroke-AA2{stroke:#4A6FF3;} + .d2-29674933 .stroke-AA4{stroke:#EDF0FD;} + .d2-29674933 .stroke-AA5{stroke:#F7F8FE;} + .d2-29674933 .stroke-AB4{stroke:#EDF0FD;} + .d2-29674933 .stroke-AB5{stroke:#F7F8FE;} + .d2-29674933 .background-color-N1{background-color:#0A0F25;} + .d2-29674933 .background-color-N2{background-color:#676C7E;} + .d2-29674933 .background-color-N3{background-color:#9499AB;} + .d2-29674933 .background-color-N4{background-color:#CFD2DD;} + .d2-29674933 .background-color-N5{background-color:#DEE1EB;} + .d2-29674933 .background-color-N6{background-color:#EEF1F8;} + .d2-29674933 .background-color-N7{background-color:#FFFFFF;} + .d2-29674933 .background-color-B1{background-color:#0D32B2;} + .d2-29674933 .background-color-B2{background-color:#0D32B2;} + .d2-29674933 .background-color-B3{background-color:#E3E9FD;} + .d2-29674933 .background-color-B4{background-color:#E3E9FD;} + .d2-29674933 .background-color-B5{background-color:#EDF0FD;} + .d2-29674933 .background-color-B6{background-color:#F7F8FE;} + .d2-29674933 .background-color-AA2{background-color:#4A6FF3;} + .d2-29674933 .background-color-AA4{background-color:#EDF0FD;} + .d2-29674933 .background-color-AA5{background-color:#F7F8FE;} + .d2-29674933 .background-color-AB4{background-color:#EDF0FD;} + .d2-29674933 .background-color-AB5{background-color:#F7F8FE;} + .d2-29674933 .color-N1{color:#0A0F25;} + .d2-29674933 .color-N2{color:#676C7E;} + .d2-29674933 .color-N3{color:#9499AB;} + .d2-29674933 .color-N4{color:#CFD2DD;} + .d2-29674933 .color-N5{color:#DEE1EB;} + .d2-29674933 .color-N6{color:#EEF1F8;} + .d2-29674933 .color-N7{color:#FFFFFF;} + .d2-29674933 .color-B1{color:#0D32B2;} + .d2-29674933 .color-B2{color:#0D32B2;} + .d2-29674933 .color-B3{color:#E3E9FD;} + .d2-29674933 .color-B4{color:#E3E9FD;} + .d2-29674933 .color-B5{color:#EDF0FD;} + .d2-29674933 .color-B6{color:#F7F8FE;} + .d2-29674933 .color-AA2{color:#4A6FF3;} + .d2-29674933 .color-AA4{color:#EDF0FD;} + .d2-29674933 .color-AA5{color:#F7F8FE;} + .d2-29674933 .color-AB4{color:#EDF0FD;} + .d2-29674933 .color-AB5{color:#F7F8FE;}.appendix text.text{fill:#0A0F25}.md{--color-fg-default:#0A0F25;--color-fg-muted:#676C7E;--color-fg-subtle:#9499AB;--color-canvas-default:#FFFFFF;--color-canvas-subtle:#EEF1F8;--color-border-default:#0D32B2;--color-border-muted:#0D32B2;--color-neutral-muted:#EEF1F8;--color-accent-fg:#0D32B2;--color-accent-emphasis:#0D32B2;--color-attention-subtle:#676C7E;--color-danger-fg:red;}.sketch-overlay-B1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B2{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B3{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-AA4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-N2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-N3{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N4{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N7{fill:url(#streaks-bright);mix-blend-mode:darken}.light-code{display: block}.dark-code{display: none}]]>npm i -g@forge/cliSet up anAtlassian siteView the helloworld appforgetunnelforgeloginforgecreateforgedeployforgeinstallHot reloadchanges?Step 1Step 2Step 3Step 4forgedeploy⬤ Forge CLI⬤ Required⬤ Optional YesNo + - + - + - + - - + + \ No newline at end of file diff --git a/e2etests/testdata/stable/simple_grid_edges/elk/board.exp.json b/e2etests/testdata/stable/simple_grid_edges/elk/board.exp.json index 3247aa247..52e639ce5 100644 --- a/e2etests/testdata/stable/simple_grid_edges/elk/board.exp.json +++ b/e2etests/testdata/stable/simple_grid_edges/elk/board.exp.json @@ -192,7 +192,7 @@ "x": 480, "y": 0 }, - "width": 120, + "width": 100, "height": 60, "opacity": 1, "strokeDash": 0, @@ -408,7 +408,7 @@ "x": 480, "y": 65 }, - "width": 120, + "width": 100, "height": 30, "opacity": 1, "strokeDash": 0, @@ -632,7 +632,7 @@ "x": 480, "y": 100 }, - "width": 120, + "width": 100, "height": 60, "opacity": 1, "strokeDash": 0, @@ -852,7 +852,7 @@ "x": 480, "y": 165 }, - "width": 120, + "width": 100, "height": 30, "opacity": 1, "strokeDash": 0, @@ -1188,7 +1188,7 @@ "x": 480, "y": 200 }, - "width": 120, + "width": 100, "height": 60, "opacity": 1, "strokeDash": 0, @@ -1539,11 +1539,11 @@ "labelPercentage": 0, "route": [ { - "x": 540, + "x": 530, "y": 100 }, { - "x": 540, + "x": 530, "y": 60 } ], @@ -1580,11 +1580,11 @@ "labelPercentage": 0, "route": [ { - "x": 540, + "x": 530, "y": 160 }, { - "x": 540, + "x": 530, "y": 200 } ], diff --git a/e2etests/testdata/stable/simple_grid_edges/elk/sketch.exp.svg b/e2etests/testdata/stable/simple_grid_edges/elk/sketch.exp.svg index a6635f2aa..31595c534 100644 --- a/e2etests/testdata/stable/simple_grid_edges/elk/sketch.exp.svg +++ b/e2etests/testdata/stable/simple_grid_edges/elk/sketch.exp.svg @@ -1,23 +1,23 @@ -npm i -g@forge/cliSet up anAtlassian siteView the helloworld appforgetunnelforgeloginforgecreateforgedeployforgeinstallHot reloadchanges?Step 1Step 2Step 3Step 4forgedeploy⬤ Forge CLI⬤ Required⬤ Optional YesNo - + .d2-29674933 .fill-N1{fill:#0A0F25;} + .d2-29674933 .fill-N2{fill:#676C7E;} + .d2-29674933 .fill-N3{fill:#9499AB;} + .d2-29674933 .fill-N4{fill:#CFD2DD;} + .d2-29674933 .fill-N5{fill:#DEE1EB;} + .d2-29674933 .fill-N6{fill:#EEF1F8;} + .d2-29674933 .fill-N7{fill:#FFFFFF;} + .d2-29674933 .fill-B1{fill:#0D32B2;} + .d2-29674933 .fill-B2{fill:#0D32B2;} + .d2-29674933 .fill-B3{fill:#E3E9FD;} + .d2-29674933 .fill-B4{fill:#E3E9FD;} + .d2-29674933 .fill-B5{fill:#EDF0FD;} + .d2-29674933 .fill-B6{fill:#F7F8FE;} + .d2-29674933 .fill-AA2{fill:#4A6FF3;} + .d2-29674933 .fill-AA4{fill:#EDF0FD;} + .d2-29674933 .fill-AA5{fill:#F7F8FE;} + .d2-29674933 .fill-AB4{fill:#EDF0FD;} + .d2-29674933 .fill-AB5{fill:#F7F8FE;} + .d2-29674933 .stroke-N1{stroke:#0A0F25;} + .d2-29674933 .stroke-N2{stroke:#676C7E;} + .d2-29674933 .stroke-N3{stroke:#9499AB;} + .d2-29674933 .stroke-N4{stroke:#CFD2DD;} + .d2-29674933 .stroke-N5{stroke:#DEE1EB;} + .d2-29674933 .stroke-N6{stroke:#EEF1F8;} + .d2-29674933 .stroke-N7{stroke:#FFFFFF;} + .d2-29674933 .stroke-B1{stroke:#0D32B2;} + .d2-29674933 .stroke-B2{stroke:#0D32B2;} + .d2-29674933 .stroke-B3{stroke:#E3E9FD;} + .d2-29674933 .stroke-B4{stroke:#E3E9FD;} + .d2-29674933 .stroke-B5{stroke:#EDF0FD;} + .d2-29674933 .stroke-B6{stroke:#F7F8FE;} + .d2-29674933 .stroke-AA2{stroke:#4A6FF3;} + .d2-29674933 .stroke-AA4{stroke:#EDF0FD;} + .d2-29674933 .stroke-AA5{stroke:#F7F8FE;} + .d2-29674933 .stroke-AB4{stroke:#EDF0FD;} + .d2-29674933 .stroke-AB5{stroke:#F7F8FE;} + .d2-29674933 .background-color-N1{background-color:#0A0F25;} + .d2-29674933 .background-color-N2{background-color:#676C7E;} + .d2-29674933 .background-color-N3{background-color:#9499AB;} + .d2-29674933 .background-color-N4{background-color:#CFD2DD;} + .d2-29674933 .background-color-N5{background-color:#DEE1EB;} + .d2-29674933 .background-color-N6{background-color:#EEF1F8;} + .d2-29674933 .background-color-N7{background-color:#FFFFFF;} + .d2-29674933 .background-color-B1{background-color:#0D32B2;} + .d2-29674933 .background-color-B2{background-color:#0D32B2;} + .d2-29674933 .background-color-B3{background-color:#E3E9FD;} + .d2-29674933 .background-color-B4{background-color:#E3E9FD;} + .d2-29674933 .background-color-B5{background-color:#EDF0FD;} + .d2-29674933 .background-color-B6{background-color:#F7F8FE;} + .d2-29674933 .background-color-AA2{background-color:#4A6FF3;} + .d2-29674933 .background-color-AA4{background-color:#EDF0FD;} + .d2-29674933 .background-color-AA5{background-color:#F7F8FE;} + .d2-29674933 .background-color-AB4{background-color:#EDF0FD;} + .d2-29674933 .background-color-AB5{background-color:#F7F8FE;} + .d2-29674933 .color-N1{color:#0A0F25;} + .d2-29674933 .color-N2{color:#676C7E;} + .d2-29674933 .color-N3{color:#9499AB;} + .d2-29674933 .color-N4{color:#CFD2DD;} + .d2-29674933 .color-N5{color:#DEE1EB;} + .d2-29674933 .color-N6{color:#EEF1F8;} + .d2-29674933 .color-N7{color:#FFFFFF;} + .d2-29674933 .color-B1{color:#0D32B2;} + .d2-29674933 .color-B2{color:#0D32B2;} + .d2-29674933 .color-B3{color:#E3E9FD;} + .d2-29674933 .color-B4{color:#E3E9FD;} + .d2-29674933 .color-B5{color:#EDF0FD;} + .d2-29674933 .color-B6{color:#F7F8FE;} + .d2-29674933 .color-AA2{color:#4A6FF3;} + .d2-29674933 .color-AA4{color:#EDF0FD;} + .d2-29674933 .color-AA5{color:#F7F8FE;} + .d2-29674933 .color-AB4{color:#EDF0FD;} + .d2-29674933 .color-AB5{color:#F7F8FE;}.appendix text.text{fill:#0A0F25}.md{--color-fg-default:#0A0F25;--color-fg-muted:#676C7E;--color-fg-subtle:#9499AB;--color-canvas-default:#FFFFFF;--color-canvas-subtle:#EEF1F8;--color-border-default:#0D32B2;--color-border-muted:#0D32B2;--color-neutral-muted:#EEF1F8;--color-accent-fg:#0D32B2;--color-accent-emphasis:#0D32B2;--color-attention-subtle:#676C7E;--color-danger-fg:red;}.sketch-overlay-B1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B2{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-B3{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-B6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-AA4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AA5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB4{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-AB5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N1{fill:url(#streaks-darker);mix-blend-mode:lighten}.sketch-overlay-N2{fill:url(#streaks-dark);mix-blend-mode:overlay}.sketch-overlay-N3{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N4{fill:url(#streaks-normal);mix-blend-mode:color-burn}.sketch-overlay-N5{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N6{fill:url(#streaks-bright);mix-blend-mode:darken}.sketch-overlay-N7{fill:url(#streaks-bright);mix-blend-mode:darken}.light-code{display: block}.dark-code{display: none}]]>npm i -g@forge/cliSet up anAtlassian siteView the helloworld appforgetunnelforgeloginforgecreateforgedeployforgeinstallHot reloadchanges?Step 1Step 2Step 3Step 4forgedeploy⬤ Forge CLI⬤ Required⬤ Optional YesNo + - + - + - + - - + + \ No newline at end of file diff --git a/e2etests/testdata/txtar.txt b/e2etests/testdata/txtar.txt index 8982b8da7..e6d17bf6d 100644 --- a/e2etests/testdata/txtar.txt +++ b/e2etests/testdata/txtar.txt @@ -181,3 +181,10 @@ vars: { } a.style.fill-pattern: none b + +-- width-smaller-than-label -- +b: hello there cat { + shape: person + width: 64 + height: 66 +} diff --git a/e2etests/testdata/txtar/width-smaller-than-label/dagre/board.exp.json b/e2etests/testdata/txtar/width-smaller-than-label/dagre/board.exp.json new file mode 100644 index 000000000..e7a9496a4 --- /dev/null +++ b/e2etests/testdata/txtar/width-smaller-than-label/dagre/board.exp.json @@ -0,0 +1,89 @@ +{ + "name": "", + "isFolderOnly": false, + "fontFamily": "SourceSansPro", + "shapes": [ + { + "id": "b", + "type": "person", + "pos": { + "x": 0, + "y": 0 + }, + "width": 64, + "height": 66, + "opacity": 1, + "strokeDash": 0, + "strokeWidth": 2, + "borderRadius": 0, + "fill": "B3", + "stroke": "B1", + "shadow": false, + "3d": false, + "multiple": false, + "double-border": false, + "tooltip": "", + "link": "", + "icon": null, + "iconPosition": "", + "blend": false, + "fields": null, + "methods": null, + "columns": null, + "label": "hello there cat", + "fontSize": 16, + "fontFamily": "DEFAULT", + "language": "", + "color": "N1", + "italic": false, + "bold": true, + "underline": false, + "labelWidth": 101, + "labelHeight": 21, + "labelPosition": "OUTSIDE_BOTTOM_CENTER", + "zIndex": 0, + "level": 1 + } + ], + "connections": [], + "root": { + "id": "", + "type": "", + "pos": { + "x": 0, + "y": 0 + }, + "width": 0, + "height": 0, + "opacity": 0, + "strokeDash": 0, + "strokeWidth": 0, + "borderRadius": 0, + "fill": "N7", + "stroke": "", + "shadow": false, + "3d": false, + "multiple": false, + "double-border": false, + "tooltip": "", + "link": "", + "icon": null, + "iconPosition": "", + "blend": false, + "fields": null, + "methods": null, + "columns": null, + "label": "", + "fontSize": 0, + "fontFamily": "", + "language": "", + "color": "", + "italic": false, + "bold": false, + "underline": false, + "labelWidth": 0, + "labelHeight": 0, + "zIndex": 0, + "level": 0 + } +} diff --git a/e2etests/testdata/txtar/width-smaller-than-label/dagre/sketch.exp.svg b/e2etests/testdata/txtar/width-smaller-than-label/dagre/sketch.exp.svg new file mode 100644 index 000000000..6b61707bb --- /dev/null +++ b/e2etests/testdata/txtar/width-smaller-than-label/dagre/sketch.exp.svg @@ -0,0 +1,95 @@ +hello there cat + + + \ No newline at end of file diff --git a/e2etests/testdata/txtar/width-smaller-than-label/elk/board.exp.json b/e2etests/testdata/txtar/width-smaller-than-label/elk/board.exp.json new file mode 100644 index 000000000..605a1b81b --- /dev/null +++ b/e2etests/testdata/txtar/width-smaller-than-label/elk/board.exp.json @@ -0,0 +1,89 @@ +{ + "name": "", + "isFolderOnly": false, + "fontFamily": "SourceSansPro", + "shapes": [ + { + "id": "b", + "type": "person", + "pos": { + "x": 12, + "y": 12 + }, + "width": 64, + "height": 66, + "opacity": 1, + "strokeDash": 0, + "strokeWidth": 2, + "borderRadius": 0, + "fill": "B3", + "stroke": "B1", + "shadow": false, + "3d": false, + "multiple": false, + "double-border": false, + "tooltip": "", + "link": "", + "icon": null, + "iconPosition": "", + "blend": false, + "fields": null, + "methods": null, + "columns": null, + "label": "hello there cat", + "fontSize": 16, + "fontFamily": "DEFAULT", + "language": "", + "color": "N1", + "italic": false, + "bold": true, + "underline": false, + "labelWidth": 101, + "labelHeight": 21, + "labelPosition": "OUTSIDE_BOTTOM_CENTER", + "zIndex": 0, + "level": 1 + } + ], + "connections": [], + "root": { + "id": "", + "type": "", + "pos": { + "x": 0, + "y": 0 + }, + "width": 0, + "height": 0, + "opacity": 0, + "strokeDash": 0, + "strokeWidth": 0, + "borderRadius": 0, + "fill": "N7", + "stroke": "", + "shadow": false, + "3d": false, + "multiple": false, + "double-border": false, + "tooltip": "", + "link": "", + "icon": null, + "iconPosition": "", + "blend": false, + "fields": null, + "methods": null, + "columns": null, + "label": "", + "fontSize": 0, + "fontFamily": "", + "language": "", + "color": "", + "italic": false, + "bold": false, + "underline": false, + "labelWidth": 0, + "labelHeight": 0, + "zIndex": 0, + "level": 0 + } +} diff --git a/e2etests/testdata/txtar/width-smaller-than-label/elk/sketch.exp.svg b/e2etests/testdata/txtar/width-smaller-than-label/elk/sketch.exp.svg new file mode 100644 index 000000000..89d6e2411 --- /dev/null +++ b/e2etests/testdata/txtar/width-smaller-than-label/elk/sketch.exp.svg @@ -0,0 +1,95 @@ +hello there cat + + + \ No newline at end of file