Adds node.networks to the debug toolbar nodes

This commit is contained in:
Simon Howe
2016-05-19 09:59:44 +01:00
parent 25685c55f9
commit da67ba05f8
4 changed files with 8 additions and 4 deletions

View File

@@ -30,12 +30,14 @@ function getPoints(h) {
}
export default function NodeShapeHex({id, highlighted, size, color, metric}) {
export default function NodeShapeHex({id, highlighted, size, color, metric, networks}) {
const pathProps = v => ({
d: getPoints(size * v * 2),
transform: `rotate(90) translate(-${size * getWidth(v)}, -${size * v})`
});
console.log('netz', networks);
const shadowSize = 0.45;
const upperHexBitHeight = -0.25 * size * shadowSize;

View File

@@ -63,6 +63,7 @@ class NodesChartNodes extends React.Component {
matches={searchNodeMatches.get(node.get('id'))}
highlighted={node.get('highlighted')}
shape={node.get('shape')}
networks={node.get('networks')}
stack={node.get('stack')}
key={node.get('id')}
id={node.get('id')}

View File

@@ -178,7 +178,8 @@ class NodesChart extends React.Component {
metrics: node.get('metrics'),
rank: node.get('rank'),
shape: node.get('shape'),
stack: node.get('stack')
stack: node.get('stack'),
networks: node.get('networknetworks'),
}));
});

View File

@@ -51,9 +51,9 @@ const deltaAdd = (name, adjacency = [], shape = 'circle', stack = false, nodeCou
label: name,
label_minor: name,
latest: {},
metadata: {},
origins: [],
rank: name
rank: name,
networks: ['fe', 'be'],
});