Merge pull request #1693 from weaveworks/1688-reduce-horizontal-gaps

reduce horizontal gap between nodes in topology views

Fixes #1688
This commit is contained in:
Matthias Radestock
2016-07-20 10:21:17 +01:00
committed by GitHub
2 changed files with 2 additions and 2 deletions

View File

@@ -85,7 +85,7 @@ class Node extends React.Component {
const color = getNodeColor(rank, label, pseudo);
const truncate = !focused && !hovered;
const labelTransform = focused ? `scale(${1 / zoomScale})` : '';
const labelWidth = nodeScale(scaleFactor * 4);
const labelWidth = nodeScale(scaleFactor * 3);
const labelOffsetX = -labelWidth / 2;
const labelDy = (showingNetworks && networks) ? 0.75 : 0.60;
const labelOffsetY = focused ? nodeScale(labelDy) : nodeScale(labelDy * scaleFactor);

View File

@@ -12,7 +12,7 @@ const DEFAULT_WIDTH = 800;
const DEFAULT_MARGINS = {top: 0, left: 0};
const DEFAULT_SCALE = val => val * 2;
const NODE_SIZE_FACTOR = 1;
const NODE_SEPARATION_FACTOR = 3.0;
const NODE_SEPARATION_FACTOR = 2.0;
const RANK_SEPARATION_FACTOR = 3.0;
let layoutRuns = 0;
let layoutRunsTrivial = 0;