agentation 2.0.0 → 2.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/index.js +38 -11
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +38 -11
- package/dist/index.mjs.map +1 -1
- package/package.json +9 -10
package/dist/index.mjs
CHANGED
|
@@ -2774,6 +2774,36 @@ function PageFeedbackToolbarCSS({
|
|
|
2774
2774
|
const interval = setInterval(checkHealth, 1e4);
|
|
2775
2775
|
return () => clearInterval(interval);
|
|
2776
2776
|
}, [endpoint, mounted]);
|
|
2777
|
+
useEffect2(() => {
|
|
2778
|
+
if (!endpoint || !mounted || !currentSessionId) return;
|
|
2779
|
+
const eventSource = new EventSource(
|
|
2780
|
+
`${endpoint}/sessions/${currentSessionId}/events`
|
|
2781
|
+
);
|
|
2782
|
+
const removedStatuses = ["resolved", "dismissed"];
|
|
2783
|
+
const handler = (e) => {
|
|
2784
|
+
try {
|
|
2785
|
+
const event = JSON.parse(e.data);
|
|
2786
|
+
if (removedStatuses.includes(event.payload?.status)) {
|
|
2787
|
+
const id = event.payload.id;
|
|
2788
|
+
setExitingMarkers((prev) => new Set(prev).add(id));
|
|
2789
|
+
setTimeout(() => {
|
|
2790
|
+
setAnnotations((prev) => prev.filter((a) => a.id !== id));
|
|
2791
|
+
setExitingMarkers((prev) => {
|
|
2792
|
+
const next = new Set(prev);
|
|
2793
|
+
next.delete(id);
|
|
2794
|
+
return next;
|
|
2795
|
+
});
|
|
2796
|
+
}, 150);
|
|
2797
|
+
}
|
|
2798
|
+
} catch {
|
|
2799
|
+
}
|
|
2800
|
+
};
|
|
2801
|
+
eventSource.addEventListener("annotation.updated", handler);
|
|
2802
|
+
return () => {
|
|
2803
|
+
eventSource.removeEventListener("annotation.updated", handler);
|
|
2804
|
+
eventSource.close();
|
|
2805
|
+
};
|
|
2806
|
+
}, [endpoint, mounted, currentSessionId]);
|
|
2777
2807
|
useEffect2(() => {
|
|
2778
2808
|
if (!endpoint || !mounted) return;
|
|
2779
2809
|
const wasDisconnected = prevConnectionStatusRef.current === "disconnected";
|
|
@@ -4039,6 +4069,12 @@ function PageFeedbackToolbarCSS({
|
|
|
4039
4069
|
setIsActive(false);
|
|
4040
4070
|
}
|
|
4041
4071
|
}
|
|
4072
|
+
if ((e.metaKey || e.ctrlKey) && e.shiftKey && (e.key === "f" || e.key === "F")) {
|
|
4073
|
+
e.preventDefault();
|
|
4074
|
+
hideTooltipsUntilMouseLeave();
|
|
4075
|
+
setIsActive((prev) => !prev);
|
|
4076
|
+
return;
|
|
4077
|
+
}
|
|
4042
4078
|
if (isTyping || e.metaKey || e.ctrlKey) return;
|
|
4043
4079
|
if (e.key === "p" || e.key === "P") {
|
|
4044
4080
|
e.preventDefault();
|
|
@@ -4393,7 +4429,7 @@ function PageFeedbackToolbarCSS({
|
|
|
4393
4429
|
] }),
|
|
4394
4430
|
/* @__PURE__ */ jsxs3("span", { className: styles_module_default2.settingsVersion, children: [
|
|
4395
4431
|
"v",
|
|
4396
|
-
"2.
|
|
4432
|
+
"2.1.1"
|
|
4397
4433
|
] }),
|
|
4398
4434
|
/* @__PURE__ */ jsx3(
|
|
4399
4435
|
"button",
|
|
@@ -4675,21 +4711,12 @@ function PageFeedbackToolbarCSS({
|
|
|
4675
4711
|
]
|
|
4676
4712
|
}
|
|
4677
4713
|
),
|
|
4678
|
-
endpoint
|
|
4714
|
+
endpoint && /* @__PURE__ */ jsx3(
|
|
4679
4715
|
"div",
|
|
4680
4716
|
{
|
|
4681
4717
|
className: `${styles_module_default2.mcpStatusDot} ${styles_module_default2[connectionStatus]}`,
|
|
4682
4718
|
title: connectionStatus === "connected" ? "Connected" : connectionStatus === "connecting" ? "Connecting..." : "Disconnected"
|
|
4683
4719
|
}
|
|
4684
|
-
) : /* @__PURE__ */ jsx3(
|
|
4685
|
-
"a",
|
|
4686
|
-
{
|
|
4687
|
-
href: "https://agentation.dev/install#mcp-server",
|
|
4688
|
-
target: "_blank",
|
|
4689
|
-
rel: "noopener noreferrer",
|
|
4690
|
-
className: styles_module_default2.settingsLink,
|
|
4691
|
-
children: "Learn more \u2192"
|
|
4692
|
-
}
|
|
4693
4720
|
)
|
|
4694
4721
|
] }),
|
|
4695
4722
|
/* @__PURE__ */ jsxs3(
|