diff --git a/package.json b/package.json index e4ab24b..0406e79 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "case-law-app-js", - "version": "0.2.1", + "version": "0.3.0", "private": true, "homepage": "https://nlesc.github.io/case-law-app", "devDependencies": { diff --git a/src/App.js b/src/App.js index 77d8fa9..2a08c8f 100644 --- a/src/App.js +++ b/src/App.js @@ -28,7 +28,7 @@ class App extends React.Component { activeNode: {}, filterState: { sizeAttributeValue: "degree", - colorAttributeValue: "community", + colorAttributeValue: "none", adjustLayout: false, filterSelected: false }, @@ -91,7 +91,7 @@ class App extends React.Component { filterState.creatorValue = filterState.creatorValue || "all"; filterState.communityValue = filterState.communityValue || "all"; filterState.sizeAttributeValue = filterState.sizeAttributeValue || "degree"; - filterState.colorAttributeValue = filterState.colorAttributeValue || "creator"; + filterState.colorAttributeValue = filterState.colorAttributeValue || "none"; return { filterState: filterState }; @@ -144,7 +144,7 @@ class App extends React.Component { } = this.state; const title = data.title || "Network"; const version = require('./../package.json').version; - const version_url = "https://github.com/NLeSC/case-law-app/releases/tag/v" + version; + const version_url = "https://github.com/NLeSC/case-law-app/releases"; return (
@@ -152,8 +152,8 @@ class App extends React.Component {

Case Law Analytics - {title}

-

Version {version}

-

Source code

+

Version {version}

+

Source code

diff --git a/src/components/ColorOnAttribute.js b/src/components/ColorOnAttribute.js index 1e04ad5..61025bf 100644 --- a/src/components/ColorOnAttribute.js +++ b/src/components/ColorOnAttribute.js @@ -30,7 +30,17 @@ class ColorOnAttribute extends React.Component { const s = props.sigma; const att = props.attribute; const nodes = s.graph.nodes(); - if (nodes.length > 0) { + if (att === 'none') { + nodes.forEach(node => { + node.color_selected = 'green'; + node.color_unselected = 'black'; + if (node.selected) { + node.color = node.color_selected; + } else { + node.color = node.color_unselected; + } + }); + } else if (nodes.length > 0) { if (typeof nodes[0][att] === 'string') { this.updateColorCategorical(nodes, att); } else { diff --git a/src/components/FilterPane.js b/src/components/FilterPane.js index 40e5256..61ad768 100644 --- a/src/components/FilterPane.js +++ b/src/components/FilterPane.js @@ -204,6 +204,7 @@ class FilterPane extends Component {

Node Color