Skip to content

Commit

Permalink
pass linting
Browse files Browse the repository at this point in the history
  • Loading branch information
Nathaniel Saul committed Jan 17, 2019
1 parent f8596d9 commit d8dda75
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"lint:test": "node_modules/eslint/bin/eslint.js --config=.eslintrc.test.config.js \"test/**/*.spec.js\"",
"lint": "npm run lint:src && npm run lint:test && npm run docs:lint",
"precommit": "lint-staged",
"prepare": "npm run dist:transpile",
"prepare": "npm run dist:rd3g && npm run dist:transpile",
"start": "http-server ./sandbox/ -p 8888 -c-1",
"test:clean": "jest --no-cache --updateSnapshot --verbose --coverage --config jest.config.js",
"test:watch": "jest --verbose --coverage --watchAll --config jest.config.js",
Expand Down
4 changes: 4 additions & 0 deletions src/components/graph/graph.builder.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,21 +139,25 @@ function buildNodeProps(node, config, nodeCallbacks = {}, highlightedNode, highl
const opacity = _getNodeOpacity(node, highlightedNode, highlightedLink, config);

let fill = node.color || config.node.color;

if (highlight && config.node.highlightColor !== CONST.KEYWORDS.SAME) {
fill = config.node.highlightColor;
}

let stroke = node.strokeColor || config.node.strokeColor;

if (highlight && config.node.highlightStrokeColor !== CONST.KEYWORDS.SAME) {
stroke = config.node.highlightStrokeColor;
}

let label = node[config.node.labelProperty] || node.id;

if (typeof config.node.labelProperty === "function") {
label = config.node.labelProperty(node);
}

let strokeWidth = node.strokeWidth || config.node.strokeWidth;

if (highlight && config.node.highlightStrokeWidth !== CONST.KEYWORDS.SAME) {
strokeWidth = config.node.highlightStrokeWidth;
}
Expand Down

0 comments on commit d8dda75

Please sign in to comment.