@receptron/graphai_vue_cytoscape 0.0.16 → 0.0.17
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/lib/cytoscape.js +4 -3
- package/package.json +2 -10
package/lib/cytoscape.js
CHANGED
|
@@ -283,9 +283,10 @@ var useCytoscape = function (selectedGraph) {
|
|
|
283
283
|
_d.label = 2;
|
|
284
284
|
case 2:
|
|
285
285
|
elements = cytoscapeData.value.elements;
|
|
286
|
+
if (!elements.map[nodeId]) return [3 /*break*/, 4];
|
|
286
287
|
elements.map[nodeId].data.color = colorMap[state];
|
|
287
288
|
graph = selectedGraph.value;
|
|
288
|
-
nodeData = (_b = ((_a = graph === null || graph === void 0 ? void 0 : graph.nodes) !== null && _a !== void 0 ? _a : {})[nodeId]) !== null && _b !== void 0 ? _b :
|
|
289
|
+
nodeData = (_b = ((_a = graph === null || graph === void 0 ? void 0 : graph.nodes) !== null && _a !== void 0 ? _a : {})[nodeId]) !== null && _b !== void 0 ? _b : {};
|
|
289
290
|
if ("agent" in nodeData && state === graphai_1.NodeState.Queued && ((_c = nodeData.priority) !== null && _c !== void 0 ? _c : 0) > 0) {
|
|
290
291
|
// computed node
|
|
291
292
|
elements.map[nodeId].data.color = colorPriority;
|
|
@@ -344,7 +345,7 @@ var useCytoscape = function (selectedGraph) {
|
|
|
344
345
|
}
|
|
345
346
|
return prevName;
|
|
346
347
|
}, layout);
|
|
347
|
-
console.log("layout",
|
|
348
|
+
// console.log("layout", name);
|
|
348
349
|
cy.layout({ name: name_1 }).run();
|
|
349
350
|
cy.fit();
|
|
350
351
|
if (!(name_1 === layout)) return [3 /*break*/, 2];
|
|
@@ -358,7 +359,7 @@ var useCytoscape = function (selectedGraph) {
|
|
|
358
359
|
});
|
|
359
360
|
}); };
|
|
360
361
|
var storePositions = function () {
|
|
361
|
-
console.log("storePositions");
|
|
362
|
+
// console.log("storePositions");
|
|
362
363
|
if (cy) {
|
|
363
364
|
cy.nodes().forEach(function (cynode) {
|
|
364
365
|
var id = cynode.id();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@receptron/graphai_vue_cytoscape",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.17",
|
|
4
4
|
"main": "lib/cytoscape.js",
|
|
5
5
|
"files": [
|
|
6
6
|
"./lib"
|
|
@@ -30,19 +30,11 @@
|
|
|
30
30
|
"cytoscape-klay": "^3.1.4"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@babel/types": "^7.26.3",
|
|
34
|
-
"@rushstack/eslint-patch": "^1.8.0",
|
|
35
|
-
"@tsconfig/node20": "^20.1.4",
|
|
36
33
|
"@types/cytoscape-klay": "^3.1.4",
|
|
37
34
|
"@vitejs/plugin-vue": "^5.2.1",
|
|
38
35
|
"@vue/tsconfig": "^0.7.0",
|
|
39
|
-
"autoprefixer": "^10.4.19",
|
|
40
|
-
"npm-run-all2": "^7.0.1",
|
|
41
|
-
"postcss": "^8.4.49",
|
|
42
|
-
"tailwindcss": "^3.4.16",
|
|
43
|
-
"vite": "^6.0.3",
|
|
44
36
|
"vue": "^3.5.13",
|
|
45
|
-
"vue-tsc": "^2.
|
|
37
|
+
"vue-tsc": "^2.2.0"
|
|
46
38
|
},
|
|
47
39
|
"types": "./lib/cytoscape.d.ts",
|
|
48
40
|
"directories": {
|