react-kggraph 0.0.26 → 0.0.27
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/index.es16.js +2 -2
- package/lib/index.es3.js +131 -124
- package/lib/index.es35.js +2 -2
- package/lib/index.es36.js +4 -0
- package/lib/index.es38.js +62 -1045
- package/lib/index.es39.js +1046 -18
- package/lib/index.es40.js +18 -40
- package/lib/index.es41.js +41 -40
- package/lib/index.es42.js +38 -87
- package/lib/index.es43.js +86 -53
- package/lib/index.es44.js +53 -28
- package/lib/index.es45.js +33 -0
- package/lib/index.es7.js +248 -244
- package/lib/index.es8.js +58 -57
- package/lib/style.css +1 -1
- package/package.json +1 -1
- package/lib/index.es37.js +0 -66
- /package/lib/{index.es49.js → index.es50.js} +0 -0
package/lib/index.es16.js
CHANGED
|
@@ -2,8 +2,8 @@ import { jsx as a } from "react/jsx-runtime";
|
|
|
2
2
|
import { forwardRef as u, useContext as g, useState as e, useRef as C, useEffect as w, useImperativeHandle as h } from "react";
|
|
3
3
|
import { Drawer as D } from "antd";
|
|
4
4
|
import { GraphContext as x } from "./index.es15.js";
|
|
5
|
-
import y from "./index.
|
|
6
|
-
import { cardDara as I } from "./index.
|
|
5
|
+
import y from "./index.es38.js";
|
|
6
|
+
import { cardDara as I } from "./index.es39.js";
|
|
7
7
|
const K = u((v, l) => {
|
|
8
8
|
const { graphInfo: f, knowledgeCardApi: R } = g(x), [t, o] = e(!1), [d, s] = e(!1), [c, i] = e(!1), [k, p] = e({ style: {}, data: {} }), r = C(null);
|
|
9
9
|
w(() => {
|
package/lib/index.es3.js
CHANGED
|
@@ -1,78 +1,78 @@
|
|
|
1
1
|
import { jsx as h, jsxs as oe } from "react/jsx-runtime";
|
|
2
|
-
import { useRef as
|
|
3
|
-
import
|
|
4
|
-
import
|
|
2
|
+
import { useRef as k, useState as v, useEffect as S } from "react";
|
|
3
|
+
import E from "cytoscape";
|
|
4
|
+
import Ee from "cytoscape-cose-bilkent";
|
|
5
5
|
import ze from "cytoscape-cise";
|
|
6
|
-
import
|
|
7
|
-
import
|
|
6
|
+
import we from "cytoscape-fcose";
|
|
7
|
+
import je from "storm-layout";
|
|
8
8
|
import Le from "./index.es7.js";
|
|
9
9
|
/* empty css */
|
|
10
|
-
import { handleCalcPath as
|
|
11
|
-
import { fixNodesToEdges as
|
|
10
|
+
import { handleCalcPath as Oe, resDetailData as F } from "./index.es8.js";
|
|
11
|
+
import { fixNodesToEdges as Re, coseBilkentLayout as ne } from "./index.es9.js";
|
|
12
12
|
import { edgeNodeStyles as Te, defaultColors as se, nodeSize as $e } from "./index.es10.js";
|
|
13
13
|
import De from "cytoscape-layout-utilities";
|
|
14
|
-
import { message as
|
|
14
|
+
import { message as C } from "antd";
|
|
15
15
|
import { menuItemsConfig as Se } from "./index.es11.js";
|
|
16
|
-
import { jsonStringify as
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import { GraphProvider as
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
const
|
|
16
|
+
import { jsonStringify as L } from "./index.es12.js";
|
|
17
|
+
import Ie from "./index.es13.js";
|
|
18
|
+
import Pe from "./index.es14.js";
|
|
19
|
+
import { GraphProvider as Be } from "./index.es15.js";
|
|
20
|
+
import We from "./index.es16.js";
|
|
21
|
+
import He from "./index.es17.js";
|
|
22
|
+
E.use(De);
|
|
23
|
+
E.use(ze);
|
|
24
|
+
E.use(we);
|
|
25
|
+
E.use(je);
|
|
26
|
+
E.use(Ee);
|
|
27
|
+
const lt = ({
|
|
28
28
|
data: de,
|
|
29
29
|
getAllGraphData: I,
|
|
30
30
|
highPathAnalysis: z = [],
|
|
31
31
|
graphInfo: g,
|
|
32
32
|
stepNextApi: re,
|
|
33
33
|
knowledgeCardApi: ae,
|
|
34
|
-
colors:
|
|
34
|
+
colors: w,
|
|
35
35
|
actionBar: ie,
|
|
36
36
|
actionCircle: le,
|
|
37
|
-
queryStatisticsConfig: ce = ["实体", "关系"],
|
|
37
|
+
queryStatisticsConfig: ce = [{ label: "实体", key: "entity" }, { label: "关系", key: "relation" }],
|
|
38
38
|
className: pe,
|
|
39
|
-
noDataDesc:
|
|
39
|
+
noDataDesc: Me = "暂无数据"
|
|
40
40
|
}) => {
|
|
41
|
-
var
|
|
42
|
-
const
|
|
43
|
-
|
|
44
|
-
H.current =
|
|
45
|
-
}, [
|
|
46
|
-
const [f,
|
|
41
|
+
var Y, G, ee;
|
|
42
|
+
const O = k(null), [p, P] = v([]), u = k(null), K = k(null), X = 1, [Ue, Z] = v(!1), [x, B] = v({}), [R, W] = v({}), [ue, ge] = v("cose-bilkent"), _ = k(null), J = k(null), [fe, Q] = v(["", ""]), H = k(w);
|
|
43
|
+
S(() => {
|
|
44
|
+
H.current = w;
|
|
45
|
+
}, [w]);
|
|
46
|
+
const [f, j] = v({
|
|
47
47
|
visible: !1,
|
|
48
48
|
x: 0,
|
|
49
49
|
y: 0,
|
|
50
50
|
targetNode: null,
|
|
51
51
|
bgColor: ""
|
|
52
|
-
}), [
|
|
52
|
+
}), [T, V] = v({
|
|
53
53
|
visible: !1,
|
|
54
54
|
x: 0,
|
|
55
55
|
y: 0,
|
|
56
56
|
content: ""
|
|
57
|
-
}), ye = Se({ cyRef: u, setContextMenu:
|
|
58
|
-
|
|
59
|
-
(z == null ? void 0 : z.length) > 1 &&
|
|
60
|
-
}, [
|
|
61
|
-
const
|
|
57
|
+
}), ye = Se({ cyRef: u, setContextMenu: j, onPathAnalysis: (Y = K.current) == null ? void 0 : Y.onPathAnalysis, setPathNodes: Q, actionCircle: le });
|
|
58
|
+
S(() => {
|
|
59
|
+
(z == null ? void 0 : z.length) > 1 && Oe(u, { pathNodes: z, isGrayed: !1 });
|
|
60
|
+
}, [L(z), L(p)]), S(() => {
|
|
61
|
+
const n = [], d = [];
|
|
62
62
|
p.forEach((l) => {
|
|
63
|
-
l.group === "nodes" ?
|
|
64
|
-
}), I == null || I({ graphData: p, nodeStatic:
|
|
65
|
-
}, [
|
|
63
|
+
l.group === "nodes" ? n.push(l.data) : l.group === "edges" && d.push(l.data);
|
|
64
|
+
}), I == null || I({ graphData: p, nodeStatic: x, relationStatic: R, data: { nodes: n, links: d } });
|
|
65
|
+
}, [L(p), L(x), L(R)]), S(() => {
|
|
66
66
|
var a;
|
|
67
|
-
if (!
|
|
68
|
-
const { elements:
|
|
69
|
-
B(
|
|
67
|
+
if (!O.current || u.current) return;
|
|
68
|
+
const { elements: n, typeListObj: d, relationListObj: l } = F(de, { typeObj: x, graphInfo: g });
|
|
69
|
+
B(d), P(n), W(l), document.addEventListener("contextmenu", function(t) {
|
|
70
70
|
t.preventDefault();
|
|
71
71
|
});
|
|
72
|
-
const e =
|
|
73
|
-
container:
|
|
74
|
-
elements:
|
|
75
|
-
style: Te({ elements:
|
|
72
|
+
const e = E({
|
|
73
|
+
container: O.current,
|
|
74
|
+
elements: n,
|
|
75
|
+
style: Te({ elements: n, colors: w }),
|
|
76
76
|
autounselectify: !1,
|
|
77
77
|
autolock: !1,
|
|
78
78
|
maxZoom: 1,
|
|
@@ -82,7 +82,7 @@ const it = ({
|
|
|
82
82
|
}
|
|
83
83
|
});
|
|
84
84
|
if (u.current = e, ((a = g == null ? void 0 : g.searchNodes) == null ? void 0 : a.length) === 2)
|
|
85
|
-
|
|
85
|
+
Re(
|
|
86
86
|
e,
|
|
87
87
|
g.searchNodes[0],
|
|
88
88
|
g.searchNodes[1]
|
|
@@ -94,24 +94,24 @@ const it = ({
|
|
|
94
94
|
});
|
|
95
95
|
}
|
|
96
96
|
return e.on("mouseover", "edge", (t) => {
|
|
97
|
-
var
|
|
97
|
+
var s;
|
|
98
98
|
const o = t.target;
|
|
99
99
|
if (!o.hasClass("path-edge")) {
|
|
100
|
-
const
|
|
100
|
+
const r = ((s = H.current) == null ? void 0 : s.edgeHoverColor) ?? se.edgeHoverColor;
|
|
101
101
|
o.style({
|
|
102
|
-
"line-color":
|
|
103
|
-
"target-arrow-color":
|
|
102
|
+
"line-color": r,
|
|
103
|
+
"target-arrow-color": r,
|
|
104
104
|
opacity: 0.8
|
|
105
105
|
});
|
|
106
106
|
}
|
|
107
107
|
}), e.on("mouseout", "edge", (t) => {
|
|
108
|
-
var
|
|
108
|
+
var s;
|
|
109
109
|
const o = t.target;
|
|
110
110
|
if (!o.hasClass("path-edge")) {
|
|
111
|
-
const
|
|
111
|
+
const r = ((s = H.current) == null ? void 0 : s.edgeDefaultColor) ?? se.edgeDefaultColor;
|
|
112
112
|
o.style({
|
|
113
|
-
"line-color":
|
|
114
|
-
"target-arrow-color":
|
|
113
|
+
"line-color": r,
|
|
114
|
+
"target-arrow-color": r,
|
|
115
115
|
opacity: 1
|
|
116
116
|
});
|
|
117
117
|
}
|
|
@@ -119,70 +119,70 @@ const it = ({
|
|
|
119
119
|
const o = t.target;
|
|
120
120
|
o.hasClass("selected") || o.addClass("hover");
|
|
121
121
|
}), e.on("mouseover", "node", (t) => {
|
|
122
|
-
const o = t.target,
|
|
123
|
-
o.addClass("hover"),
|
|
122
|
+
const o = t.target, s = o.renderedPosition(), r = o.data("name") || "";
|
|
123
|
+
o.addClass("hover"), V({
|
|
124
124
|
visible: !0,
|
|
125
|
-
x:
|
|
126
|
-
y:
|
|
127
|
-
content:
|
|
125
|
+
x: s.x,
|
|
126
|
+
y: s.y - 60,
|
|
127
|
+
content: r
|
|
128
128
|
});
|
|
129
129
|
}), e.on("mouseout", "node", (t) => {
|
|
130
|
-
t.target.removeClass("hover"),
|
|
130
|
+
t.target.removeClass("hover"), V((s) => ({ ...s, visible: !1 }));
|
|
131
131
|
}), e.on("cxttap", "node", (t) => {
|
|
132
132
|
t.preventDefault(), t.stopPropagation(), t.stopImmediatePropagation(), t.originalEvent && (t.originalEvent.preventDefault(), t.originalEvent.stopPropagation(), t.originalEvent.stopImmediatePropagation());
|
|
133
|
-
const o = t.target,
|
|
134
|
-
console.log("renderedPos:::", o.data(), o.style("background-color")),
|
|
133
|
+
const o = t.target, s = o.renderedPosition();
|
|
134
|
+
console.log("renderedPos:::", o.data(), o.style("background-color")), j({
|
|
135
135
|
visible: !0,
|
|
136
|
-
x:
|
|
137
|
-
y:
|
|
136
|
+
x: s.x - 90,
|
|
137
|
+
y: s.y - 90,
|
|
138
138
|
targetNode: o,
|
|
139
139
|
bgColor: o.style("background-color")
|
|
140
140
|
});
|
|
141
141
|
}), u.current = e, e.on("click", "node", (t) => {
|
|
142
142
|
const o = t.target;
|
|
143
143
|
e.nodes().removeClass("selected grayed highlighted"), e.edges().removeClass("selected grayed highlighted"), o.addClass("selected");
|
|
144
|
-
const
|
|
145
|
-
console.log("cy.nodes().not(relatedNodes):::",
|
|
144
|
+
const r = o.neighborhood().nodes().add(o), N = r.edgesWith(r);
|
|
145
|
+
console.log("cy.nodes().not(relatedNodes):::", r), e.nodes().not(r).addClass("grayed"), e.edges().not(N).addClass("grayed"), r.addClass("highlighted"), N.addClass("highlighted");
|
|
146
146
|
}), e.on("tap", (t) => {
|
|
147
|
-
t.target === e && (
|
|
147
|
+
t.target === e && (j((o) => ({ ...o, visible: !1 })), e.nodes().removeClass("grayed highlighted highlight selected correlationStyle path-node level-highlight level-selected level-grayed"), e.edges().removeClass("grayed highlighted highlight selected correlationStyle path-edge level-highlightedge level-grayed"));
|
|
148
148
|
}), () => {
|
|
149
149
|
u.current && (u.current.destroy(), u.current = null);
|
|
150
150
|
};
|
|
151
151
|
}, []);
|
|
152
|
-
const me = async (
|
|
153
|
-
const { id:
|
|
152
|
+
const me = async (n) => {
|
|
153
|
+
const { id: d, kgId: l } = n, e = u.current;
|
|
154
154
|
if (!e) return;
|
|
155
|
-
const a = e.$(`#${
|
|
155
|
+
const a = e.$(`#${d}`);
|
|
156
156
|
if (!a || a.length === 0) {
|
|
157
157
|
console.error("当前节点不存在");
|
|
158
158
|
return;
|
|
159
159
|
}
|
|
160
|
-
const t = e.nodes().filter((
|
|
160
|
+
const t = e.nodes().filter((s) => s.data("parentId") ? (s.data("parentId") === d || s.data("idLabel") === `${d}-${s.data("name")}`) && s.data("zktype") === n.zktype : !1);
|
|
161
161
|
if (t.length > 0) {
|
|
162
|
-
const
|
|
163
|
-
(c) => c.data("source") ===
|
|
164
|
-
),
|
|
162
|
+
const s = t.map((c) => c.id()), r = t.connectedEdges(), N = e.edges().filter(
|
|
163
|
+
(c) => c.data("source") === d && s.includes(c.data("target"))
|
|
164
|
+
), $ = e.edges().filter((c) => c.data("appendedBy") === d), M = r.merge(N).merge($).filter((c) => c.data().zktype === n.zktype);
|
|
165
165
|
t.animate({
|
|
166
166
|
style: { opacity: 0 }
|
|
167
167
|
}, {
|
|
168
168
|
duration: 200,
|
|
169
169
|
complete: () => {
|
|
170
170
|
e.remove(t), e.remove(M), P((c) => {
|
|
171
|
-
const
|
|
171
|
+
const D = c.filter((m) => {
|
|
172
172
|
var b, te;
|
|
173
173
|
const i = m.data.zktype;
|
|
174
|
-
if (m.group === "nodes" &&
|
|
174
|
+
if (m.group === "nodes" && s.includes((b = m.data) == null ? void 0 : b.id) && i && i === n.zktype)
|
|
175
175
|
return !1;
|
|
176
|
-
if (m.group === "edges" && i && i ===
|
|
177
|
-
const
|
|
178
|
-
const A =
|
|
176
|
+
if (m.group === "edges" && i && i === n.zktype) {
|
|
177
|
+
const xe = Array.from($).map((Ce) => {
|
|
178
|
+
const A = Ce.data();
|
|
179
179
|
return `${A.source}-${A.target}-${A.label}`;
|
|
180
|
-
}), q = m.data,
|
|
181
|
-
return !
|
|
180
|
+
}), q = m.data, Ne = xe.includes(`${q.source}-${q.target}-${q.label}`), ke = ((te = m.data) == null ? void 0 : te.appendedBy) === d;
|
|
181
|
+
return !Ne && !ke;
|
|
182
182
|
}
|
|
183
183
|
return !0;
|
|
184
|
-
}), { typeListObj: y, relationListObj: U } = F({}, { graphData:
|
|
185
|
-
return B(y), W(U),
|
|
184
|
+
}), { typeListObj: y, relationListObj: U } = F({}, { graphData: D, typeObj: {} });
|
|
185
|
+
return B(y), W(U), D;
|
|
186
186
|
}), a.data("appendedNodes", []), a.data("isExpanded", !1);
|
|
187
187
|
}
|
|
188
188
|
}), setTimeout(() => {
|
|
@@ -190,26 +190,26 @@ const it = ({
|
|
|
190
190
|
}, 300);
|
|
191
191
|
} else {
|
|
192
192
|
try {
|
|
193
|
-
Z(!0),
|
|
193
|
+
Z(!0), C.open({
|
|
194
194
|
type: "loading",
|
|
195
195
|
content: "正在展开...",
|
|
196
196
|
duration: 0
|
|
197
197
|
});
|
|
198
|
-
const
|
|
199
|
-
if (B(
|
|
198
|
+
const s = await re({ uri: d, queryType: 1, kgId: l, zktype: n.zktype }), { elements: r, typeListObj: N, relationListObj: $ } = F(s.data, { graphData: p, typeObj: x, relationObj: R, zktype: n.zktype });
|
|
199
|
+
if (B(N), W($), !((r == null ? void 0 : r.length) > 0)) {
|
|
200
200
|
setTimeout(() => {
|
|
201
|
-
|
|
201
|
+
C.destroy(), C.warning("暂无数据");
|
|
202
202
|
}, 2e3);
|
|
203
203
|
return;
|
|
204
204
|
}
|
|
205
|
-
if ((
|
|
205
|
+
if ((r == null ? void 0 : r.length) > 0) {
|
|
206
206
|
const M = e.layoutUtilities({
|
|
207
207
|
...ne(),
|
|
208
208
|
idealEdgeLength: 80,
|
|
209
209
|
// 与你的期望边长匹配
|
|
210
210
|
offset: 30
|
|
211
211
|
// 随机偏移,避免完全重叠
|
|
212
|
-
}), c =
|
|
212
|
+
}), c = r.map((i) => {
|
|
213
213
|
if (i.group === "nodes") {
|
|
214
214
|
const b = $e * X;
|
|
215
215
|
return {
|
|
@@ -221,12 +221,12 @@ const it = ({
|
|
|
221
221
|
},
|
|
222
222
|
data: {
|
|
223
223
|
...i.data,
|
|
224
|
-
parentId:
|
|
224
|
+
parentId: d,
|
|
225
225
|
// 标记父节点
|
|
226
|
-
appendedBy:
|
|
226
|
+
appendedBy: d,
|
|
227
227
|
// 标记由谁追加
|
|
228
|
-
idLabel:
|
|
229
|
-
zktype:
|
|
228
|
+
idLabel: d + "-" + i.data.label,
|
|
229
|
+
zktype: n.zktype,
|
|
230
230
|
isAppended: !0,
|
|
231
231
|
// 标记是追加节点
|
|
232
232
|
baseWidth: b,
|
|
@@ -238,13 +238,13 @@ const it = ({
|
|
|
238
238
|
...i,
|
|
239
239
|
data: {
|
|
240
240
|
...i.data,
|
|
241
|
-
appendedBy:
|
|
242
|
-
zktype:
|
|
241
|
+
appendedBy: d,
|
|
242
|
+
zktype: n.zktype
|
|
243
243
|
}
|
|
244
244
|
};
|
|
245
|
-
}),
|
|
245
|
+
}), D = e.add(c);
|
|
246
246
|
P([...p, ...c]);
|
|
247
|
-
const y =
|
|
247
|
+
const y = D.filter(":node"), U = y.map((i) => i.id());
|
|
248
248
|
a.data("appendedNodes", U), a.data("isExpanded", !0);
|
|
249
249
|
const m = e.nodes().difference(y);
|
|
250
250
|
m.forEach((i) => i.lock()), M.placeNewNodes(y), e.layout({
|
|
@@ -281,26 +281,26 @@ const it = ({
|
|
|
281
281
|
}, 600);
|
|
282
282
|
} else
|
|
283
283
|
console.log("没有找到相关节点数据");
|
|
284
|
-
|
|
285
|
-
} catch (
|
|
286
|
-
|
|
284
|
+
C.destroy();
|
|
285
|
+
} catch (s) {
|
|
286
|
+
C.destroy(), C.error("请求接口失败"), console.error("22请求接口失败:", s);
|
|
287
287
|
}
|
|
288
288
|
Z(!1);
|
|
289
289
|
}
|
|
290
|
-
|
|
290
|
+
j({ visible: !1 });
|
|
291
291
|
}, he = {
|
|
292
292
|
expanded: "typed-literal",
|
|
293
293
|
contract: "uri"
|
|
294
|
-
}, ve = (
|
|
294
|
+
}, ve = (n, d) => {
|
|
295
295
|
var e;
|
|
296
|
-
console.log("handleMenuAction:::",
|
|
297
|
-
const l =
|
|
296
|
+
console.log("handleMenuAction:::", n, d);
|
|
297
|
+
const l = d || f.targetNode;
|
|
298
298
|
if (l) {
|
|
299
|
-
const a =
|
|
299
|
+
const a = n.ids, t = l.data();
|
|
300
300
|
if (["expanded", "contract"].includes(a))
|
|
301
301
|
me({ kgId: g.kgId, ...t, zktype: he[a] });
|
|
302
302
|
else if (a === "nodeInfo") {
|
|
303
|
-
const o = l,
|
|
303
|
+
const o = l, s = {
|
|
304
304
|
id: o.id(),
|
|
305
305
|
data: o.data(),
|
|
306
306
|
position: o.position(),
|
|
@@ -310,12 +310,19 @@ const it = ({
|
|
|
310
310
|
classes: o.classes(),
|
|
311
311
|
style: o.style()
|
|
312
312
|
};
|
|
313
|
-
|
|
314
|
-
} else a === "knowledgeCard" &&
|
|
315
|
-
(e =
|
|
313
|
+
_.current.open(s);
|
|
314
|
+
} else a === "knowledgeCard" && J.current.open(l.data());
|
|
315
|
+
(e = n.onClick) == null || e.call(n, l), j({ visible: !1, x: 0, y: 0, targetNode: null });
|
|
316
316
|
}
|
|
317
317
|
};
|
|
318
|
-
|
|
318
|
+
console.log(111, !(((G = p == null ? void 0 : p.nodes) == null ? void 0 : G.length) > 0), p);
|
|
319
|
+
const be = () => {
|
|
320
|
+
const n = {};
|
|
321
|
+
return Object.keys(x).forEach((d) => {
|
|
322
|
+
d !== "_" && (n[d] = x[d]);
|
|
323
|
+
}), n;
|
|
324
|
+
};
|
|
325
|
+
return /* @__PURE__ */ h(Be, { value: { pathNodes: fe, setPathNodes: Q, graphInfo: g, graphData: p, layoutType: ue, setLayoutType: ge, knowledgeCardApi: ae, queryStatisticsConfig: ce, actionBar: ie }, children: /* @__PURE__ */ oe("div", { className: He("cytoscape-container relative", pe), children: [
|
|
319
326
|
/* @__PURE__ */ h("div", { className: "btn-group" }),
|
|
320
327
|
/* @__PURE__ */ h(
|
|
321
328
|
Le,
|
|
@@ -324,14 +331,14 @@ const it = ({
|
|
|
324
331
|
cyRef: u,
|
|
325
332
|
graphInfo: g,
|
|
326
333
|
initNodeScale: X,
|
|
327
|
-
cyContainerRef:
|
|
328
|
-
typeObj:
|
|
329
|
-
relationObj:
|
|
330
|
-
colors:
|
|
334
|
+
cyContainerRef: O,
|
|
335
|
+
typeObj: be(),
|
|
336
|
+
relationObj: R,
|
|
337
|
+
colors: w
|
|
331
338
|
}
|
|
332
339
|
),
|
|
333
340
|
/* @__PURE__ */ oe("div", { className: "relative h-100", children: [
|
|
334
|
-
/* @__PURE__ */ h("div", { ref:
|
|
341
|
+
/* @__PURE__ */ h("div", { ref: O, className: "cy-container" }),
|
|
335
342
|
f.visible && f.targetNode && /* @__PURE__ */ h(
|
|
336
343
|
"div",
|
|
337
344
|
{
|
|
@@ -351,17 +358,17 @@ const it = ({
|
|
|
351
358
|
height: "200px",
|
|
352
359
|
overflow: "hidden"
|
|
353
360
|
},
|
|
354
|
-
onClick: (
|
|
355
|
-
children: /* @__PURE__ */ h(
|
|
361
|
+
onClick: (n) => n.stopPropagation(),
|
|
362
|
+
children: /* @__PURE__ */ h(Ie, { items: ye, centerImage: (ee = f == null ? void 0 : f.targetNode) == null ? void 0 : ee.data().image, targetNode: f.targetNode, onClick: (n, d) => ve(n, d) })
|
|
356
363
|
}
|
|
357
364
|
),
|
|
358
|
-
|
|
365
|
+
T.visible && /* @__PURE__ */ h(
|
|
359
366
|
"div",
|
|
360
367
|
{
|
|
361
368
|
style: {
|
|
362
369
|
position: "absolute",
|
|
363
|
-
left: `${
|
|
364
|
-
top: `${
|
|
370
|
+
left: `${T.x}px`,
|
|
371
|
+
top: `${T.y}px`,
|
|
365
372
|
transform: "translateX(-50%)",
|
|
366
373
|
backgroundColor: "rgba(0, 0, 0, 0.85)",
|
|
367
374
|
color: "#fff",
|
|
@@ -375,14 +382,14 @@ const it = ({
|
|
|
375
382
|
overflow: "hidden",
|
|
376
383
|
textOverflow: "ellipsis"
|
|
377
384
|
},
|
|
378
|
-
children:
|
|
385
|
+
children: T.content
|
|
379
386
|
}
|
|
380
387
|
)
|
|
381
388
|
] }),
|
|
382
|
-
/* @__PURE__ */ h(
|
|
383
|
-
/* @__PURE__ */ h(
|
|
389
|
+
/* @__PURE__ */ h(Pe, { ref: _ }),
|
|
390
|
+
/* @__PURE__ */ h(We, { ref: J })
|
|
384
391
|
] }) });
|
|
385
392
|
};
|
|
386
393
|
export {
|
|
387
|
-
|
|
394
|
+
lt as default
|
|
388
395
|
};
|