diff --git a/d2layouts/d2sequence/constants.go b/d2layouts/d2sequence/constants.go index 62a8132ec..12d591f3e 100644 --- a/d2layouts/d2sequence/constants.go +++ b/d2layouts/d2sequence/constants.go @@ -19,3 +19,7 @@ const SPAN_DEPTH_GROWTH_FACTOR = 8. // when a span has a single messages const MIN_SPAN_HEIGHT = 80. + +const LIFELINE_STROKE_WIDTH int = 2 + +const LIFELINE_STROKE_DASH int = 8 diff --git a/d2layouts/d2sequence/sequence_diagram.go b/d2layouts/d2sequence/sequence_diagram.go index 9a20692e0..d49f657c9 100644 --- a/d2layouts/d2sequence/sequence_diagram.go +++ b/d2layouts/d2sequence/sequence_diagram.go @@ -134,9 +134,8 @@ func (sd *sequenceDiagram) addLifelineEdges() { sd.lifelines = append(sd.lifelines, &d2graph.Edge{ Attributes: d2graph.Attributes{ Style: d2graph.Style{ - StrokeDash: &d2graph.Scalar{Value: "10"}, - Stroke: actor.Attributes.Style.Stroke, - StrokeWidth: actor.Attributes.Style.StrokeWidth, + StrokeDash: &d2graph.Scalar{Value: fmt.Sprintf("%d", LIFELINE_STROKE_DASH)}, + StrokeWidth: &d2graph.Scalar{Value: fmt.Sprintf("%d", LIFELINE_STROKE_WIDTH)}, }, }, Src: actor,