3d-force-graph 1.70.7 → 1.70.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -16
- package/dist/3d-force-graph.js +1 -1
- package/dist/3d-force-graph.min.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
[![NPM package][npm-img]][npm-url]
|
|
5
5
|
[![Build Size][build-size-img]][build-size-url]
|
|
6
|
-
[![
|
|
6
|
+
[![NPM Downloads][npm-downloads-img]][npm-downloads-url]
|
|
7
7
|
|
|
8
8
|
<p align="center">
|
|
9
9
|
<a href="https://vasturiano.github.io/3d-force-graph/example/large-graph/"><img width="80%" src="http://gist.github.com/vasturiano/02affe306ce445e423f992faeea13521/raw/preview.png"></a>
|
|
@@ -51,28 +51,28 @@ And check out the [React bindings](https://github.com/vasturiano/react-force-gra
|
|
|
51
51
|
|
|
52
52
|
## Quick start
|
|
53
53
|
|
|
54
|
-
```
|
|
54
|
+
```js
|
|
55
55
|
import ForceGraph3D from '3d-force-graph';
|
|
56
56
|
```
|
|
57
57
|
or
|
|
58
|
-
```
|
|
59
|
-
|
|
58
|
+
```js
|
|
59
|
+
const ForceGraph3D = require('3d-force-graph');
|
|
60
60
|
```
|
|
61
61
|
or even
|
|
62
|
-
```
|
|
62
|
+
```html
|
|
63
63
|
<script src="//unpkg.com/3d-force-graph"></script>
|
|
64
64
|
```
|
|
65
65
|
then
|
|
66
|
-
```
|
|
67
|
-
|
|
66
|
+
```js
|
|
67
|
+
const myGraph = ForceGraph3D();
|
|
68
68
|
myGraph(<myDOMElement>)
|
|
69
|
-
|
|
69
|
+
.graphData(<myData>);
|
|
70
70
|
```
|
|
71
71
|
|
|
72
72
|
## API reference
|
|
73
73
|
|
|
74
74
|
### Initialisation
|
|
75
|
-
```
|
|
75
|
+
```js
|
|
76
76
|
ForceGraph3d({ configOptions })(<domElement>)
|
|
77
77
|
```
|
|
78
78
|
|
|
@@ -209,7 +209,7 @@ ForceGraph3d({ configOptions })(<domElement>)
|
|
|
209
209
|
| <b>screen2GraphCoords</b>(<i>x</i>, <i>y</i>, <i>distance</i>) | Utility method to translate viewport distance coordinates to the graph domain. Given a pair of `x`,`y` screen coordinates and distance from the camera, returns the current equivalent `{x, y, z}` in the domain of graph node coordinates. |
|
|
210
210
|
|
|
211
211
|
### Input JSON syntax
|
|
212
|
-
```
|
|
212
|
+
```json
|
|
213
213
|
{
|
|
214
214
|
"nodes": [
|
|
215
215
|
{
|
|
@@ -222,14 +222,14 @@ ForceGraph3d({ configOptions })(<domElement>)
|
|
|
222
222
|
"name": "name2",
|
|
223
223
|
"val": 10
|
|
224
224
|
},
|
|
225
|
-
|
|
225
|
+
...
|
|
226
226
|
],
|
|
227
227
|
"links": [
|
|
228
228
|
{
|
|
229
229
|
"source": "id1",
|
|
230
230
|
"target": "id2"
|
|
231
231
|
},
|
|
232
|
-
|
|
232
|
+
...
|
|
233
233
|
]
|
|
234
234
|
}
|
|
235
235
|
```
|
|
@@ -238,9 +238,9 @@ ForceGraph3d({ configOptions })(<domElement>)
|
|
|
238
238
|
|
|
239
239
|
[](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=L398E7PKP47E8¤cy_code=USD&source=url) If this project has helped you and you'd like to contribute back, you can always [buy me a ☕](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=L398E7PKP47E8¤cy_code=USD&source=url)!
|
|
240
240
|
|
|
241
|
-
[npm-img]: https://img.shields.io/npm/v/3d-force-graph
|
|
241
|
+
[npm-img]: https://img.shields.io/npm/v/3d-force-graph
|
|
242
242
|
[npm-url]: https://npmjs.org/package/3d-force-graph
|
|
243
|
-
[build-size-img]: https://img.shields.io/bundlephobia/minzip/3d-force-graph
|
|
243
|
+
[build-size-img]: https://img.shields.io/bundlephobia/minzip/3d-force-graph
|
|
244
244
|
[build-size-url]: https://bundlephobia.com/result?p=3d-force-graph
|
|
245
|
-
[
|
|
246
|
-
[
|
|
245
|
+
[npm-downloads-img]: https://img.shields.io/npm/dt/3d-force-graph
|
|
246
|
+
[npm-downloads-url]: https://www.npmtrends.com/3d-force-graph
|
package/dist/3d-force-graph.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// Version 1.70.
|
|
1
|
+
// Version 1.70.8 3d-force-graph - https://github.com/vasturiano/3d-force-graph
|
|
2
2
|
(function (global, factory) {
|
|
3
3
|
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
|
|
4
4
|
typeof define === 'function' && define.amd ? define(factory) :
|