@neo4j-nvl/react 0.2.40 → 0.2.42
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.
|
@@ -153,18 +153,30 @@ export const BasicNvlWrapper = memo(forwardRef((_a, ref) => {
|
|
|
153
153
|
}, [nodes, rels]);
|
|
154
154
|
useEffect(() => {
|
|
155
155
|
var _a;
|
|
156
|
+
if (nvlRef.current === null || layout === undefined) {
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
156
159
|
(_a = nvlRef.current) === null || _a === void 0 ? void 0 : _a.setLayout(layout);
|
|
157
160
|
}, [layout]);
|
|
158
161
|
useDeepCompareEffect(() => {
|
|
159
162
|
var _a;
|
|
163
|
+
if (nvlRef.current === null || layoutOptions === undefined) {
|
|
164
|
+
return;
|
|
165
|
+
}
|
|
160
166
|
(_a = nvlRef.current) === null || _a === void 0 ? void 0 : _a.setLayoutOptions(layoutOptions);
|
|
161
167
|
}, [layoutOptions]);
|
|
162
168
|
useEffect(() => {
|
|
163
169
|
var _a;
|
|
170
|
+
if (nvlRef.current === null || nvlOptions.useWebGL === undefined) {
|
|
171
|
+
return;
|
|
172
|
+
}
|
|
164
173
|
(_a = nvlRef.current) === null || _a === void 0 ? void 0 : _a.setUseWebGLRenderer(nvlOptions.useWebGL);
|
|
165
174
|
}, [nvlOptions.useWebGL]);
|
|
166
175
|
useEffect(() => {
|
|
167
176
|
var _a;
|
|
177
|
+
if (nvlRef.current === null || nvlOptions.disableWebGL === undefined) {
|
|
178
|
+
return;
|
|
179
|
+
}
|
|
168
180
|
(_a = nvlRef.current) === null || _a === void 0 ? void 0 : _a.setDisableWebGL(nvlOptions.disableWebGL);
|
|
169
181
|
}, [nvlOptions.disableWebGL]);
|
|
170
182
|
return React.createElement("div", Object.assign({ ref: containerRef, style: { height: '100%', outline: '0' } }, nvlEvents));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Node, Relationship } from '@neo4j-nvl/core';
|
|
2
|
-
declare const getMapDifferences: <T extends
|
|
2
|
+
declare const getMapDifferences: <T extends Node | Relationship>(prevGraphElements: T[], newGraphElements: T[]) => {
|
|
3
3
|
added: T[];
|
|
4
4
|
removed: T[];
|
|
5
5
|
updated: T[];
|