Skip to content

Commit d27d62f

Browse files
committed
Release 1.2.1
1 parent ef2b507 commit d27d62f

File tree

11 files changed

+4929
-41
lines changed

11 files changed

+4929
-41
lines changed

README.md

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# react-d3-graph · [![Build Status](https://travis-ci.org/danielcaldas/react-d3-graph.svg?branch=master&style=flat-square)](https://travis-ci.org/danielcaldas/react-d3-graph)
22

3-
[![npm version](https://img.shields.io/badge/npm-v1.2.0-blue.svg?longCache=true&style=flat-square)](https://www.npmjs.com/package/react-d3-graph) [![npm stats](https://img.shields.io/badge/downloads-3k-brightgreen.svg?longCache=true&style=flat-square)](https://npm-stat.com/charts.html?package=react-d3-graph&from=2017-04-25) [![probot enabled](https://img.shields.io/badge/probot:stale-enabled-yellow.svg?longCache=true&style=flat-square)](https://probot.github.io/) [![trello](https://img.shields.io/badge/trello-board-blue.svg?longCache=true&style=flat-square)](https://trello.com/b/KrnmFXha/react-d3-graph)
3+
[![npm version](https://img.shields.io/badge/npm-v1.2.1-blue.svg?longCache=true&style=flat-square)](https://www.npmjs.com/package/react-d3-graph) [![npm stats](https://img.shields.io/badge/downloads-3k-brightgreen.svg?longCache=true&style=flat-square)](https://npm-stat.com/charts.html?package=react-d3-graph&from=2017-04-25) [![probot enabled](https://img.shields.io/badge/probot:stale-enabled-yellow.svg?longCache=true&style=flat-square)](https://probot.github.io/) [![trello](https://img.shields.io/badge/trello-board-blue.svg?longCache=true&style=flat-square)](https://trello.com/b/KrnmFXha/react-d3-graph)
44
[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)
55

6-
:book: [1.2.0](https://danielcaldas.github.io/react-d3-graph/docs/index.html)
6+
:book: [1.2.1](https://danielcaldas.github.io/react-d3-graph/docs/index.html)
77

88
### _Interactive and configurable graphs with react and d3 effortlessly_
99

@@ -36,59 +36,59 @@ import { Graph } from 'react-d3-graph';
3636

3737
// graph payload (with minimalist structure)
3838
const data = {
39-
nodes: [{ id: 'Harry' }, { id: 'Sally' }, { id: 'Alice' }],
40-
links: [{ source: 'Harry', target: 'Sally' }, { source: 'Harry', target: 'Alice' }]
39+
nodes: [{ id: 'Harry' }, { id: 'Sally' }, { id: 'Alice' }],
40+
links: [{ source: 'Harry', target: 'Sally' }, { source: 'Harry', target: 'Alice' }]
4141
};
4242

4343
// the graph configuration, you only need to pass down properties
4444
// that you want to override, otherwise default ones will be used
4545
const myConfig = {
46-
nodeHighlightBehavior: true,
47-
node: {
48-
color: 'lightgreen',
49-
size: 120,
50-
highlightStrokeColor: 'blue'
51-
},
52-
link: {
53-
highlightColor: 'lightblue'
54-
}
46+
nodeHighlightBehavior: true,
47+
node: {
48+
color: 'lightgreen',
49+
size: 120,
50+
highlightStrokeColor: 'blue'
51+
},
52+
link: {
53+
highlightColor: 'lightblue'
54+
}
5555
};
5656

5757
// graph event callbacks
5858
const onClickNode = function(nodeId) {
59-
window.alert('Clicked node ${nodeId}');
59+
window.alert('Clicked node ${nodeId}');
6060
};
6161

6262
const onMouseOverNode = function(nodeId) {
63-
window.alert(`Mouse over node ${nodeId}`);
63+
window.alert(`Mouse over node ${nodeId}`);
6464
};
6565

6666
const onMouseOutNode = function(nodeId) {
67-
window.alert(`Mouse out node ${nodeId}`);
67+
window.alert(`Mouse out node ${nodeId}`);
6868
};
6969

7070
const onClickLink = function(source, target) {
71-
window.alert(`Clicked link between ${source} and ${target}`);
71+
window.alert(`Clicked link between ${source} and ${target}`);
7272
};
7373

7474
const onMouseOverLink = function(source, target) {
75-
window.alert(`Mouse over in link between ${source} and ${target}`);
75+
window.alert(`Mouse over in link between ${source} and ${target}`);
7676
};
7777

7878
const onMouseOutLink = function(source, target) {
79-
window.alert(`Mouse out link between ${source} and ${target}`);
79+
window.alert(`Mouse out link between ${source} and ${target}`);
8080
};
8181

8282
<Graph
83-
id="graph-id" // id is mandatory, if no id is defined rd3g will throw an error
84-
data={data}
85-
config={myConfig}
86-
onClickNode={onClickNode}
87-
onClickLink={onClickLink}
88-
onMouseOverNode={onMouseOverNode}
89-
onMouseOutNode={onMouseOutNode}
90-
onMouseOverLink={onMouseOverLink}
91-
onMouseOutLink={onMouseOutLink}
83+
id="graph-id" // id is mandatory, if no id is defined rd3g will throw an error
84+
data={data}
85+
config={myConfig}
86+
onClickNode={onClickNode}
87+
onClickLink={onClickLink}
88+
onMouseOverNode={onMouseOverNode}
89+
onMouseOutNode={onMouseOutNode}
90+
onMouseOverLink={onMouseOverLink}
91+
onMouseOutLink={onMouseOutLink}
9292
/>;
9393
```
9494

docs/0.3.0.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ <h4><a href="https://github.com/danielcaldas/react-d3-graph" target="_blank">
2121
<h4><a href="https://danielcaldas.github.io/react-d3-graph/sandbox/index.html" target="_blank">🔗 Live Demo</a></h4>
2222
<h5>Versions</h5>
2323
<ul>
24-
<li><a href="./index.html">1.2.0 (latest) 🚀</a></li>
24+
<li><a href="./index.html">1.2.1 (latest) 🚀</a></li>
25+
<li><a href="./1.2.0.html">1.2.0</a></li>
2526
<li><a href="./1.0.1.html">1.0.1</a></li>
2627
<li><a href="./1.0.0.html">1.0.0</a></li>
2728
<li><a href="./0.4.0.html">0.4.0</a></li>

docs/0.4.0.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ <h4><a href="https://github.com/danielcaldas/react-d3-graph" target="_blank">
2121
<h4><a href="https://danielcaldas.github.io/react-d3-graph/sandbox/index.html" target="_blank">🔗 Live Demo</a></h4>
2222
<h5>Versions</h5>
2323
<ul>
24-
<li><a href="./index.html">1.2.0 (latest) 🚀</a></li>
24+
<li><a href="./index.html">1.2.1 (latest) 🚀</a></li>
25+
<li><a href="./1.2.0.html">1.2.0</a></li>
2526
<li><a href="./1.0.1.html">1.0.1</a></li>
2627
<li><a href="./1.0.0.html">1.0.0</a></li>
2728
<li><a href="./0.4.0.html">0.4.0</a></li>

docs/1.0.0.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ <h4><a href="https://github.com/danielcaldas/react-d3-graph" target="_blank">
2121
<h4><a href="https://danielcaldas.github.io/react-d3-graph/sandbox/index.html" target="_blank">🔗 Live Demo</a></h4>
2222
<h5>Versions</h5>
2323
<ul>
24-
<li><a href="./index.html">1.2.0 (latest) 🚀</a></li>
24+
<li><a href="./index.html">1.2.1 (latest) 🚀</a></li>
25+
<li><a href="./1.2.0.html">1.2.0</a></li>
2526
<li><a href="./1.0.1.html">1.0.1</a></li>
2627
<li><a href="./1.0.0.html">1.0.0</a></li>
2728
<li><a href="./0.4.0.html">0.4.0</a></li>

docs/1.0.1.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ <h4><a href="https://github.com/danielcaldas/react-d3-graph" target="_blank">
2121
<h4><a href="https://danielcaldas.github.io/react-d3-graph/sandbox/index.html" target="_blank">🔗 Live Demo</a></h4>
2222
<h5>Versions</h5>
2323
<ul>
24-
<li><a href="./index.html">1.2.0 (latest) 🚀</a></li>
24+
<li><a href="./index.html">1.2.1 (latest) 🚀</a></li>
25+
<li><a href="./1.2.0.html">1.2.0</a></li>
2526
<li><a href="./1.0.1.html">1.0.1</a></li>
2627
<li><a href="./1.0.0.html">1.0.0</a></li>
2728
<li><a href="./0.4.0.html">0.4.0</a></li>

0 commit comments

Comments
 (0)