From 9f4650b012b651a4d462171ab29ad1a2f559a8cb Mon Sep 17 00:00:00 2001 From: Bram Kragten Date: Tue, 6 Apr 2021 18:39:05 +0200 Subject: [PATCH] Update hat-graph-node.ts --- src/components/trace/hat-graph-node.ts | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/components/trace/hat-graph-node.ts b/src/components/trace/hat-graph-node.ts index c9d6b8296f..9e92c5b559 100644 --- a/src/components/trace/hat-graph-node.ts +++ b/src/components/trace/hat-graph-node.ts @@ -29,8 +29,8 @@ export class HatGraphNode extends LitElement { } if (this.spacer) { svgEl.setAttribute("width", "10px"); - svgEl.setAttribute("height", "41px"); - svgEl.setAttribute("viewBox", "-5 -40 10 26"); + svgEl.setAttribute("height", `${SPACING + NODE_SIZE + 1}px`); + svgEl.setAttribute("viewBox", `-5 0 10 ${SPACING + NODE_SIZE + 1}`); return; } const bbox = svgEl.getBBox(); @@ -59,9 +59,7 @@ export class HatGraphNode extends LitElement { class="connector" d=" M 0 ${ - this.spacer - ? -SPACING * 2 - NODE_SIZE - : -SPACING - NODE_SIZE / 2 + this.spacer ? SPACING + NODE_SIZE + 1 : -SPACING - NODE_SIZE / 2 } L 0 0 "