@truedat/dd 4.35.0 → 4.35.1
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/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@truedat/dd",
|
|
3
|
-
"version": "4.35.
|
|
3
|
+
"version": "4.35.1",
|
|
4
4
|
"description": "Truedat Web Data Dictionary",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"jsnext:main": "src/index.js",
|
|
@@ -107,5 +107,5 @@
|
|
|
107
107
|
"react-dom": ">= 16.8.6 < 17",
|
|
108
108
|
"semantic-ui-react": ">= 0.88.2 < 2.1"
|
|
109
109
|
},
|
|
110
|
-
"gitHead": "
|
|
110
|
+
"gitHead": "2619cb0ebdd315247a3a842819aa2463cc4b3ca4"
|
|
111
111
|
}
|
|
@@ -2,12 +2,11 @@ import _ from "lodash/fp";
|
|
|
2
2
|
import React, { useEffect } from "react";
|
|
3
3
|
import PropTypes from "prop-types";
|
|
4
4
|
import { connect } from "react-redux";
|
|
5
|
-
import {
|
|
6
|
-
import GraphRedirector from "./GraphRedirector";
|
|
5
|
+
import { createGraph, fetchStructureGraph } from "../routines";
|
|
7
6
|
import LineageGraph from "./LineageGraph";
|
|
8
7
|
|
|
9
8
|
export const StructureGraph = ({
|
|
10
|
-
|
|
9
|
+
createGraph,
|
|
11
10
|
degree,
|
|
12
11
|
fetchStructureGraph,
|
|
13
12
|
graph,
|
|
@@ -16,23 +15,16 @@ export const StructureGraph = ({
|
|
|
16
15
|
type,
|
|
17
16
|
}) => {
|
|
18
17
|
useEffect(() => {
|
|
19
|
-
degree &&
|
|
20
|
-
_.isEmpty(graph) &&
|
|
21
|
-
createStructureGraph({ ids: [id], type: type });
|
|
18
|
+
degree && _.isEmpty(graph) && createGraph({ ids: [id], type: type });
|
|
22
19
|
}, [type]);
|
|
23
20
|
useEffect(() => {
|
|
24
21
|
graphId && _.isEmpty(graph) && fetchStructureGraph({ id: graphId });
|
|
25
22
|
}, [graphId]);
|
|
26
|
-
return degree ?
|
|
27
|
-
<>
|
|
28
|
-
<GraphRedirector />
|
|
29
|
-
<LineageGraph height="50vh" graph={graph} />
|
|
30
|
-
</>
|
|
31
|
-
) : null;
|
|
23
|
+
return degree ? <LineageGraph height="50vh" graph={graph} /> : null;
|
|
32
24
|
};
|
|
33
25
|
|
|
34
26
|
StructureGraph.propTypes = {
|
|
35
|
-
|
|
27
|
+
createGraph: PropTypes.func,
|
|
36
28
|
fetchStructureGraph: PropTypes.func,
|
|
37
29
|
degree: PropTypes.object,
|
|
38
30
|
graph: PropTypes.object,
|
|
@@ -47,6 +39,6 @@ const mapStateToProps = ({ structure }) => ({
|
|
|
47
39
|
});
|
|
48
40
|
|
|
49
41
|
export default connect(mapStateToProps, {
|
|
50
|
-
|
|
42
|
+
createGraph,
|
|
51
43
|
fetchStructureGraph,
|
|
52
44
|
})(StructureGraph);
|