@lv-x-software-house/x_view 1.3.8 → 1.3.9
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/dist/index.js +422 -213
- package/dist/index.mjs +346 -137
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -44,9 +44,9 @@ __export(index_exports, {
|
|
|
44
44
|
module.exports = __toCommonJS(index_exports);
|
|
45
45
|
|
|
46
46
|
// src/XViewScene.jsx
|
|
47
|
-
var
|
|
47
|
+
var import_react38 = __toESM(require("react"));
|
|
48
48
|
var import_navigation = require("next/navigation");
|
|
49
|
-
var
|
|
49
|
+
var import_react39 = require("next-auth/react");
|
|
50
50
|
var import_crypto_js = __toESM(require("crypto-js"));
|
|
51
51
|
var THREE3 = __toESM(require("three"));
|
|
52
52
|
var import_OrbitControls = require("three/examples/jsm/controls/OrbitControls.js");
|
|
@@ -5158,8 +5158,8 @@ function ContextMenu({
|
|
|
5158
5158
|
const handleClickOutside = (e) => {
|
|
5159
5159
|
if (menuRef.current && !menuRef.current.contains(e.target)) onClose();
|
|
5160
5160
|
};
|
|
5161
|
-
document.addEventListener("
|
|
5162
|
-
return () => document.removeEventListener("
|
|
5161
|
+
document.addEventListener("pointerdown", handleClickOutside);
|
|
5162
|
+
return () => document.removeEventListener("pointerdown", handleClickOutside);
|
|
5163
5163
|
}, [data.visible, onClose]);
|
|
5164
5164
|
const visibleLinkIds = (0, import_react2.useMemo)(() => {
|
|
5165
5165
|
var _a2;
|
|
@@ -5599,7 +5599,7 @@ function ContextMenu({
|
|
|
5599
5599
|
"div",
|
|
5600
5600
|
{
|
|
5601
5601
|
ref: menuRef,
|
|
5602
|
-
className: "ui-overlay context-menu-class origin-top-left rounded-xl border border-white/10 bg-slate-950/70 backdrop-blur-xl shadow-[0_20px_80px_rgba(0,0,0,0.6)] ring-1 ring-white/10 text-white min-w-[220px] max-w-[min(95vw,420px)]
|
|
5602
|
+
className: "ui-overlay context-menu-class origin-top-left rounded-xl border border-white/10 bg-slate-950/70 backdrop-blur-xl shadow-[0_20px_80px_rgba(0,0,0,0.6)] ring-1 ring-white/10 text-white min-w-[220px] max-w-[min(95vw,420px)] max-h-[85vh] overflow-y-auto custom-scrollbar w-max",
|
|
5603
5603
|
style: { position: "absolute", left: `${menuPos.left}px`, top: `${menuPos.top}px`, zIndex: 1e3 },
|
|
5604
5604
|
onPointerDown: swallow,
|
|
5605
5605
|
onPointerMove: swallow,
|
|
@@ -13747,14 +13747,18 @@ function NodeDetailsPanel({
|
|
|
13747
13747
|
});
|
|
13748
13748
|
const [selectedImageUrl, setSelectedImageUrl] = (0, import_react21.useState)((node == null ? void 0 : node.textureImageUrl) ?? null);
|
|
13749
13749
|
const [hasUnsavedChanges, setHasUnsavedChanges] = (0, import_react21.useState)(false);
|
|
13750
|
-
const
|
|
13750
|
+
const isMobile = typeof window !== "undefined" && window.innerWidth < 640;
|
|
13751
|
+
const maxPanelW = typeof window !== "undefined" ? Math.min(window.innerWidth - 32, 1200) : 1200;
|
|
13752
|
+
const defaultWidth = isMobile ? typeof window !== "undefined" ? window.innerWidth - 32 : 360 : isReadMode ? 700 : 440;
|
|
13751
13753
|
const { width: panelWidth, isResizing, handlePointerDown: handleResize, setWidth } = useResizablePanel({
|
|
13752
|
-
initialWidth:
|
|
13753
|
-
minWidth:
|
|
13754
|
+
initialWidth: defaultWidth,
|
|
13755
|
+
minWidth: typeof window !== "undefined" ? Math.min(280, window.innerWidth - 32) : 280,
|
|
13754
13756
|
maxWidth: maxPanelW
|
|
13755
13757
|
});
|
|
13756
13758
|
(0, import_react21.useEffect)(() => {
|
|
13757
|
-
|
|
13759
|
+
const isMob = typeof window !== "undefined" && window.innerWidth < 640;
|
|
13760
|
+
const targetW = isMob ? typeof window !== "undefined" ? window.innerWidth - 32 : 360 : isReadMode ? 700 : 440;
|
|
13761
|
+
setWidth(targetW);
|
|
13758
13762
|
}, [isReadMode, setWidth]);
|
|
13759
13763
|
const prevNodeIdRef = (0, import_react21.useRef)(null);
|
|
13760
13764
|
const propsEndRef = (0, import_react21.useRef)(null);
|
|
@@ -17415,8 +17419,8 @@ function MultiNodeContextMenu({
|
|
|
17415
17419
|
const handleClickOutside = (e) => {
|
|
17416
17420
|
if (menuRef.current && !menuRef.current.contains(e.target)) onClose();
|
|
17417
17421
|
};
|
|
17418
|
-
document.addEventListener("
|
|
17419
|
-
return () => document.removeEventListener("
|
|
17422
|
+
document.addEventListener("pointerdown", handleClickOutside);
|
|
17423
|
+
return () => document.removeEventListener("pointerdown", handleClickOutside);
|
|
17420
17424
|
}, [data.visible, onClose]);
|
|
17421
17425
|
if (!data.visible || !data.nodeIds || data.nodeIds.size === 0) return null;
|
|
17422
17426
|
const swallow = (e) => e.stopPropagation();
|
|
@@ -17857,8 +17861,8 @@ function RelationshipContextMenu({
|
|
|
17857
17861
|
const handleClickOutside = (e) => {
|
|
17858
17862
|
if (menuRef.current && !menuRef.current.contains(e.target)) onClose();
|
|
17859
17863
|
};
|
|
17860
|
-
document.addEventListener("
|
|
17861
|
-
return () => document.removeEventListener("
|
|
17864
|
+
document.addEventListener("pointerdown", handleClickOutside);
|
|
17865
|
+
return () => document.removeEventListener("pointerdown", handleClickOutside);
|
|
17862
17866
|
}, [data.visible, onClose]);
|
|
17863
17867
|
if (!data.visible) return null;
|
|
17864
17868
|
const swallow = (e) => e.stopPropagation();
|
|
@@ -19426,63 +19430,201 @@ function MilestoneManager({
|
|
|
19426
19430
|
}
|
|
19427
19431
|
|
|
19428
19432
|
// src/components/UpgradeModal.jsx
|
|
19433
|
+
var import_react37 = __toESM(require("react"));
|
|
19434
|
+
|
|
19435
|
+
// src/components/icons/UltraMinimalIcon.jsx
|
|
19429
19436
|
var import_react36 = __toESM(require("react"));
|
|
19430
|
-
|
|
19437
|
+
function UltraMinimalIcon({
|
|
19438
|
+
size = 13,
|
|
19439
|
+
className = "",
|
|
19440
|
+
strokeWidth = 1.5,
|
|
19441
|
+
...props
|
|
19442
|
+
}) {
|
|
19443
|
+
return /* @__PURE__ */ import_react36.default.createElement(
|
|
19444
|
+
"svg",
|
|
19445
|
+
{
|
|
19446
|
+
width: size,
|
|
19447
|
+
height: size,
|
|
19448
|
+
viewBox: "0 0 24 24",
|
|
19449
|
+
fill: "none",
|
|
19450
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
19451
|
+
className: `inline-block shrink-0 transition-transform duration-200 ${className}`,
|
|
19452
|
+
...props
|
|
19453
|
+
},
|
|
19454
|
+
/* @__PURE__ */ import_react36.default.createElement(
|
|
19455
|
+
"path",
|
|
19456
|
+
{
|
|
19457
|
+
d: "M6 3h12l4 6-10 12L2 9l4-6z",
|
|
19458
|
+
stroke: "currentColor",
|
|
19459
|
+
strokeWidth,
|
|
19460
|
+
strokeLinecap: "round",
|
|
19461
|
+
strokeLinejoin: "round"
|
|
19462
|
+
}
|
|
19463
|
+
),
|
|
19464
|
+
/* @__PURE__ */ import_react36.default.createElement(
|
|
19465
|
+
"path",
|
|
19466
|
+
{
|
|
19467
|
+
d: "M11 3v6",
|
|
19468
|
+
stroke: "currentColor",
|
|
19469
|
+
strokeWidth,
|
|
19470
|
+
strokeLinecap: "round",
|
|
19471
|
+
strokeLinejoin: "round"
|
|
19472
|
+
}
|
|
19473
|
+
),
|
|
19474
|
+
/* @__PURE__ */ import_react36.default.createElement(
|
|
19475
|
+
"path",
|
|
19476
|
+
{
|
|
19477
|
+
d: "M13 3v6",
|
|
19478
|
+
stroke: "currentColor",
|
|
19479
|
+
strokeWidth,
|
|
19480
|
+
strokeLinecap: "round",
|
|
19481
|
+
strokeLinejoin: "round"
|
|
19482
|
+
}
|
|
19483
|
+
),
|
|
19484
|
+
/* @__PURE__ */ import_react36.default.createElement(
|
|
19485
|
+
"path",
|
|
19486
|
+
{
|
|
19487
|
+
d: "M2 9h20",
|
|
19488
|
+
stroke: "currentColor",
|
|
19489
|
+
strokeWidth,
|
|
19490
|
+
strokeLinecap: "round",
|
|
19491
|
+
strokeLinejoin: "round"
|
|
19492
|
+
}
|
|
19493
|
+
),
|
|
19494
|
+
/* @__PURE__ */ import_react36.default.createElement(
|
|
19495
|
+
"path",
|
|
19496
|
+
{
|
|
19497
|
+
d: "M12 21L8 9",
|
|
19498
|
+
stroke: "currentColor",
|
|
19499
|
+
strokeWidth,
|
|
19500
|
+
strokeLinecap: "round",
|
|
19501
|
+
strokeLinejoin: "round"
|
|
19502
|
+
}
|
|
19503
|
+
),
|
|
19504
|
+
/* @__PURE__ */ import_react36.default.createElement(
|
|
19505
|
+
"path",
|
|
19506
|
+
{
|
|
19507
|
+
d: "M12 21l4-12",
|
|
19508
|
+
stroke: "currentColor",
|
|
19509
|
+
strokeWidth,
|
|
19510
|
+
strokeLinecap: "round",
|
|
19511
|
+
strokeLinejoin: "round"
|
|
19512
|
+
}
|
|
19513
|
+
)
|
|
19514
|
+
);
|
|
19515
|
+
}
|
|
19516
|
+
|
|
19517
|
+
// src/components/UpgradeModal.jsx
|
|
19431
19518
|
function UpgradeModal({
|
|
19432
19519
|
isOpen,
|
|
19433
19520
|
onClose,
|
|
19434
|
-
nodeCounter,
|
|
19521
|
+
nodeCounter = 0,
|
|
19435
19522
|
nodeLimit = 100,
|
|
19523
|
+
plan,
|
|
19436
19524
|
onUpgrade
|
|
19437
19525
|
}) {
|
|
19526
|
+
const [isSubmitting, setIsSubmitting] = (0, import_react37.useState)(false);
|
|
19438
19527
|
if (!isOpen) return null;
|
|
19439
|
-
|
|
19440
|
-
|
|
19441
|
-
|
|
19442
|
-
|
|
19443
|
-
|
|
19444
|
-
|
|
19445
|
-
|
|
19446
|
-
|
|
19447
|
-
|
|
19448
|
-
|
|
19449
|
-
|
|
19450
|
-
|
|
19528
|
+
const currentPlan = plan || (nodeLimit === -1 ? "premium" : "free");
|
|
19529
|
+
const handleUpgradeClick = async () => {
|
|
19530
|
+
if (isSubmitting) return;
|
|
19531
|
+
setIsSubmitting(true);
|
|
19532
|
+
try {
|
|
19533
|
+
if (onUpgrade) {
|
|
19534
|
+
await onUpgrade();
|
|
19535
|
+
} else {
|
|
19536
|
+
alert("Redirecting to checkout...");
|
|
19537
|
+
}
|
|
19538
|
+
} catch (error) {
|
|
19539
|
+
console.error("Error during upgrade:", error);
|
|
19540
|
+
} finally {
|
|
19541
|
+
setIsSubmitting(false);
|
|
19542
|
+
}
|
|
19543
|
+
};
|
|
19544
|
+
const limit = nodeLimit === -1 ? 100 : nodeLimit;
|
|
19545
|
+
const safeNodeCounter = Math.max(0, nodeCounter || 0);
|
|
19546
|
+
const usagePercentage = Math.min(
|
|
19547
|
+
100,
|
|
19548
|
+
Math.round(safeNodeCounter / limit * 100)
|
|
19549
|
+
);
|
|
19550
|
+
return /* @__PURE__ */ import_react37.default.createElement("div", { className: "fixed inset-0 bg-slate-950/40 backdrop-blur-md z-[10000] flex justify-center items-center p-4 animate-in fade-in duration-300 font-sans select-none" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "bg-[#0b1224]/80 border border-cyan-600/20 p-7 rounded-3xl shadow-[0_0_50px_-12px_rgba(6,182,212,0.2)] w-full max-w-[380px] relative text-center overflow-hidden animate-in zoom-in-95 duration-300" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "absolute -top-20 left-1/2 -translate-x-1/2 w-40 h-40 bg-cyan-600/10 rounded-full blur-[60px] pointer-events-none" }), /* @__PURE__ */ import_react37.default.createElement("div", { className: "flex justify-center mb-4 relative" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "relative w-14 h-14 flex items-center justify-center" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "absolute inset-0 bg-cyan-500 rounded-full blur-2xl opacity-20 animate-pulse" }), /* @__PURE__ */ import_react37.default.createElement("div", { className: "relative w-12 h-12 rounded-xl bg-slate-900 border border-cyan-400/30 shadow-lg flex items-center justify-center z-10 animate-float" }, /* @__PURE__ */ import_react37.default.createElement(
|
|
19551
|
+
UltraMinimalIcon,
|
|
19552
|
+
{
|
|
19553
|
+
size: 22,
|
|
19554
|
+
className: "text-cyan-400",
|
|
19555
|
+
strokeWidth: 2
|
|
19556
|
+
}
|
|
19557
|
+
)))), /* @__PURE__ */ import_react37.default.createElement("h2", { className: "text-xl font-bold text-white mb-1 tracking-tight font-sans" }, "Upgrade x.plore"), /* @__PURE__ */ import_react37.default.createElement("p", { className: "text-slate-400 text-[11px] mb-6 leading-relaxed px-4 font-medium italic" }, "Unlock unlimited nodes and community features."), /* @__PURE__ */ import_react37.default.createElement("div", { className: "grid grid-cols-2 gap-3 mb-3 text-left" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "bg-gradient-to-b from-[#0e172a]/90 to-[#070c18]/90 border border-cyan-500/20 hover:border-cyan-400/40 p-3.5 rounded-2xl flex flex-col justify-between shadow-md transition-all duration-300" }, /* @__PURE__ */ import_react37.default.createElement("div", null, /* @__PURE__ */ import_react37.default.createElement("span", { className: "text-xs font-sans font-normal text-cyan-400/80 tracking-normal block mb-1.5" }, "Node Usage"), /* @__PURE__ */ import_react37.default.createElement("div", { className: "flex items-baseline gap-1" }, /* @__PURE__ */ import_react37.default.createElement("span", { className: "text-lg font-bold text-white font-sans tracking-tight" }, nodeCounter), /* @__PURE__ */ import_react37.default.createElement("span", { className: "text-xs font-sans font-medium text-slate-400" }, "/ ", currentPlan === "premium" ? "\u221E" : "100"))), currentPlan !== "premium" && /* @__PURE__ */ import_react37.default.createElement("div", { className: "mt-2.5" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "w-full h-1.5 bg-slate-900 border border-white/5 rounded-full overflow-hidden p-[1px]" }, /* @__PURE__ */ import_react37.default.createElement(
|
|
19451
19558
|
"div",
|
|
19452
19559
|
{
|
|
19453
|
-
className: "
|
|
19454
|
-
|
|
19560
|
+
className: `h-full rounded-full transition-all duration-500 ${usagePercentage >= 100 ? "bg-gradient-to-r from-rose-500 to-pink-500 shadow-[0_0_8px_#f43f5e]" : "bg-gradient-to-r from-cyan-500 to-sky-300 shadow-[0_0_8px_#22d3ee]"}`,
|
|
19561
|
+
style: { width: `${usagePercentage}%` }
|
|
19455
19562
|
}
|
|
19456
|
-
), /* @__PURE__ */
|
|
19563
|
+
)))), /* @__PURE__ */ import_react37.default.createElement("div", { className: "bg-gradient-to-b from-[#0e172a]/90 to-[#070c18]/90 border border-cyan-500/20 hover:border-cyan-400/40 p-3.5 rounded-2xl flex flex-col justify-between shadow-md transition-all duration-300" }, /* @__PURE__ */ import_react37.default.createElement("div", null, /* @__PURE__ */ import_react37.default.createElement("span", { className: "text-xs font-sans font-normal text-cyan-400/80 tracking-normal block mb-1.5" }, "Current Plan"), /* @__PURE__ */ import_react37.default.createElement("div", { className: "mt-1" }, /* @__PURE__ */ import_react37.default.createElement(
|
|
19564
|
+
"span",
|
|
19565
|
+
{
|
|
19566
|
+
className: `inline-flex items-center gap-1.5 px-2.5 py-1 rounded-lg border text-xs font-normal font-sans tracking-normal ${currentPlan === "premium" ? "bg-indigo-500/15 border-indigo-400/30 text-indigo-300" : "bg-cyan-500/10 border-cyan-400/30 text-cyan-300"}`
|
|
19567
|
+
},
|
|
19568
|
+
/* @__PURE__ */ import_react37.default.createElement(
|
|
19569
|
+
"span",
|
|
19570
|
+
{
|
|
19571
|
+
className: `w-1.5 h-1.5 rounded-full animate-pulse ${currentPlan === "premium" ? "bg-indigo-400 shadow-[0_0_6px_#818cf8]" : "bg-cyan-400 shadow-[0_0_6px_#22d3ee]"}`
|
|
19572
|
+
}
|
|
19573
|
+
),
|
|
19574
|
+
currentPlan === "premium" ? "Premium" : "Free"
|
|
19575
|
+
))))), /* @__PURE__ */ import_react37.default.createElement("div", { className: "bg-gradient-to-b from-[#0e172a]/70 to-[#070c18]/80 border border-cyan-500/15 p-3.5 rounded-2xl space-y-2.5 mb-5 text-left shadow-sm" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "flex items-center gap-2.5 text-slate-200 text-xs font-medium" }, /* @__PURE__ */ import_react37.default.createElement("span", { className: "w-1.5 h-1.5 rounded-full bg-cyan-400 shadow-[0_0_6px_#22d3ee] shrink-0" }), /* @__PURE__ */ import_react37.default.createElement("span", null, "Unlimited Nodes")), /* @__PURE__ */ import_react37.default.createElement("div", { className: "flex items-center gap-2.5 text-slate-200 text-xs font-medium" }, /* @__PURE__ */ import_react37.default.createElement("span", { className: "w-1.5 h-1.5 rounded-full bg-cyan-400 shadow-[0_0_6px_#22d3ee] shrink-0" }), /* @__PURE__ */ import_react37.default.createElement("span", null, "Community and collaboration features"))), /* @__PURE__ */ import_react37.default.createElement("div", { className: "space-y-2.5" }, currentPlan !== "premium" ? /* @__PURE__ */ import_react37.default.createElement(
|
|
19457
19576
|
"button",
|
|
19458
19577
|
{
|
|
19459
|
-
onClick:
|
|
19460
|
-
|
|
19578
|
+
onClick: handleUpgradeClick,
|
|
19579
|
+
disabled: isSubmitting,
|
|
19580
|
+
className: "group relative w-full py-3.5 rounded-xl bg-gradient-to-r from-cyan-400 to-cyan-500 hover:from-cyan-300 hover:to-cyan-400 text-slate-950 font-normal text-sm tracking-normal font-sans shadow-[0_0_15px_rgba(34,211,238,0.22)] hover:shadow-[0_0_22px_rgba(34,211,238,0.38)] hover:scale-[1.01] active:scale-[0.98] transition-all duration-300 overflow-hidden cursor-pointer border border-cyan-300/30 disabled:opacity-30 disabled:grayscale"
|
|
19461
19581
|
},
|
|
19462
|
-
/* @__PURE__ */
|
|
19463
|
-
|
|
19582
|
+
/* @__PURE__ */ import_react37.default.createElement("div", { className: "absolute inset-0 bg-gradient-to-r from-transparent via-white/40 to-transparent -translate-x-full group-hover:translate-x-full transition-transform duration-700 ease-in-out pointer-events-none" }),
|
|
19583
|
+
isSubmitting ? /* @__PURE__ */ import_react37.default.createElement("div", { className: "relative z-10 flex items-center justify-center gap-2" }, /* @__PURE__ */ import_react37.default.createElement("div", { className: "h-4 w-4 border-2 border-slate-950/30 border-t-slate-950 rounded-full animate-spin" })) : /* @__PURE__ */ import_react37.default.createElement("span", { className: "relative z-10 font-normal" }, "Upgrade Now")
|
|
19584
|
+
) : /* @__PURE__ */ import_react37.default.createElement("div", { className: "w-full py-3 rounded-xl bg-indigo-500/10 border border-indigo-500/30 text-indigo-300 font-normal text-sm text-center flex items-center justify-center gap-2 font-sans tracking-normal" }, /* @__PURE__ */ import_react37.default.createElement("span", null, "Your Account is Premium")), /* @__PURE__ */ import_react37.default.createElement(
|
|
19464
19585
|
"button",
|
|
19465
19586
|
{
|
|
19466
|
-
|
|
19467
|
-
|
|
19468
|
-
if (onUpgrade) {
|
|
19469
|
-
await onUpgrade();
|
|
19470
|
-
} else {
|
|
19471
|
-
alert("Redirecionando para upgrade... (Em breve)");
|
|
19472
|
-
}
|
|
19473
|
-
onClose();
|
|
19474
|
-
}
|
|
19587
|
+
onClick: onClose,
|
|
19588
|
+
className: "w-full py-2.5 rounded-xl bg-slate-950/50 hover:bg-slate-900 border border-slate-800 text-slate-400 hover:text-white text-xs font-semibold transition-all duration-300 active:scale-[0.98] cursor-pointer text-center"
|
|
19475
19589
|
},
|
|
19476
|
-
"
|
|
19477
|
-
|
|
19478
|
-
), /* @__PURE__ */ import_react36.default.createElement(
|
|
19590
|
+
currentPlan === "premium" ? "Close" : "Continue with Free Plan"
|
|
19591
|
+
)), /* @__PURE__ */ import_react37.default.createElement(
|
|
19479
19592
|
"button",
|
|
19480
19593
|
{
|
|
19481
19594
|
onClick: onClose,
|
|
19482
|
-
className: "
|
|
19595
|
+
className: "absolute top-6 right-6 text-slate-500 hover:text-cyan-400 transition-all duration-300 p-1 hover:rotate-90 cursor-pointer",
|
|
19596
|
+
"aria-label": "Close modal"
|
|
19483
19597
|
},
|
|
19484
|
-
|
|
19485
|
-
|
|
19598
|
+
/* @__PURE__ */ import_react37.default.createElement(
|
|
19599
|
+
"svg",
|
|
19600
|
+
{
|
|
19601
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
19602
|
+
width: "18",
|
|
19603
|
+
height: "18",
|
|
19604
|
+
viewBox: "0 0 24 24",
|
|
19605
|
+
fill: "none",
|
|
19606
|
+
stroke: "currentColor",
|
|
19607
|
+
strokeWidth: "2.5",
|
|
19608
|
+
strokeLinecap: "round",
|
|
19609
|
+
strokeLinejoin: "round"
|
|
19610
|
+
},
|
|
19611
|
+
/* @__PURE__ */ import_react37.default.createElement("line", { x1: "18", y1: "6", x2: "6", y2: "18" }),
|
|
19612
|
+
/* @__PURE__ */ import_react37.default.createElement("line", { x1: "6", y1: "6", x2: "18", y2: "18" })
|
|
19613
|
+
)
|
|
19614
|
+
)), /* @__PURE__ */ import_react37.default.createElement("style", null, `
|
|
19615
|
+
@keyframes float {
|
|
19616
|
+
0%,
|
|
19617
|
+
100% {
|
|
19618
|
+
transform: translateY(0px);
|
|
19619
|
+
}
|
|
19620
|
+
50% {
|
|
19621
|
+
transform: translateY(-8px);
|
|
19622
|
+
}
|
|
19623
|
+
}
|
|
19624
|
+
.animate-float {
|
|
19625
|
+
animation: float 4s ease-in-out infinite;
|
|
19626
|
+
}
|
|
19627
|
+
`));
|
|
19486
19628
|
}
|
|
19487
19629
|
|
|
19488
19630
|
// src/XViewScene.jsx
|
|
@@ -19636,12 +19778,12 @@ function XViewScene({
|
|
|
19636
19778
|
onUpgrade
|
|
19637
19779
|
}) {
|
|
19638
19780
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
|
|
19639
|
-
const { data: session, status } = (0,
|
|
19781
|
+
const { data: session, status } = (0, import_react39.useSession)();
|
|
19640
19782
|
const router = (0, import_navigation.useRouter)();
|
|
19641
19783
|
const searchParams = (0, import_navigation.useSearchParams)();
|
|
19642
19784
|
const focusNodeId = searchParams == null ? void 0 : searchParams.get("focus");
|
|
19643
19785
|
const focusAncestryId = searchParams == null ? void 0 : searchParams.get("ancestry");
|
|
19644
|
-
const viewParams = (0,
|
|
19786
|
+
const viewParams = (0, import_react38.useMemo)(() => {
|
|
19645
19787
|
if (encryptedConfig) {
|
|
19646
19788
|
const data = decryptData(encryptedConfig);
|
|
19647
19789
|
if (data && data.id && data.owner_id && data.type) {
|
|
@@ -19650,12 +19792,12 @@ function XViewScene({
|
|
|
19650
19792
|
}
|
|
19651
19793
|
return null;
|
|
19652
19794
|
}, [encryptedConfig, session]);
|
|
19653
|
-
(0,
|
|
19795
|
+
(0, import_react38.useEffect)(() => {
|
|
19654
19796
|
if (viewParams == null ? void 0 : viewParams.name) {
|
|
19655
19797
|
document.title = `${viewParams.name} - x.plore`;
|
|
19656
19798
|
}
|
|
19657
19799
|
}, [viewParams == null ? void 0 : viewParams.name]);
|
|
19658
|
-
(0,
|
|
19800
|
+
(0, import_react38.useEffect)(() => {
|
|
19659
19801
|
async function verifyPermission() {
|
|
19660
19802
|
if (!viewParams || !session || !check_user_permission) return;
|
|
19661
19803
|
const { id, type, owner_id } = viewParams;
|
|
@@ -19692,68 +19834,70 @@ function XViewScene({
|
|
|
19692
19834
|
setIsLoading(false);
|
|
19693
19835
|
}
|
|
19694
19836
|
}, [viewParams, session, status, check_user_permission]);
|
|
19695
|
-
const sceneConfigId = (0,
|
|
19696
|
-
const ownerId = (0,
|
|
19697
|
-
const dbSaveUrl = (0,
|
|
19837
|
+
const sceneConfigId = (0, import_react38.useMemo)(() => (viewParams == null ? void 0 : viewParams.id) || null, [viewParams]);
|
|
19838
|
+
const ownerId = (0, import_react38.useMemo)(() => (viewParams == null ? void 0 : viewParams.owner_id) || null, [viewParams]);
|
|
19839
|
+
const dbSaveUrl = (0, import_react38.useMemo)(() => {
|
|
19698
19840
|
if (ownerId && sceneConfigId) {
|
|
19699
19841
|
return `x_view_dbs/${ownerId}/${sceneConfigId}`;
|
|
19700
19842
|
}
|
|
19701
19843
|
return null;
|
|
19702
19844
|
}, [ownerId, sceneConfigId]);
|
|
19703
|
-
const sceneSaveUrl = (0,
|
|
19845
|
+
const sceneSaveUrl = (0, import_react38.useMemo)(() => {
|
|
19704
19846
|
if (ownerId && sceneConfigId) {
|
|
19705
19847
|
return `x_view_scenes/${ownerId}/${sceneConfigId}`;
|
|
19706
19848
|
}
|
|
19707
19849
|
return null;
|
|
19708
19850
|
}, [ownerId, sceneConfigId]);
|
|
19709
|
-
const ancestry_save_url = (0,
|
|
19851
|
+
const ancestry_save_url = (0, import_react38.useMemo)(() => {
|
|
19710
19852
|
if (ownerId && sceneConfigId) {
|
|
19711
19853
|
return `x_view_ancestry/${ownerId}/${sceneConfigId}`;
|
|
19712
19854
|
}
|
|
19713
19855
|
return null;
|
|
19714
19856
|
}, [ownerId, sceneConfigId]);
|
|
19715
|
-
const sceneDataRef = (0,
|
|
19716
|
-
const parentDataRef = (0,
|
|
19857
|
+
const sceneDataRef = (0, import_react38.useRef)(null);
|
|
19858
|
+
const parentDataRef = (0, import_react38.useRef)(null);
|
|
19717
19859
|
const graphDataRef = parentDataRef;
|
|
19718
|
-
const ancestryDataRef = (0,
|
|
19719
|
-
const [isLoading, setIsLoading] = (0,
|
|
19720
|
-
const [isProcessing, setIsProcessing] = (0,
|
|
19721
|
-
const [permissionStatus, setPermissionStatus] = (0,
|
|
19722
|
-
const [userPermissionRole, setUserPermissionRole] = (0,
|
|
19723
|
-
const [viewMembers, setViewMembers] = (0,
|
|
19724
|
-
const [isInitialized, setIsInitialized] = (0,
|
|
19725
|
-
const [sceneVersion, setSceneVersion] = (0,
|
|
19726
|
-
const [contextMenu, setContextMenu] = (0,
|
|
19860
|
+
const ancestryDataRef = (0, import_react38.useRef)(null);
|
|
19861
|
+
const [isLoading, setIsLoading] = (0, import_react38.useState)(true);
|
|
19862
|
+
const [isProcessing, setIsProcessing] = (0, import_react38.useState)(false);
|
|
19863
|
+
const [permissionStatus, setPermissionStatus] = (0, import_react38.useState)("loading");
|
|
19864
|
+
const [userPermissionRole, setUserPermissionRole] = (0, import_react38.useState)(null);
|
|
19865
|
+
const [viewMembers, setViewMembers] = (0, import_react38.useState)([]);
|
|
19866
|
+
const [isInitialized, setIsInitialized] = (0, import_react38.useState)(false);
|
|
19867
|
+
const [sceneVersion, setSceneVersion] = (0, import_react38.useState)(0);
|
|
19868
|
+
const [contextMenu, setContextMenu] = (0, import_react38.useState)({
|
|
19727
19869
|
visible: false,
|
|
19728
19870
|
x: 0,
|
|
19729
19871
|
y: 0,
|
|
19730
19872
|
nodeData: null
|
|
19731
19873
|
});
|
|
19732
|
-
const [multiContextMenu, setMultiContextMenu] = (0,
|
|
19874
|
+
const [multiContextMenu, setMultiContextMenu] = (0, import_react38.useState)({
|
|
19733
19875
|
visible: false,
|
|
19734
19876
|
x: 0,
|
|
19735
19877
|
y: 0,
|
|
19736
19878
|
nodeIds: null
|
|
19737
19879
|
});
|
|
19738
|
-
const [relationshipMenu, setRelationshipMenu] = (0,
|
|
19880
|
+
const [relationshipMenu, setRelationshipMenu] = (0, import_react38.useState)({
|
|
19739
19881
|
visible: false,
|
|
19740
19882
|
x: 0,
|
|
19741
19883
|
y: 0,
|
|
19742
19884
|
linkObject: null
|
|
19743
19885
|
});
|
|
19744
|
-
const [creationMode, setCreationMode] = (0,
|
|
19886
|
+
const [creationMode, setCreationMode] = (0, import_react38.useState)({
|
|
19745
19887
|
isActive: false,
|
|
19746
19888
|
sourceNodeData: null
|
|
19747
19889
|
});
|
|
19748
|
-
const [versionMode, setVersionMode] = (0,
|
|
19890
|
+
const [versionMode, setVersionMode] = (0, import_react38.useState)({
|
|
19749
19891
|
isActive: false,
|
|
19750
19892
|
sourceNodeData: null
|
|
19751
19893
|
});
|
|
19752
|
-
const [questMode, setQuestMode] = (0,
|
|
19753
|
-
const [processMode, setProcessMode] = (0,
|
|
19754
|
-
const
|
|
19755
|
-
const
|
|
19756
|
-
const [
|
|
19894
|
+
const [questMode, setQuestMode] = (0, import_react38.useState)({ isActive: false });
|
|
19895
|
+
const [processMode, setProcessMode] = (0, import_react38.useState)({ isActive: false });
|
|
19896
|
+
const longPressTimeoutRef = (0, import_react38.useRef)(null);
|
|
19897
|
+
const isLongPressTriggeredRef = (0, import_react38.useRef)(false);
|
|
19898
|
+
const [hasFocusedInitial, setHasFocusedInitial] = (0, import_react38.useState)(false);
|
|
19899
|
+
const [hasOpenedInitialAncestry, setHasOpenedInitialAncestry] = (0, import_react38.useState)(false);
|
|
19900
|
+
const [questTreeMode, setQuestTreeMode] = (0, import_react38.useState)({
|
|
19757
19901
|
isActive: false,
|
|
19758
19902
|
questNodeId: null,
|
|
19759
19903
|
questTempData: null,
|
|
@@ -19763,7 +19907,7 @@ function XViewScene({
|
|
|
19763
19907
|
isAddingNodes: false,
|
|
19764
19908
|
isAddingAbstractionNodes: false
|
|
19765
19909
|
});
|
|
19766
|
-
const [processTreeMode, setProcessTreeMode] = (0,
|
|
19910
|
+
const [processTreeMode, setProcessTreeMode] = (0, import_react38.useState)({
|
|
19767
19911
|
isActive: false,
|
|
19768
19912
|
processNodeId: null,
|
|
19769
19913
|
processTempData: null,
|
|
@@ -19773,7 +19917,7 @@ function XViewScene({
|
|
|
19773
19917
|
isAddingNodes: false,
|
|
19774
19918
|
isAddingAbstractionNodes: false
|
|
19775
19919
|
});
|
|
19776
|
-
const [ancestryMode, setAncestryMode] = (0,
|
|
19920
|
+
const [ancestryMode, setAncestryMode] = (0, import_react38.useState)({
|
|
19777
19921
|
isActive: false,
|
|
19778
19922
|
tree: null,
|
|
19779
19923
|
selectedParentId: null,
|
|
@@ -19784,45 +19928,45 @@ function XViewScene({
|
|
|
19784
19928
|
ancestryDescriptionSections: [],
|
|
19785
19929
|
isAddingNodes: false
|
|
19786
19930
|
});
|
|
19787
|
-
const [readingMode, setReadingMode] = (0,
|
|
19931
|
+
const [readingMode, setReadingMode] = (0, import_react38.useState)({
|
|
19788
19932
|
isActive: false,
|
|
19789
19933
|
ancestry: null,
|
|
19790
19934
|
branchStack: [],
|
|
19791
19935
|
autoAbstraction: false
|
|
19792
19936
|
});
|
|
19793
|
-
const [formPosition, setFormPosition] = (0,
|
|
19937
|
+
const [formPosition, setFormPosition] = (0, import_react38.useState)({
|
|
19794
19938
|
left: 16,
|
|
19795
19939
|
top: 16,
|
|
19796
19940
|
opacity: 0
|
|
19797
19941
|
});
|
|
19798
|
-
const [detailsNode, setDetailsNode] = (0,
|
|
19799
|
-
const [detailsLink, setDetailsLink] = (0,
|
|
19800
|
-
const [ancestryLinkDetails, setAncestryLinkDetails] = (0,
|
|
19801
|
-
const [imageViewer, setImageViewer] = (0,
|
|
19942
|
+
const [detailsNode, setDetailsNode] = (0, import_react38.useState)(null);
|
|
19943
|
+
const [detailsLink, setDetailsLink] = (0, import_react38.useState)(null);
|
|
19944
|
+
const [ancestryLinkDetails, setAncestryLinkDetails] = (0, import_react38.useState)(null);
|
|
19945
|
+
const [imageViewer, setImageViewer] = (0, import_react38.useState)({
|
|
19802
19946
|
visible: false,
|
|
19803
19947
|
images: [],
|
|
19804
19948
|
startIndex: 0
|
|
19805
19949
|
});
|
|
19806
|
-
const [editingAncestryRel, setEditingAncestryRel] = (0,
|
|
19950
|
+
const [editingAncestryRel, setEditingAncestryRel] = (0, import_react38.useState)({
|
|
19807
19951
|
visible: false,
|
|
19808
19952
|
data: null,
|
|
19809
19953
|
path: null
|
|
19810
19954
|
});
|
|
19811
|
-
const [isImportModalOpen, setIsImportModalOpen] = (0,
|
|
19812
|
-
const [importSuccessMessage, setImportSuccessMessage] = (0,
|
|
19813
|
-
const [invalidTargetError, setInvalidTargetError] = (0,
|
|
19814
|
-
const [highlightedNodeId, setHighlightedNodeId] = (0,
|
|
19815
|
-
const [isBoardsOpen, setIsBoardsOpen] = (0,
|
|
19816
|
-
const [boardItems, setBoardItems] = (0,
|
|
19817
|
-
const [isSidebarOpen, setIsSidebarOpen] = (0,
|
|
19818
|
-
const [isMilestoneManagerOpen, setIsMilestoneManagerOpen] = (0,
|
|
19819
|
-
const [nodeCounter, setNodeCounter] = (0,
|
|
19820
|
-
const [isUpgradeModalOpen, setIsUpgradeModalOpen] = (0,
|
|
19821
|
-
const [nodeLimit, setNodeLimit] = (0,
|
|
19822
|
-
const mountRef = (0,
|
|
19823
|
-
const tooltipRef = (0,
|
|
19824
|
-
const formRef = (0,
|
|
19825
|
-
const stateRef = (0,
|
|
19955
|
+
const [isImportModalOpen, setIsImportModalOpen] = (0, import_react38.useState)(false);
|
|
19956
|
+
const [importSuccessMessage, setImportSuccessMessage] = (0, import_react38.useState)("");
|
|
19957
|
+
const [invalidTargetError, setInvalidTargetError] = (0, import_react38.useState)(null);
|
|
19958
|
+
const [highlightedNodeId, setHighlightedNodeId] = (0, import_react38.useState)(null);
|
|
19959
|
+
const [isBoardsOpen, setIsBoardsOpen] = (0, import_react38.useState)(false);
|
|
19960
|
+
const [boardItems, setBoardItems] = (0, import_react38.useState)([]);
|
|
19961
|
+
const [isSidebarOpen, setIsSidebarOpen] = (0, import_react38.useState)(false);
|
|
19962
|
+
const [isMilestoneManagerOpen, setIsMilestoneManagerOpen] = (0, import_react38.useState)(false);
|
|
19963
|
+
const [nodeCounter, setNodeCounter] = (0, import_react38.useState)(0);
|
|
19964
|
+
const [isUpgradeModalOpen, setIsUpgradeModalOpen] = (0, import_react38.useState)(false);
|
|
19965
|
+
const [nodeLimit, setNodeLimit] = (0, import_react38.useState)(100);
|
|
19966
|
+
const mountRef = (0, import_react38.useRef)(null);
|
|
19967
|
+
const tooltipRef = (0, import_react38.useRef)(null);
|
|
19968
|
+
const formRef = (0, import_react38.useRef)(null);
|
|
19969
|
+
const stateRef = (0, import_react38.useRef)({
|
|
19826
19970
|
readMode: {
|
|
19827
19971
|
currentMaxIndex: 0,
|
|
19828
19972
|
progressMap: {}
|
|
@@ -19907,16 +20051,16 @@ function XViewScene({
|
|
|
19907
20051
|
minWidth: 320,
|
|
19908
20052
|
maxWidth: maxReadPanelW
|
|
19909
20053
|
});
|
|
19910
|
-
(0,
|
|
20054
|
+
(0, import_react38.useEffect)(() => {
|
|
19911
20055
|
stateRef.current.ancestry = ancestryMode;
|
|
19912
20056
|
}, [ancestryMode]);
|
|
19913
|
-
(0,
|
|
20057
|
+
(0, import_react38.useEffect)(() => {
|
|
19914
20058
|
stateRef.current.questTree = questTreeMode;
|
|
19915
20059
|
}, [questTreeMode]);
|
|
19916
|
-
(0,
|
|
20060
|
+
(0, import_react38.useEffect)(() => {
|
|
19917
20061
|
stateRef.current.processTree = processTreeMode;
|
|
19918
20062
|
}, [processTreeMode]);
|
|
19919
|
-
(0,
|
|
20063
|
+
(0, import_react38.useEffect)(() => {
|
|
19920
20064
|
var _a2, _b2;
|
|
19921
20065
|
if (!isInitialized) return;
|
|
19922
20066
|
const map = /* @__PURE__ */ new Map();
|
|
@@ -19941,7 +20085,7 @@ function XViewScene({
|
|
|
19941
20085
|
}
|
|
19942
20086
|
stateRef.current.nodeIdToParentFileMap = map;
|
|
19943
20087
|
}, [isInitialized, sceneVersion]);
|
|
19944
|
-
const handleNavigateBack = (0,
|
|
20088
|
+
const handleNavigateBack = (0, import_react38.useCallback)(() => {
|
|
19945
20089
|
const type = viewParams == null ? void 0 : viewParams.type;
|
|
19946
20090
|
const tab = type === "database" ? "datasets" : "views";
|
|
19947
20091
|
const targetUrl = `/dashboard/xview?tab=${tab}`;
|
|
@@ -19952,7 +20096,7 @@ function XViewScene({
|
|
|
19952
20096
|
window.location.href = targetUrl;
|
|
19953
20097
|
}
|
|
19954
20098
|
}, [router, viewParams]);
|
|
19955
|
-
const handleConfirmImport = (0,
|
|
20099
|
+
const handleConfirmImport = (0, import_react38.useCallback)(
|
|
19956
20100
|
async (importPayload) => {
|
|
19957
20101
|
var _a2, _b2;
|
|
19958
20102
|
let files = [];
|
|
@@ -20077,7 +20221,7 @@ function XViewScene({
|
|
|
20077
20221
|
add_new_parent_file_to_scene_at_firebase_action
|
|
20078
20222
|
]
|
|
20079
20223
|
);
|
|
20080
|
-
const handleSaveConfig = (0,
|
|
20224
|
+
const handleSaveConfig = (0, import_react38.useCallback)(
|
|
20081
20225
|
async (newConfig) => {
|
|
20082
20226
|
if (!sceneDataRef.current || !save_view_data || !sceneSaveUrl) return;
|
|
20083
20227
|
const updatedData = {
|
|
@@ -20097,7 +20241,7 @@ function XViewScene({
|
|
|
20097
20241
|
const handleOpenImageViewer = (images, startIndex) => {
|
|
20098
20242
|
setImageViewer({ visible: true, images, startIndex });
|
|
20099
20243
|
};
|
|
20100
|
-
const tweenToTarget = (0,
|
|
20244
|
+
const tweenToTarget = (0, import_react38.useCallback)(
|
|
20101
20245
|
(target, zoomFactor = 1, forcedDirection = null) => {
|
|
20102
20246
|
const {
|
|
20103
20247
|
camera: sceneCamera,
|
|
@@ -20127,7 +20271,7 @@ function XViewScene({
|
|
|
20127
20271
|
if (!t || typeof t.closest !== "function") return false;
|
|
20128
20272
|
return !!t.closest(".ui-overlay");
|
|
20129
20273
|
};
|
|
20130
|
-
const buildFullAncestryTree = (0,
|
|
20274
|
+
const buildFullAncestryTree = (0, import_react38.useCallback)(
|
|
20131
20275
|
(idTree, nodes, ancestries = []) => {
|
|
20132
20276
|
if (!idTree) return null;
|
|
20133
20277
|
const nodeMap = new Map(nodes.map((n) => [String(n.id), n]));
|
|
@@ -20214,7 +20358,7 @@ function XViewScene({
|
|
|
20214
20358
|
},
|
|
20215
20359
|
[]
|
|
20216
20360
|
);
|
|
20217
|
-
const handleActivateTimeline = (0,
|
|
20361
|
+
const handleActivateTimeline = (0, import_react38.useCallback)(() => {
|
|
20218
20362
|
const { nodeObjects, tweenGroup, timelineIntervalsGroup } = stateRef.current;
|
|
20219
20363
|
if (!nodeObjects || !tweenGroup || !timelineIntervalsGroup) return;
|
|
20220
20364
|
while (timelineIntervalsGroup.children.length > 0) {
|
|
@@ -20367,7 +20511,7 @@ function XViewScene({
|
|
|
20367
20511
|
tweenToTarget(center, zoomFactor);
|
|
20368
20512
|
}
|
|
20369
20513
|
}, [tweenToTarget]);
|
|
20370
|
-
const handleVersionTimeline = (0,
|
|
20514
|
+
const handleVersionTimeline = (0, import_react38.useCallback)(
|
|
20371
20515
|
(sourceMesh, versionMeshes) => {
|
|
20372
20516
|
const { tweenGroup, timelineIntervalsGroup } = stateRef.current;
|
|
20373
20517
|
if (!tweenGroup || !timelineIntervalsGroup || versionMeshes.length === 0)
|
|
@@ -20516,7 +20660,7 @@ function XViewScene({
|
|
|
20516
20660
|
},
|
|
20517
20661
|
[tweenToTarget]
|
|
20518
20662
|
);
|
|
20519
|
-
(0,
|
|
20663
|
+
(0, import_react38.useEffect)(() => {
|
|
20520
20664
|
async function fetchAllData(configPath, ownerId2) {
|
|
20521
20665
|
var _a2, _b2;
|
|
20522
20666
|
if (!get_scene_view_data) {
|
|
@@ -20614,12 +20758,12 @@ function XViewScene({
|
|
|
20614
20758
|
focusNodeId,
|
|
20615
20759
|
focusAncestryId
|
|
20616
20760
|
]);
|
|
20617
|
-
const isNodeInView = (0,
|
|
20761
|
+
const isNodeInView = (0, import_react38.useCallback)((id) => {
|
|
20618
20762
|
const key = String(id);
|
|
20619
20763
|
const objs = stateRef.current.nodeObjects || {};
|
|
20620
20764
|
return !!objs[key];
|
|
20621
20765
|
}, []);
|
|
20622
|
-
const addOrUpdateNodeMesh = (0,
|
|
20766
|
+
const addOrUpdateNodeMesh = (0, import_react38.useCallback)(
|
|
20623
20767
|
(nodeData, position, suppressVersionUpdate = false, forceShowQuestDate = false, isTemplate = false) => {
|
|
20624
20768
|
const {
|
|
20625
20769
|
graphGroup,
|
|
@@ -20661,7 +20805,7 @@ function XViewScene({
|
|
|
20661
20805
|
},
|
|
20662
20806
|
[]
|
|
20663
20807
|
);
|
|
20664
|
-
const handleActivateReshapeLens = (0,
|
|
20808
|
+
const handleActivateReshapeLens = (0, import_react38.useCallback)(
|
|
20665
20809
|
({ type, columns, centerNodeId }) => {
|
|
20666
20810
|
const { nodeObjects, tweenGroup, camera, controls } = stateRef.current;
|
|
20667
20811
|
if (!nodeObjects || !tweenGroup || !camera || !controls) return;
|
|
@@ -20795,7 +20939,7 @@ function XViewScene({
|
|
|
20795
20939
|
},
|
|
20796
20940
|
[]
|
|
20797
20941
|
);
|
|
20798
|
-
const handleActivateQuestLens = (0,
|
|
20942
|
+
const handleActivateQuestLens = (0, import_react38.useCallback)(
|
|
20799
20943
|
({ assigneeId, status: status2, milestoneId }) => {
|
|
20800
20944
|
var _a2;
|
|
20801
20945
|
const { nodeObjects, tweenGroup, graphGroup } = stateRef.current;
|
|
@@ -21017,7 +21161,7 @@ function XViewScene({
|
|
|
21017
21161
|
},
|
|
21018
21162
|
[addOrUpdateNodeMesh]
|
|
21019
21163
|
);
|
|
21020
|
-
(0,
|
|
21164
|
+
(0, import_react38.useEffect)(() => {
|
|
21021
21165
|
if (!isInitialized || !sceneDataRef.current) return;
|
|
21022
21166
|
const currentMount = mountRef.current;
|
|
21023
21167
|
if (!currentMount) return;
|
|
@@ -21046,11 +21190,17 @@ function XViewScene({
|
|
|
21046
21190
|
renderer.outputColorSpace = THREE3.SRGBColorSpace;
|
|
21047
21191
|
renderer.toneMapping = THREE3.ACESFilmicToneMapping;
|
|
21048
21192
|
renderer.toneMappingExposure = 1.2;
|
|
21193
|
+
currentMount.style.touchAction = "none";
|
|
21194
|
+
renderer.domElement.style.touchAction = "none";
|
|
21049
21195
|
currentMount.appendChild(renderer.domElement);
|
|
21050
21196
|
stateRef.current.renderer = renderer;
|
|
21051
21197
|
const controls = new import_OrbitControls.OrbitControls(camera, renderer.domElement);
|
|
21052
21198
|
controls.enableDamping = true;
|
|
21053
21199
|
controls.dampingFactor = 0.05;
|
|
21200
|
+
controls.touches = {
|
|
21201
|
+
ONE: THREE3.TOUCH.ROTATE,
|
|
21202
|
+
TWO: THREE3.TOUCH.DOLLY_PAN
|
|
21203
|
+
};
|
|
21054
21204
|
stateRef.current.controls = controls;
|
|
21055
21205
|
scene.add(new THREE3.AmbientLight(16777215, 0.1));
|
|
21056
21206
|
const directionalLight = new THREE3.DirectionalLight(16777215, 0.2);
|
|
@@ -21275,21 +21425,58 @@ function XViewScene({
|
|
|
21275
21425
|
stateRef.current.dragCandidate = null;
|
|
21276
21426
|
return;
|
|
21277
21427
|
}
|
|
21278
|
-
if (event.button !== 0) return;
|
|
21428
|
+
if (event.button !== 0 && event.pointerType !== "touch") return;
|
|
21279
21429
|
if (picked && !stateRef.current.ancestry.isActive) {
|
|
21280
21430
|
stateRef.current.controls.enabled = false;
|
|
21281
21431
|
}
|
|
21282
21432
|
stateRef.current.pointerDown = {
|
|
21283
21433
|
isDown: true,
|
|
21284
21434
|
x: event.clientX,
|
|
21285
|
-
y: event.clientY
|
|
21435
|
+
y: event.clientY,
|
|
21436
|
+
pointerType: event.pointerType
|
|
21286
21437
|
};
|
|
21287
21438
|
stateRef.current.dragCandidate = picked;
|
|
21439
|
+
if (event.pointerType === "touch" || event.pointerType === "pen") {
|
|
21440
|
+
if (longPressTimeoutRef.current) {
|
|
21441
|
+
clearTimeout(longPressTimeoutRef.current);
|
|
21442
|
+
}
|
|
21443
|
+
isLongPressTriggeredRef.current = false;
|
|
21444
|
+
if (picked) {
|
|
21445
|
+
const touchX = event.clientX;
|
|
21446
|
+
const touchY = event.clientY;
|
|
21447
|
+
longPressTimeoutRef.current = setTimeout(() => {
|
|
21448
|
+
isLongPressTriggeredRef.current = true;
|
|
21449
|
+
if (typeof navigator !== "undefined" && navigator.vibrate) {
|
|
21450
|
+
navigator.vibrate(40);
|
|
21451
|
+
}
|
|
21452
|
+
setContextMenu({
|
|
21453
|
+
visible: true,
|
|
21454
|
+
x: touchX,
|
|
21455
|
+
y: touchY,
|
|
21456
|
+
nodeData: picked.userData
|
|
21457
|
+
});
|
|
21458
|
+
setMultiContextMenu((prev) => ({ ...prev, visible: false }));
|
|
21459
|
+
setRelationshipMenu((prev) => ({ ...prev, visible: false }));
|
|
21460
|
+
setDetailsNode(null);
|
|
21461
|
+
}, 450);
|
|
21462
|
+
}
|
|
21463
|
+
}
|
|
21288
21464
|
}
|
|
21289
21465
|
function onPointerMove(event) {
|
|
21290
21466
|
if (stateRef.current.camera) stateRef.current.camera.layers.enableAll();
|
|
21291
21467
|
if (isFromUiOverlay(event)) return;
|
|
21292
21468
|
setMouseFromEvent(event);
|
|
21469
|
+
if (stateRef.current.pointerDown.isDown) {
|
|
21470
|
+
const dx = event.clientX - stateRef.current.pointerDown.x;
|
|
21471
|
+
const dy = event.clientY - stateRef.current.pointerDown.y;
|
|
21472
|
+
const dist = Math.hypot(dx, dy);
|
|
21473
|
+
if (dist > (x_view_config.DRAG_THRESHOLD_PX || 5)) {
|
|
21474
|
+
if (longPressTimeoutRef.current) {
|
|
21475
|
+
clearTimeout(longPressTimeoutRef.current);
|
|
21476
|
+
longPressTimeoutRef.current = null;
|
|
21477
|
+
}
|
|
21478
|
+
}
|
|
21479
|
+
}
|
|
21293
21480
|
if (stateRef.current.isDragging && stateRef.current.draggedNode) {
|
|
21294
21481
|
const raycaster2 = new THREE3.Raycaster();
|
|
21295
21482
|
raycaster2.setFromCamera(mouse, camera);
|
|
@@ -21332,7 +21519,7 @@ function XViewScene({
|
|
|
21332
21519
|
return;
|
|
21333
21520
|
}
|
|
21334
21521
|
if (stateRef.current.creation.isActive) return;
|
|
21335
|
-
if (stateRef.current.pointerDown.isDown && stateRef.current.dragCandidate) {
|
|
21522
|
+
if (stateRef.current.pointerDown.isDown && stateRef.current.dragCandidate && !isLongPressTriggeredRef.current) {
|
|
21336
21523
|
const dx = event.clientX - stateRef.current.pointerDown.x;
|
|
21337
21524
|
const dy = event.clientY - stateRef.current.pointerDown.y;
|
|
21338
21525
|
if (Math.hypot(dx, dy) > x_view_config.DRAG_THRESHOLD_PX) {
|
|
@@ -21364,6 +21551,17 @@ function XViewScene({
|
|
|
21364
21551
|
async function onPointerUp(event) {
|
|
21365
21552
|
var _a2, _b2, _c2;
|
|
21366
21553
|
if (stateRef.current.camera) stateRef.current.camera.layers.enableAll();
|
|
21554
|
+
if (longPressTimeoutRef.current) {
|
|
21555
|
+
clearTimeout(longPressTimeoutRef.current);
|
|
21556
|
+
longPressTimeoutRef.current = null;
|
|
21557
|
+
}
|
|
21558
|
+
if (isLongPressTriggeredRef.current) {
|
|
21559
|
+
isLongPressTriggeredRef.current = false;
|
|
21560
|
+
stateRef.current.pointerDown.isDown = false;
|
|
21561
|
+
stateRef.current.dragCandidate = null;
|
|
21562
|
+
stateRef.current.controls.enabled = true;
|
|
21563
|
+
return;
|
|
21564
|
+
}
|
|
21367
21565
|
if (isFromUiOverlay(event)) return;
|
|
21368
21566
|
const {
|
|
21369
21567
|
connection,
|
|
@@ -21598,7 +21796,7 @@ function XViewScene({
|
|
|
21598
21796
|
stateRef.current.dragCandidate = null;
|
|
21599
21797
|
return;
|
|
21600
21798
|
}
|
|
21601
|
-
if (event.button === 0 && !stateRef.current.creation.isActive && stateRef.current.pointerDown.isDown) {
|
|
21799
|
+
if ((event.button === 0 || event.pointerType === "touch") && !stateRef.current.creation.isActive && stateRef.current.pointerDown.isDown) {
|
|
21602
21800
|
setMouseFromEvent(event);
|
|
21603
21801
|
const clickedNode = stateRef.current.dragCandidate || tryPickNode();
|
|
21604
21802
|
stateRef.current.dragCandidate = null;
|
|
@@ -21607,6 +21805,9 @@ function XViewScene({
|
|
|
21607
21805
|
stateRef.current.selectedNodes.clear();
|
|
21608
21806
|
}
|
|
21609
21807
|
if (clickedNode) {
|
|
21808
|
+
setContextMenu((prev) => prev.visible ? { ...prev, visible: false } : prev);
|
|
21809
|
+
setMultiContextMenu((prev) => prev.visible ? { ...prev, visible: false } : prev);
|
|
21810
|
+
setRelationshipMenu((prev) => prev.visible ? { ...prev, visible: false } : prev);
|
|
21610
21811
|
setDetailsNode({ ...clickedNode.userData });
|
|
21611
21812
|
setDetailsLink(null);
|
|
21612
21813
|
return;
|
|
@@ -21642,6 +21843,14 @@ function XViewScene({
|
|
|
21642
21843
|
if (stateRef.current.camera) stateRef.current.camera.layers.enableAll();
|
|
21643
21844
|
if (isFromUiOverlay(event)) return;
|
|
21644
21845
|
event.preventDefault();
|
|
21846
|
+
if (longPressTimeoutRef.current) {
|
|
21847
|
+
clearTimeout(longPressTimeoutRef.current);
|
|
21848
|
+
longPressTimeoutRef.current = null;
|
|
21849
|
+
}
|
|
21850
|
+
isLongPressTriggeredRef.current = true;
|
|
21851
|
+
stateRef.current.pointerDown.isDown = false;
|
|
21852
|
+
stateRef.current.dragCandidate = null;
|
|
21853
|
+
setDetailsNode(null);
|
|
21645
21854
|
if (stateRef.current.creation.isActive || stateRef.current.connection.isActive || stateRef.current.relink.isActive)
|
|
21646
21855
|
return;
|
|
21647
21856
|
setMouseFromEvent(event);
|
|
@@ -21942,7 +22151,7 @@ function XViewScene({
|
|
|
21942
22151
|
get_scene_view_data,
|
|
21943
22152
|
save_view_data
|
|
21944
22153
|
]);
|
|
21945
|
-
const handleGhostNodeImageChange = (0,
|
|
22154
|
+
const handleGhostNodeImageChange = (0, import_react38.useCallback)((useImage, imageUrl) => {
|
|
21946
22155
|
const {
|
|
21947
22156
|
node: ghostNode,
|
|
21948
22157
|
line: ghostLine,
|
|
@@ -21990,7 +22199,7 @@ function XViewScene({
|
|
|
21990
22199
|
aura: newGhostNode.getObjectByName("aura")
|
|
21991
22200
|
};
|
|
21992
22201
|
}, []);
|
|
21993
|
-
const handleGhostNodeIntensityChange = (0,
|
|
22202
|
+
const handleGhostNodeIntensityChange = (0, import_react38.useCallback)((newIntensity) => {
|
|
21994
22203
|
const { node: ghostNode, aura: ghostAura } = stateRef.current.ghostElements;
|
|
21995
22204
|
if (!ghostNode) return;
|
|
21996
22205
|
const adjustedIntensity = newIntensity + MIN_VISIBILITY_INTENSITY;
|
|
@@ -22011,7 +22220,7 @@ function XViewScene({
|
|
|
22011
22220
|
ghostAura.material.opacity = Math.min(0.8, newIntensity * 0.15);
|
|
22012
22221
|
}
|
|
22013
22222
|
}, []);
|
|
22014
|
-
const handleDetailNodeIntensityChange = (0,
|
|
22223
|
+
const handleDetailNodeIntensityChange = (0, import_react38.useCallback)(
|
|
22015
22224
|
(nodeId, newIntensity) => {
|
|
22016
22225
|
const mesh = stateRef.current.nodeObjects[String(nodeId)];
|
|
22017
22226
|
if (!mesh) return;
|
|
@@ -22167,7 +22376,7 @@ function XViewScene({
|
|
|
22167
22376
|
mountRef.current.style.cursor = "default";
|
|
22168
22377
|
}
|
|
22169
22378
|
};
|
|
22170
|
-
const handleAncestryTreeUpdate = (0,
|
|
22379
|
+
const handleAncestryTreeUpdate = (0, import_react38.useCallback)((newTree, extraData = null) => {
|
|
22171
22380
|
setAncestryMode((prev) => {
|
|
22172
22381
|
const prevTreeStr = JSON.stringify(prev.tree);
|
|
22173
22382
|
const newTreeStr = JSON.stringify(newTree);
|
|
@@ -22190,7 +22399,7 @@ function XViewScene({
|
|
|
22190
22399
|
};
|
|
22191
22400
|
});
|
|
22192
22401
|
}, []);
|
|
22193
|
-
const actionHandlerContext = (0,
|
|
22402
|
+
const actionHandlerContext = (0, import_react38.useMemo)(
|
|
22194
22403
|
() => {
|
|
22195
22404
|
var _a2;
|
|
22196
22405
|
return {
|
|
@@ -22302,7 +22511,7 @@ function XViewScene({
|
|
|
22302
22511
|
const handleStartVersioning = (nodeData) => {
|
|
22303
22512
|
userActionHandlers.handleStartVersioning(actionHandlerContext, nodeData);
|
|
22304
22513
|
};
|
|
22305
|
-
const handleStartQuestQuick = (0,
|
|
22514
|
+
const handleStartQuestQuick = (0, import_react38.useCallback)(
|
|
22306
22515
|
(questNode) => {
|
|
22307
22516
|
var _a2, _b2, _c2, _d2, _e2, _f2;
|
|
22308
22517
|
if (!questNode || !actionHandlerContext) return;
|
|
@@ -22384,7 +22593,7 @@ function XViewScene({
|
|
|
22384
22593
|
},
|
|
22385
22594
|
[session, actionHandlerContext]
|
|
22386
22595
|
);
|
|
22387
|
-
const handleFinishQuestQuick = (0,
|
|
22596
|
+
const handleFinishQuestQuick = (0, import_react38.useCallback)(
|
|
22388
22597
|
(questNode) => {
|
|
22389
22598
|
var _a2, _b2, _c2, _d2, _e2, _f2, _g2;
|
|
22390
22599
|
if (!questNode || !actionHandlerContext) return;
|
|
@@ -22534,7 +22743,7 @@ function XViewScene({
|
|
|
22534
22743
|
},
|
|
22535
22744
|
[session, actionHandlerContext, viewMembers, detailsNode]
|
|
22536
22745
|
);
|
|
22537
|
-
const handleCancelQuest = (0,
|
|
22746
|
+
const handleCancelQuest = (0, import_react38.useCallback)(() => {
|
|
22538
22747
|
const { graphGroup, ghostElements } = stateRef.current;
|
|
22539
22748
|
if (ghostElements.node && graphGroup) {
|
|
22540
22749
|
if (ghostElements.node.userData.labelObject) {
|
|
@@ -22556,7 +22765,7 @@ function XViewScene({
|
|
|
22556
22765
|
stateRef.current.ghostElements = { node: null, line: null, aura: null };
|
|
22557
22766
|
setQuestMode({ isActive: false });
|
|
22558
22767
|
}, []);
|
|
22559
|
-
const handleCancelProcess = (0,
|
|
22768
|
+
const handleCancelProcess = (0, import_react38.useCallback)(() => {
|
|
22560
22769
|
const { graphGroup, ghostElements } = stateRef.current;
|
|
22561
22770
|
if (ghostElements.node && graphGroup) {
|
|
22562
22771
|
if (ghostElements.node.userData.labelObject) {
|
|
@@ -22909,7 +23118,7 @@ function XViewScene({
|
|
|
22909
23118
|
alert("Ocorreu um erro ao criar o Processo.");
|
|
22910
23119
|
}
|
|
22911
23120
|
};
|
|
22912
|
-
const handleClearAncestryVisuals = (0,
|
|
23121
|
+
const handleClearAncestryVisuals = (0, import_react38.useCallback)((ancestryId) => {
|
|
22913
23122
|
const { renderedAncestries, ancestryGroup } = stateRef.current;
|
|
22914
23123
|
const renderIndex = renderedAncestries.findIndex(
|
|
22915
23124
|
(a) => String(a.id) === String(ancestryId)
|
|
@@ -22927,7 +23136,7 @@ function XViewScene({
|
|
|
22927
23136
|
);
|
|
22928
23137
|
}
|
|
22929
23138
|
}, []);
|
|
22930
|
-
const handleRenderAncestry = (0,
|
|
23139
|
+
const handleRenderAncestry = (0, import_react38.useCallback)(
|
|
22931
23140
|
async (ancestryObject, allowedSectionIds = null, activeSectionIdForFocus = null, baseRotation = 0, forceReprocess = true) => {
|
|
22932
23141
|
setContextMenu(
|
|
22933
23142
|
(prev) => prev.visible ? { ...prev, visible: false } : prev
|
|
@@ -23421,7 +23630,7 @@ function XViewScene({
|
|
|
23421
23630
|
ancestryMode.isActive
|
|
23422
23631
|
]
|
|
23423
23632
|
);
|
|
23424
|
-
const handleRenderAbstractionTree = (0,
|
|
23633
|
+
const handleRenderAbstractionTree = (0, import_react38.useCallback)(
|
|
23425
23634
|
(ancestryObject, targetNodeId = null, focusNodeId2 = null) => {
|
|
23426
23635
|
setContextMenu(
|
|
23427
23636
|
(prev) => prev.visible ? { ...prev, visible: false } : prev
|
|
@@ -23530,7 +23739,7 @@ function XViewScene({
|
|
|
23530
23739
|
handleClearAncestryVisuals
|
|
23531
23740
|
]
|
|
23532
23741
|
);
|
|
23533
|
-
const handleReadModeBranchNav = (0,
|
|
23742
|
+
const handleReadModeBranchNav = (0, import_react38.useCallback)(
|
|
23534
23743
|
(nodeId, action, direction = "right") => {
|
|
23535
23744
|
const { ancestry, branchStack } = readingMode;
|
|
23536
23745
|
if (!ancestry || !ancestry.tree) return;
|
|
@@ -23708,13 +23917,13 @@ function XViewScene({
|
|
|
23708
23917
|
},
|
|
23709
23918
|
[readingMode, handleRenderAncestry, buildFullAncestryTree, tweenToTarget]
|
|
23710
23919
|
);
|
|
23711
|
-
const handleReadModeHighlight = (0,
|
|
23920
|
+
const handleReadModeHighlight = (0, import_react38.useCallback)((nodeId) => {
|
|
23712
23921
|
if (stateRef.current.highlightedNodeId !== nodeId) {
|
|
23713
23922
|
stateRef.current.highlightedNodeId = nodeId;
|
|
23714
23923
|
}
|
|
23715
23924
|
setHighlightedNodeId(nodeId);
|
|
23716
23925
|
}, []);
|
|
23717
|
-
const activeNodeBranches = (0,
|
|
23926
|
+
const activeNodeBranches = (0, import_react38.useMemo)(() => {
|
|
23718
23927
|
if (!highlightedNodeId || !readingMode.ancestry || !readingMode.ancestry.tree)
|
|
23719
23928
|
return null;
|
|
23720
23929
|
const fullTree = buildFullAncestryTree(
|
|
@@ -23758,7 +23967,7 @@ function XViewScene({
|
|
|
23758
23967
|
readingMode.branchStack,
|
|
23759
23968
|
ancestryDataRef.current
|
|
23760
23969
|
]);
|
|
23761
|
-
const backNavigationInfo = (0,
|
|
23970
|
+
const backNavigationInfo = (0, import_react38.useMemo)(() => {
|
|
23762
23971
|
const { branchStack } = readingMode;
|
|
23763
23972
|
if (!branchStack || branchStack.length === 0) return null;
|
|
23764
23973
|
const lastStep = branchStack[branchStack.length - 1];
|
|
@@ -23769,7 +23978,7 @@ function XViewScene({
|
|
|
23769
23978
|
name: "Voltar para anterior"
|
|
23770
23979
|
};
|
|
23771
23980
|
}, [readingMode.branchStack]);
|
|
23772
|
-
const getReadModeDisplayContext = (0,
|
|
23981
|
+
const getReadModeDisplayContext = (0, import_react38.useMemo)(() => {
|
|
23773
23982
|
const { ancestry, branchStack } = readingMode;
|
|
23774
23983
|
if (!ancestry) return null;
|
|
23775
23984
|
if (branchStack.length === 0) {
|
|
@@ -23812,7 +24021,7 @@ function XViewScene({
|
|
|
23812
24021
|
customProperties: branchProps
|
|
23813
24022
|
};
|
|
23814
24023
|
}, [readingMode, buildFullAncestryTree, ancestryDataRef.current]);
|
|
23815
|
-
const readModeAbstractionTree = (0,
|
|
24024
|
+
const readModeAbstractionTree = (0, import_react38.useMemo)(() => {
|
|
23816
24025
|
if (!readingMode.isActive || !readingMode.ancestry || !readingMode.ancestry.abstraction_tree) {
|
|
23817
24026
|
return null;
|
|
23818
24027
|
}
|
|
@@ -23831,7 +24040,7 @@ function XViewScene({
|
|
|
23831
24040
|
buildFullAncestryTree,
|
|
23832
24041
|
sceneVersion
|
|
23833
24042
|
]);
|
|
23834
|
-
const handleStartReadingAncestry = (0,
|
|
24043
|
+
const handleStartReadingAncestry = (0, import_react38.useCallback)(
|
|
23835
24044
|
async (ancestryObject, renderMode = "full") => {
|
|
23836
24045
|
setContextMenu(
|
|
23837
24046
|
(prev) => prev.visible ? { ...prev, visible: false } : prev
|
|
@@ -23874,7 +24083,7 @@ function XViewScene({
|
|
|
23874
24083
|
},
|
|
23875
24084
|
[handleRenderAncestry, handleRenderAbstractionTree]
|
|
23876
24085
|
);
|
|
23877
|
-
const handleReadModeSectionChange = (0,
|
|
24086
|
+
const handleReadModeSectionChange = (0, import_react38.useCallback)(
|
|
23878
24087
|
(activeSectionId) => {
|
|
23879
24088
|
const { ancestry, branchStack } = readingMode;
|
|
23880
24089
|
if (!ancestry || !readingMode.isActive) return;
|
|
@@ -23959,10 +24168,10 @@ function XViewScene({
|
|
|
23959
24168
|
ancestryDataRef.current
|
|
23960
24169
|
]
|
|
23961
24170
|
);
|
|
23962
|
-
const handleCloseReadMode = (0,
|
|
24171
|
+
const handleCloseReadMode = (0, import_react38.useCallback)(() => {
|
|
23963
24172
|
setReadingMode({ isActive: false, ancestry: null, branchStack: [] });
|
|
23964
24173
|
}, []);
|
|
23965
|
-
const handleAncestrySectionChange = (0,
|
|
24174
|
+
const handleAncestrySectionChange = (0, import_react38.useCallback)(
|
|
23966
24175
|
(activeSectionId, ancestryOverride = null, rotation = 0) => {
|
|
23967
24176
|
var _a2, _b2;
|
|
23968
24177
|
const currentMode = stateRef.current.ancestry;
|
|
@@ -24024,7 +24233,7 @@ function XViewScene({
|
|
|
24024
24233
|
},
|
|
24025
24234
|
[handleRenderAncestry]
|
|
24026
24235
|
);
|
|
24027
|
-
const handleEditAncestry = (0,
|
|
24236
|
+
const handleEditAncestry = (0, import_react38.useCallback)(
|
|
24028
24237
|
async (ancestryObject) => {
|
|
24029
24238
|
setContextMenu(
|
|
24030
24239
|
(prev) => prev.visible ? { ...prev, visible: false } : prev
|
|
@@ -24079,7 +24288,7 @@ function XViewScene({
|
|
|
24079
24288
|
const handleSelectAncestryParent = (nodeId) => {
|
|
24080
24289
|
setAncestryMode((prev) => ({ ...prev, selectedParentId: nodeId }));
|
|
24081
24290
|
};
|
|
24082
|
-
const handleRemoveFromAncestry = (0,
|
|
24291
|
+
const handleRemoveFromAncestry = (0, import_react38.useCallback)((pathToRemove) => {
|
|
24083
24292
|
if (!Array.isArray(pathToRemove) || pathToRemove.length === 0) {
|
|
24084
24293
|
console.warn("Tentativa de remover a raiz ou caminho inv\xE1lido.");
|
|
24085
24294
|
return;
|
|
@@ -24104,7 +24313,7 @@ function XViewScene({
|
|
|
24104
24313
|
return { ...prev, tree: newTree };
|
|
24105
24314
|
});
|
|
24106
24315
|
}, []);
|
|
24107
|
-
const handleSaveAncestry = (0,
|
|
24316
|
+
const handleSaveAncestry = (0, import_react38.useCallback)(
|
|
24108
24317
|
async (ancestryName, ancestryDescription, ancestrySections, keepOpen = false, treeOverride = null, ancestryCustomProps = {}) => {
|
|
24109
24318
|
var _a2;
|
|
24110
24319
|
const treeToUse = treeOverride || ancestryMode.tree;
|
|
@@ -24372,7 +24581,7 @@ function XViewScene({
|
|
|
24372
24581
|
});
|
|
24373
24582
|
setEditingAncestryRel({ visible: false, data: null, path: null });
|
|
24374
24583
|
};
|
|
24375
|
-
const handleDeleteAncestry = (0,
|
|
24584
|
+
const handleDeleteAncestry = (0, import_react38.useCallback)(
|
|
24376
24585
|
async (ancestryIdToDelete) => {
|
|
24377
24586
|
if (!ancestryIdToDelete) {
|
|
24378
24587
|
alert("ID da ancestralidade n\xE3o encontrado.");
|
|
@@ -24506,19 +24715,19 @@ function XViewScene({
|
|
|
24506
24715
|
},
|
|
24507
24716
|
[save_view_data, delete_file_action]
|
|
24508
24717
|
);
|
|
24509
|
-
const handleOpenBoards = (0,
|
|
24718
|
+
const handleOpenBoards = (0, import_react38.useCallback)(() => {
|
|
24510
24719
|
setIsBoardsOpen(true);
|
|
24511
24720
|
}, []);
|
|
24512
|
-
const allAvailableNodes = (0,
|
|
24721
|
+
const allAvailableNodes = (0, import_react38.useMemo)(() => {
|
|
24513
24722
|
if (!parentDataRef.current) return [];
|
|
24514
24723
|
return Object.values(parentDataRef.current).flatMap(
|
|
24515
24724
|
(fileData) => fileData.nodes || []
|
|
24516
24725
|
);
|
|
24517
24726
|
}, [sceneVersion, isInitialized]);
|
|
24518
|
-
const allAvailableAncestries = (0,
|
|
24727
|
+
const allAvailableAncestries = (0, import_react38.useMemo)(() => {
|
|
24519
24728
|
return ancestryDataRef.current || [];
|
|
24520
24729
|
}, [sceneVersion, isInitialized]);
|
|
24521
|
-
const handleFocusNode = (0,
|
|
24730
|
+
const handleFocusNode = (0, import_react38.useCallback)(
|
|
24522
24731
|
(nodeData) => {
|
|
24523
24732
|
var _a2;
|
|
24524
24733
|
if (!nodeData) return;
|
|
@@ -24534,7 +24743,7 @@ function XViewScene({
|
|
|
24534
24743
|
},
|
|
24535
24744
|
[tweenToTarget]
|
|
24536
24745
|
);
|
|
24537
|
-
const handleOpenReference = (0,
|
|
24746
|
+
const handleOpenReference = (0, import_react38.useCallback)(
|
|
24538
24747
|
(referenceData) => {
|
|
24539
24748
|
const { type, id } = referenceData;
|
|
24540
24749
|
if (type === "node") {
|
|
@@ -24570,7 +24779,7 @@ function XViewScene({
|
|
|
24570
24779
|
handleFocusNode
|
|
24571
24780
|
]
|
|
24572
24781
|
);
|
|
24573
|
-
const handleSelectAncestryFromBoard = (0,
|
|
24782
|
+
const handleSelectAncestryFromBoard = (0, import_react38.useCallback)(
|
|
24574
24783
|
(item) => {
|
|
24575
24784
|
setIsBoardsOpen(false);
|
|
24576
24785
|
setIsSidebarOpen(false);
|
|
@@ -24582,7 +24791,7 @@ function XViewScene({
|
|
|
24582
24791
|
},
|
|
24583
24792
|
[handleStartReadingAncestry, handleOpenReference]
|
|
24584
24793
|
);
|
|
24585
|
-
const handleSaveBoards = (0,
|
|
24794
|
+
const handleSaveBoards = (0, import_react38.useCallback)(
|
|
24586
24795
|
async (boardItems2) => {
|
|
24587
24796
|
if (!sceneConfigId || !viewParams || !session) return;
|
|
24588
24797
|
const sceneType = (viewParams.type || "").toLowerCase().includes("database") ? "database" : "view";
|
|
@@ -24596,7 +24805,7 @@ function XViewScene({
|
|
|
24596
24805
|
},
|
|
24597
24806
|
[sceneConfigId, viewParams, session, save_boards_action, ownerId]
|
|
24598
24807
|
);
|
|
24599
|
-
const existingNodeTypes = (0,
|
|
24808
|
+
const existingNodeTypes = (0, import_react38.useMemo)(() => {
|
|
24600
24809
|
if (!parentDataRef.current) {
|
|
24601
24810
|
return [];
|
|
24602
24811
|
}
|
|
@@ -24608,7 +24817,7 @@ function XViewScene({
|
|
|
24608
24817
|
).filter((t) => Boolean(t) && String(t).toLowerCase() !== "quest");
|
|
24609
24818
|
return [...new Set(allTypes)];
|
|
24610
24819
|
}, [parentDataRef.current, sceneVersion]);
|
|
24611
|
-
const searchableDbNodes = (0,
|
|
24820
|
+
const searchableDbNodes = (0, import_react38.useMemo)(() => {
|
|
24612
24821
|
if (!parentDataRef.current) {
|
|
24613
24822
|
return [];
|
|
24614
24823
|
}
|
|
@@ -24623,7 +24832,7 @@ function XViewScene({
|
|
|
24623
24832
|
return !((_a2 = node.version_node) == null ? void 0 : _a2.is_version);
|
|
24624
24833
|
});
|
|
24625
24834
|
}, [parentDataRef.current, sceneVersion]);
|
|
24626
|
-
const handleAddExistingNode = (0,
|
|
24835
|
+
const handleAddExistingNode = (0, import_react38.useCallback)(
|
|
24627
24836
|
(nodeId) => {
|
|
24628
24837
|
return userActionHandlers.handleAddExistingNodeById(
|
|
24629
24838
|
actionHandlerContext,
|
|
@@ -24632,7 +24841,7 @@ function XViewScene({
|
|
|
24632
24841
|
},
|
|
24633
24842
|
[actionHandlerContext]
|
|
24634
24843
|
);
|
|
24635
|
-
const handleUpdateMilestones = (0,
|
|
24844
|
+
const handleUpdateMilestones = (0, import_react38.useCallback)(
|
|
24636
24845
|
async (newMilestones) => {
|
|
24637
24846
|
var _a2, _b2, _c2;
|
|
24638
24847
|
if (!sceneDataRef.current) return;
|
|
@@ -24659,7 +24868,7 @@ function XViewScene({
|
|
|
24659
24868
|
},
|
|
24660
24869
|
[sceneConfigId, sceneSaveUrl, save_view_data, viewParams == null ? void 0 : viewParams.type]
|
|
24661
24870
|
);
|
|
24662
|
-
const handleSaveCurrentView = (0,
|
|
24871
|
+
const handleSaveCurrentView = (0, import_react38.useCallback)(async () => {
|
|
24663
24872
|
var _a2;
|
|
24664
24873
|
const { nodeObjects, allLinks } = stateRef.current;
|
|
24665
24874
|
if (!nodeObjects || !allLinks || !sceneSaveUrl || !parentDataRef.current) {
|
|
@@ -24698,13 +24907,13 @@ function XViewScene({
|
|
|
24698
24907
|
console.error("Erro na chamada de save_view_data:", error);
|
|
24699
24908
|
}
|
|
24700
24909
|
}, [sceneSaveUrl, save_view_data, sceneConfigId, viewParams == null ? void 0 : viewParams.type]);
|
|
24701
|
-
const handleToggleAncestryAddMode = (0,
|
|
24910
|
+
const handleToggleAncestryAddMode = (0, import_react38.useCallback)(() => {
|
|
24702
24911
|
setAncestryMode((prev) => ({
|
|
24703
24912
|
...prev,
|
|
24704
24913
|
isAddingNodes: !prev.isAddingNodes
|
|
24705
24914
|
}));
|
|
24706
24915
|
}, []);
|
|
24707
|
-
const availableDatasets = (0,
|
|
24916
|
+
const availableDatasets = (0, import_react38.useMemo)(() => {
|
|
24708
24917
|
if (!sceneDataRef.current || !parentDataRef.current) return [];
|
|
24709
24918
|
return sceneDataRef.current.parent_dbs.map((db) => {
|
|
24710
24919
|
var _a2;
|
|
@@ -24718,7 +24927,7 @@ function XViewScene({
|
|
|
24718
24927
|
String(creationMode.sourceNodeData.id)
|
|
24719
24928
|
)) == null ? void 0 : _b.parentFileId : null;
|
|
24720
24929
|
const detailsNodeDatasetInfo = detailsNode ? stateRef.current.nodeIdToParentFileMap.get(String(detailsNode.id)) : null;
|
|
24721
|
-
(0,
|
|
24930
|
+
(0, import_react38.useEffect)(() => {
|
|
24722
24931
|
if (!isInitialized || hasFocusedInitial) return;
|
|
24723
24932
|
const nodeObjects = stateRef.current.nodeObjects || {};
|
|
24724
24933
|
if (focusNodeId) {
|
|
@@ -24765,7 +24974,7 @@ function XViewScene({
|
|
|
24765
24974
|
hasFocusedInitial,
|
|
24766
24975
|
tweenToTarget
|
|
24767
24976
|
]);
|
|
24768
|
-
(0,
|
|
24977
|
+
(0, import_react38.useEffect)(() => {
|
|
24769
24978
|
if (isInitialized && focusAncestryId && !hasOpenedInitialAncestry) {
|
|
24770
24979
|
const ancestries = ancestryDataRef.current || [];
|
|
24771
24980
|
const targetAncestry = ancestries.find(
|
|
@@ -24790,7 +24999,7 @@ function XViewScene({
|
|
|
24790
24999
|
hasOpenedInitialAncestry,
|
|
24791
25000
|
handleStartReadingAncestry
|
|
24792
25001
|
]);
|
|
24793
|
-
(0,
|
|
25002
|
+
(0, import_react38.useEffect)(() => {
|
|
24794
25003
|
function handleKeyDown(event) {
|
|
24795
25004
|
var _a2, _b2, _c2, _d2, _e2, _f2;
|
|
24796
25005
|
const context = actionHandlerContext;
|
|
@@ -25013,7 +25222,7 @@ function XViewScene({
|
|
|
25013
25222
|
// <-- handleCancelQuest adicionado aqui
|
|
25014
25223
|
]);
|
|
25015
25224
|
if (isLoading || status === "loading" || permissionStatus === "loading") {
|
|
25016
|
-
return /* @__PURE__ */
|
|
25225
|
+
return /* @__PURE__ */ import_react38.default.createElement(LoadingScreen, null);
|
|
25017
25226
|
}
|
|
25018
25227
|
const overlayHiddenStyle = questTreeMode.isActive || processTreeMode.isActive ? {
|
|
25019
25228
|
opacity: 0,
|
|
@@ -25022,7 +25231,7 @@ function XViewScene({
|
|
|
25022
25231
|
transition: "all 300ms ease-in-out"
|
|
25023
25232
|
} : {};
|
|
25024
25233
|
if (permissionStatus === "corrupted") {
|
|
25025
|
-
return /* @__PURE__ */
|
|
25234
|
+
return /* @__PURE__ */ import_react38.default.createElement("div", { className: "flex flex-col items-center justify-center min-h-screen w-full bg-slate-950 text-white" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "bg-slate-900/50 p-8 rounded-2xl border border-slate-800 shadow-2xl text-center max-w-md animate-fade-in" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "mb-4 text-amber-500" }, /* @__PURE__ */ import_react38.default.createElement(
|
|
25026
25235
|
"svg",
|
|
25027
25236
|
{
|
|
25028
25237
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -25032,7 +25241,7 @@ function XViewScene({
|
|
|
25032
25241
|
stroke: "currentColor",
|
|
25033
25242
|
className: "w-16 h-16 mx-auto"
|
|
25034
25243
|
},
|
|
25035
|
-
/* @__PURE__ */
|
|
25244
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25036
25245
|
"path",
|
|
25037
25246
|
{
|
|
25038
25247
|
strokeLinecap: "round",
|
|
@@ -25040,13 +25249,13 @@ function XViewScene({
|
|
|
25040
25249
|
d: "M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"
|
|
25041
25250
|
}
|
|
25042
25251
|
)
|
|
25043
|
-
)), /* @__PURE__ */
|
|
25252
|
+
)), /* @__PURE__ */ import_react38.default.createElement("h2", { className: "text-2xl font-bold mb-2" }, "Link Inv\xE1lido"), /* @__PURE__ */ import_react38.default.createElement("p", { className: "text-slate-400 mb-6" }, "O link de acesso a este cen\xE1rio est\xE1 corrompido, incompleto ou foi alterado de forma incorreta. Por favor, verifique a URL ou retorne ao dashboard."), /* @__PURE__ */ import_react38.default.createElement(
|
|
25044
25253
|
"button",
|
|
25045
25254
|
{
|
|
25046
25255
|
onClick: handleNavigateBack,
|
|
25047
25256
|
className: "flex items-center justify-center gap-2 w-full py-3 px-4 bg-blue-600 hover:bg-blue-700 text-white rounded-lg transition-colors font-medium cursor-pointer"
|
|
25048
25257
|
},
|
|
25049
|
-
/* @__PURE__ */
|
|
25258
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25050
25259
|
"svg",
|
|
25051
25260
|
{
|
|
25052
25261
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -25056,7 +25265,7 @@ function XViewScene({
|
|
|
25056
25265
|
stroke: "currentColor",
|
|
25057
25266
|
className: "w-5 h-5"
|
|
25058
25267
|
},
|
|
25059
|
-
/* @__PURE__ */
|
|
25268
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25060
25269
|
"path",
|
|
25061
25270
|
{
|
|
25062
25271
|
strokeLinecap: "round",
|
|
@@ -25069,7 +25278,7 @@ function XViewScene({
|
|
|
25069
25278
|
)));
|
|
25070
25279
|
}
|
|
25071
25280
|
if (permissionStatus === "denied") {
|
|
25072
|
-
return /* @__PURE__ */
|
|
25281
|
+
return /* @__PURE__ */ import_react38.default.createElement("div", { className: "flex flex-col items-center justify-center min-h-screen w-full bg-slate-950 text-white" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "bg-slate-900/50 p-8 rounded-2xl border border-slate-800 shadow-2xl text-center max-w-md" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "mb-4 text-red-500" }, /* @__PURE__ */ import_react38.default.createElement(
|
|
25073
25282
|
"svg",
|
|
25074
25283
|
{
|
|
25075
25284
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -25079,7 +25288,7 @@ function XViewScene({
|
|
|
25079
25288
|
stroke: "currentColor",
|
|
25080
25289
|
className: "w-16 h-16 mx-auto"
|
|
25081
25290
|
},
|
|
25082
|
-
/* @__PURE__ */
|
|
25291
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25083
25292
|
"path",
|
|
25084
25293
|
{
|
|
25085
25294
|
strokeLinecap: "round",
|
|
@@ -25087,13 +25296,13 @@ function XViewScene({
|
|
|
25087
25296
|
d: "M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z"
|
|
25088
25297
|
}
|
|
25089
25298
|
)
|
|
25090
|
-
)), /* @__PURE__ */
|
|
25299
|
+
)), /* @__PURE__ */ import_react38.default.createElement("h2", { className: "text-2xl font-bold mb-2" }, "Acesso Negado"), /* @__PURE__ */ import_react38.default.createElement("p", { className: "text-slate-400 mb-6" }, "Voc\xEA n\xE3o tem permiss\xE3o para acessar este conte\xFAdo. Solicite acesso ao propriet\xE1rio ou verifique se est\xE1 na conta correta."), /* @__PURE__ */ import_react38.default.createElement(
|
|
25091
25300
|
"button",
|
|
25092
25301
|
{
|
|
25093
25302
|
onClick: handleNavigateBack,
|
|
25094
25303
|
className: "flex items-center justify-center gap-2 w-full py-3 px-4 bg-blue-600 hover:bg-blue-700 text-white rounded-lg transition-colors font-medium"
|
|
25095
25304
|
},
|
|
25096
|
-
/* @__PURE__ */
|
|
25305
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25097
25306
|
"svg",
|
|
25098
25307
|
{
|
|
25099
25308
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -25103,7 +25312,7 @@ function XViewScene({
|
|
|
25103
25312
|
stroke: "currentColor",
|
|
25104
25313
|
className: "w-5 h-5"
|
|
25105
25314
|
},
|
|
25106
|
-
/* @__PURE__ */
|
|
25315
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25107
25316
|
"path",
|
|
25108
25317
|
{
|
|
25109
25318
|
strokeLinecap: "round",
|
|
@@ -25115,7 +25324,7 @@ function XViewScene({
|
|
|
25115
25324
|
"Voltar para o X.View"
|
|
25116
25325
|
)));
|
|
25117
25326
|
}
|
|
25118
|
-
return /* @__PURE__ */
|
|
25327
|
+
return /* @__PURE__ */ import_react38.default.createElement(
|
|
25119
25328
|
"div",
|
|
25120
25329
|
{
|
|
25121
25330
|
ref: mountRef,
|
|
@@ -25127,7 +25336,7 @@ function XViewScene({
|
|
|
25127
25336
|
cursor: isProcessing ? "progress" : stateRef.current.connection.isActive || stateRef.current.relink.isActive || ancestryMode.isActive ? "crosshair" : creationMode.isActive ? "default" : "grab"
|
|
25128
25337
|
}
|
|
25129
25338
|
},
|
|
25130
|
-
userPermissionRole !== "link_viewer" && /* @__PURE__ */
|
|
25339
|
+
userPermissionRole !== "link_viewer" && /* @__PURE__ */ import_react38.default.createElement(
|
|
25131
25340
|
XViewSidebar,
|
|
25132
25341
|
{
|
|
25133
25342
|
dbNodes: searchableDbNodes,
|
|
@@ -25156,7 +25365,7 @@ function XViewScene({
|
|
|
25156
25365
|
viewMembers
|
|
25157
25366
|
}
|
|
25158
25367
|
),
|
|
25159
|
-
creationMode.isActive && /* @__PURE__ */
|
|
25368
|
+
creationMode.isActive && /* @__PURE__ */ import_react38.default.createElement(
|
|
25160
25369
|
InSceneCreationForm,
|
|
25161
25370
|
{
|
|
25162
25371
|
onSave: (data) => userActionHandlers.handleSaveNode(actionHandlerContext, data),
|
|
@@ -25191,7 +25400,7 @@ function XViewScene({
|
|
|
25191
25400
|
view_google_folder_id: (_h = sceneDataRef.current) == null ? void 0 : _h.view_google_folder_id
|
|
25192
25401
|
}
|
|
25193
25402
|
),
|
|
25194
|
-
versionMode.isActive && /* @__PURE__ */
|
|
25403
|
+
versionMode.isActive && /* @__PURE__ */ import_react38.default.createElement(
|
|
25195
25404
|
InSceneVersionForm,
|
|
25196
25405
|
{
|
|
25197
25406
|
onSave: (data) => userActionHandlers.handleSaveVersionNode(actionHandlerContext, data),
|
|
@@ -25218,7 +25427,7 @@ function XViewScene({
|
|
|
25218
25427
|
availableAncestries: allAvailableAncestries
|
|
25219
25428
|
}
|
|
25220
25429
|
),
|
|
25221
|
-
questTreeMode.isActive && /* @__PURE__ */
|
|
25430
|
+
questTreeMode.isActive && /* @__PURE__ */ import_react38.default.createElement(
|
|
25222
25431
|
CreateQuestTreePanel,
|
|
25223
25432
|
{
|
|
25224
25433
|
questTreeMode,
|
|
@@ -25227,7 +25436,7 @@ function XViewScene({
|
|
|
25227
25436
|
onClose: handleCloseQuestTree
|
|
25228
25437
|
}
|
|
25229
25438
|
),
|
|
25230
|
-
processTreeMode.isActive && /* @__PURE__ */
|
|
25439
|
+
processTreeMode.isActive && /* @__PURE__ */ import_react38.default.createElement(
|
|
25231
25440
|
CreateProcessTreePanel,
|
|
25232
25441
|
{
|
|
25233
25442
|
processTreeMode,
|
|
@@ -25236,7 +25445,7 @@ function XViewScene({
|
|
|
25236
25445
|
onClose: handleCloseProcessTree
|
|
25237
25446
|
}
|
|
25238
25447
|
),
|
|
25239
|
-
questMode.isActive && /* @__PURE__ */
|
|
25448
|
+
questMode.isActive && /* @__PURE__ */ import_react38.default.createElement(
|
|
25240
25449
|
InSceneQuestForm,
|
|
25241
25450
|
{
|
|
25242
25451
|
onSave: (data) => handleSaveQuestNode(actionHandlerContext, data),
|
|
@@ -25267,7 +25476,7 @@ function XViewScene({
|
|
|
25267
25476
|
view_google_folder_id: (_m = sceneDataRef.current) == null ? void 0 : _m.view_google_folder_id
|
|
25268
25477
|
}
|
|
25269
25478
|
),
|
|
25270
|
-
processMode.isActive && /* @__PURE__ */
|
|
25479
|
+
processMode.isActive && /* @__PURE__ */ import_react38.default.createElement(
|
|
25271
25480
|
InSceneProcessForm,
|
|
25272
25481
|
{
|
|
25273
25482
|
onSave: (data) => handleSaveProcessNode(actionHandlerContext, data),
|
|
@@ -25294,7 +25503,7 @@ function XViewScene({
|
|
|
25294
25503
|
view_google_folder_id: (_n = sceneDataRef.current) == null ? void 0 : _n.view_google_folder_id
|
|
25295
25504
|
}
|
|
25296
25505
|
),
|
|
25297
|
-
readingMode.isActive && readingMode.ancestry && /* @__PURE__ */
|
|
25506
|
+
readingMode.isActive && readingMode.ancestry && /* @__PURE__ */ import_react38.default.createElement(
|
|
25298
25507
|
"div",
|
|
25299
25508
|
{
|
|
25300
25509
|
className: `ui-overlay absolute group rounded-2xl border border-white/10 bg-slate-950/70 backdrop-blur-xl shadow-[0_20px_80px_rgba(0,0,0,0.6)] ring-1 ring-white/10 text-white overflow-hidden flex flex-col ${isReadModeResizing ? "transition-none" : "transition-all duration-300 ease-out"}`,
|
|
@@ -25307,7 +25516,7 @@ function XViewScene({
|
|
|
25307
25516
|
maxWidth: "92vw"
|
|
25308
25517
|
}
|
|
25309
25518
|
},
|
|
25310
|
-
/* @__PURE__ */
|
|
25519
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25311
25520
|
"div",
|
|
25312
25521
|
{
|
|
25313
25522
|
onPointerDown: (e) => {
|
|
@@ -25318,7 +25527,7 @@ function XViewScene({
|
|
|
25318
25527
|
title: "Arraste para redimensionar"
|
|
25319
25528
|
}
|
|
25320
25529
|
),
|
|
25321
|
-
/* @__PURE__ */
|
|
25530
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25322
25531
|
DescriptionReadModePanel,
|
|
25323
25532
|
{
|
|
25324
25533
|
key: readingMode.branchStack.length > 0 ? readingMode.branchStack[readingMode.branchStack.length - 1].branchId : readingMode.ancestry.ancestry_id,
|
|
@@ -25353,7 +25562,7 @@ function XViewScene({
|
|
|
25353
25562
|
}
|
|
25354
25563
|
)
|
|
25355
25564
|
),
|
|
25356
|
-
ancestryMode.isActive && ancestryMode.tree && /* @__PURE__ */
|
|
25565
|
+
ancestryMode.isActive && ancestryMode.tree && /* @__PURE__ */ import_react38.default.createElement(
|
|
25357
25566
|
CreateAncestryPanel,
|
|
25358
25567
|
{
|
|
25359
25568
|
ancestryMode,
|
|
@@ -25389,7 +25598,7 @@ function XViewScene({
|
|
|
25389
25598
|
onRenderAbstractionTree: (data, targetId) => handleRenderAbstractionTree(data, targetId)
|
|
25390
25599
|
}
|
|
25391
25600
|
),
|
|
25392
|
-
editingAncestryRel.visible && /* @__PURE__ */
|
|
25601
|
+
editingAncestryRel.visible && /* @__PURE__ */ import_react38.default.createElement(
|
|
25393
25602
|
AncestryRelationshipPanel,
|
|
25394
25603
|
{
|
|
25395
25604
|
data: editingAncestryRel.data,
|
|
@@ -25403,8 +25612,8 @@ function XViewScene({
|
|
|
25403
25612
|
onUploadFile: upload_file_action
|
|
25404
25613
|
}
|
|
25405
25614
|
),
|
|
25406
|
-
isProcessing && /* @__PURE__ */
|
|
25407
|
-
detailsNode && detailsNode.is_quest && /* @__PURE__ */
|
|
25615
|
+
isProcessing && /* @__PURE__ */ import_react38.default.createElement("div", { className: "fixed bottom-8 right-8 z-[2000] flex items-center gap-3 px-4 py-2 bg-slate-900/80 backdrop-blur-md border border-white/10 rounded-full shadow-2xl animate-pulse" }, /* @__PURE__ */ import_react38.default.createElement("div", { className: "w-4 h-4 border-2 border-indigo-500 border-t-transparent rounded-full animate-spin" }), /* @__PURE__ */ import_react38.default.createElement("span", { className: "text-xs font-medium text-indigo-200 tracking-wider uppercase" }, "Sincronizando Processo...")),
|
|
25616
|
+
detailsNode && detailsNode.is_quest && /* @__PURE__ */ import_react38.default.createElement(
|
|
25408
25617
|
QuestDetailsPanel,
|
|
25409
25618
|
{
|
|
25410
25619
|
node: detailsNode,
|
|
@@ -25436,7 +25645,7 @@ function XViewScene({
|
|
|
25436
25645
|
style: overlayHiddenStyle
|
|
25437
25646
|
}
|
|
25438
25647
|
),
|
|
25439
|
-
detailsNode && detailsNode.is_process && /* @__PURE__ */
|
|
25648
|
+
detailsNode && detailsNode.is_process && /* @__PURE__ */ import_react38.default.createElement(
|
|
25440
25649
|
ProcessDetailsPanel,
|
|
25441
25650
|
{
|
|
25442
25651
|
node: detailsNode,
|
|
@@ -25466,7 +25675,7 @@ function XViewScene({
|
|
|
25466
25675
|
style: overlayHiddenStyle
|
|
25467
25676
|
}
|
|
25468
25677
|
),
|
|
25469
|
-
detailsNode && !detailsNode.is_quest && !detailsNode.is_process && /* @__PURE__ */
|
|
25678
|
+
detailsNode && !detailsNode.is_quest && !detailsNode.is_process && /* @__PURE__ */ import_react38.default.createElement(
|
|
25470
25679
|
NodeDetailsPanel,
|
|
25471
25680
|
{
|
|
25472
25681
|
node: detailsNode,
|
|
@@ -25501,7 +25710,7 @@ function XViewScene({
|
|
|
25501
25710
|
style: overlayHiddenStyle
|
|
25502
25711
|
}
|
|
25503
25712
|
),
|
|
25504
|
-
detailsLink && /* @__PURE__ */
|
|
25713
|
+
detailsLink && /* @__PURE__ */ import_react38.default.createElement(
|
|
25505
25714
|
RelationshipDetailsPanel,
|
|
25506
25715
|
{
|
|
25507
25716
|
link: detailsLink,
|
|
@@ -25516,7 +25725,7 @@ function XViewScene({
|
|
|
25516
25725
|
onHighlight: handleReadModeHighlight
|
|
25517
25726
|
}
|
|
25518
25727
|
),
|
|
25519
|
-
ancestryLinkDetails && /* @__PURE__ */
|
|
25728
|
+
ancestryLinkDetails && /* @__PURE__ */ import_react38.default.createElement(
|
|
25520
25729
|
AncestryLinkDetailsPanel,
|
|
25521
25730
|
{
|
|
25522
25731
|
data: ancestryLinkDetails,
|
|
@@ -25528,7 +25737,7 @@ function XViewScene({
|
|
|
25528
25737
|
onHighlight: handleReadModeHighlight
|
|
25529
25738
|
}
|
|
25530
25739
|
),
|
|
25531
|
-
/* @__PURE__ */
|
|
25740
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25532
25741
|
"div",
|
|
25533
25742
|
{
|
|
25534
25743
|
ref: tooltipRef,
|
|
@@ -25555,7 +25764,7 @@ function XViewScene({
|
|
|
25555
25764
|
}
|
|
25556
25765
|
}
|
|
25557
25766
|
),
|
|
25558
|
-
/* @__PURE__ */
|
|
25767
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25559
25768
|
ContextMenu,
|
|
25560
25769
|
{
|
|
25561
25770
|
data: contextMenu,
|
|
@@ -25594,7 +25803,7 @@ function XViewScene({
|
|
|
25594
25803
|
onInitiateProcess: (data) => userActionHandlers.handleInitiateProcess(actionHandlerContext, data)
|
|
25595
25804
|
}
|
|
25596
25805
|
),
|
|
25597
|
-
/* @__PURE__ */
|
|
25806
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25598
25807
|
MultiNodeContextMenu,
|
|
25599
25808
|
{
|
|
25600
25809
|
data: multiContextMenu,
|
|
@@ -25614,7 +25823,7 @@ function XViewScene({
|
|
|
25614
25823
|
)
|
|
25615
25824
|
}
|
|
25616
25825
|
),
|
|
25617
|
-
/* @__PURE__ */
|
|
25826
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25618
25827
|
RelationshipContextMenu,
|
|
25619
25828
|
{
|
|
25620
25829
|
data: relationshipMenu,
|
|
@@ -25632,14 +25841,14 @@ function XViewScene({
|
|
|
25632
25841
|
onDelete: (data) => userActionHandlers.handleDeleteLink(actionHandlerContext, data)
|
|
25633
25842
|
}
|
|
25634
25843
|
),
|
|
25635
|
-
/* @__PURE__ */
|
|
25844
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25636
25845
|
ImageViewer,
|
|
25637
25846
|
{
|
|
25638
25847
|
data: imageViewer,
|
|
25639
25848
|
onClose: () => setImageViewer({ ...imageViewer, visible: false })
|
|
25640
25849
|
}
|
|
25641
25850
|
),
|
|
25642
|
-
/* @__PURE__ */
|
|
25851
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25643
25852
|
Boards,
|
|
25644
25853
|
{
|
|
25645
25854
|
isOpen: isBoardsOpen,
|
|
@@ -25652,7 +25861,7 @@ function XViewScene({
|
|
|
25652
25861
|
userRole: userPermissionRole
|
|
25653
25862
|
}
|
|
25654
25863
|
),
|
|
25655
|
-
/* @__PURE__ */
|
|
25864
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25656
25865
|
MilestoneManager,
|
|
25657
25866
|
{
|
|
25658
25867
|
isOpen: isMilestoneManagerOpen,
|
|
@@ -25661,7 +25870,7 @@ function XViewScene({
|
|
|
25661
25870
|
onUpdateMilestones: handleUpdateMilestones
|
|
25662
25871
|
}
|
|
25663
25872
|
),
|
|
25664
|
-
/* @__PURE__ */
|
|
25873
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25665
25874
|
ImportParentFileModal,
|
|
25666
25875
|
{
|
|
25667
25876
|
isOpen: isImportModalOpen,
|
|
@@ -25674,7 +25883,7 @@ function XViewScene({
|
|
|
25674
25883
|
currentAncestries: ancestryDataRef.current || []
|
|
25675
25884
|
}
|
|
25676
25885
|
),
|
|
25677
|
-
invalidTargetError && /* @__PURE__ */
|
|
25886
|
+
invalidTargetError && /* @__PURE__ */ import_react38.default.createElement(
|
|
25678
25887
|
"div",
|
|
25679
25888
|
{
|
|
25680
25889
|
className: "ui-overlay",
|
|
@@ -25699,13 +25908,13 @@ function XViewScene({
|
|
|
25699
25908
|
animation: "fadeInDown 0.5s cubic-bezier(0.16, 1, 0.3, 1)"
|
|
25700
25909
|
}
|
|
25701
25910
|
},
|
|
25702
|
-
/* @__PURE__ */
|
|
25911
|
+
/* @__PURE__ */ import_react38.default.createElement("style", null, `
|
|
25703
25912
|
@keyframes fadeInDown {
|
|
25704
25913
|
from { opacity: 0; transform: translate(-50%, -20px); }
|
|
25705
25914
|
to { opacity: 1; transform: translate(-50%, 0); }
|
|
25706
25915
|
}
|
|
25707
25916
|
`),
|
|
25708
|
-
/* @__PURE__ */
|
|
25917
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25709
25918
|
"svg",
|
|
25710
25919
|
{
|
|
25711
25920
|
width: "20",
|
|
@@ -25717,12 +25926,12 @@ function XViewScene({
|
|
|
25717
25926
|
strokeLinecap: "round",
|
|
25718
25927
|
strokeLinejoin: "round"
|
|
25719
25928
|
},
|
|
25720
|
-
/* @__PURE__ */
|
|
25721
|
-
/* @__PURE__ */
|
|
25722
|
-
/* @__PURE__ */
|
|
25929
|
+
/* @__PURE__ */ import_react38.default.createElement("circle", { cx: "12", cy: "12", r: "10" }),
|
|
25930
|
+
/* @__PURE__ */ import_react38.default.createElement("line", { x1: "12", y1: "8", x2: "12", y2: "12" }),
|
|
25931
|
+
/* @__PURE__ */ import_react38.default.createElement("line", { x1: "12", y1: "16", x2: "12.01", y2: "16" })
|
|
25723
25932
|
),
|
|
25724
|
-
/* @__PURE__ */
|
|
25725
|
-
/* @__PURE__ */
|
|
25933
|
+
/* @__PURE__ */ import_react38.default.createElement("span", { style: { fontSize: "14px", fontWeight: 500 } }, invalidTargetError),
|
|
25934
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25726
25935
|
"button",
|
|
25727
25936
|
{
|
|
25728
25937
|
onClick: () => setInvalidTargetError(null),
|
|
@@ -25750,7 +25959,7 @@ function XViewScene({
|
|
|
25750
25959
|
"Fechar"
|
|
25751
25960
|
)
|
|
25752
25961
|
),
|
|
25753
|
-
/* @__PURE__ */
|
|
25962
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
25754
25963
|
UpgradeModal,
|
|
25755
25964
|
{
|
|
25756
25965
|
isOpen: isUpgradeModalOpen,
|