@copilotkit/react-ui 1.0.9-pre-async-submit-message.0 → 1.0.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/CHANGELOG.md +5 -5
- package/dist/{chunk-IN42MBI2.mjs → chunk-64STG5VG.mjs} +2 -2
- package/dist/{chunk-M5A56FBF.mjs → chunk-D6QNFZXK.mjs} +9 -3
- package/dist/chunk-D6QNFZXK.mjs.map +1 -0
- package/dist/{chunk-NS5XXT5G.mjs → chunk-E6UH55HG.mjs} +2 -2
- package/dist/{chunk-6TWACO5V.mjs → chunk-KISORA5S.mjs} +3 -3
- package/dist/{chunk-B7DNOYVQ.mjs → chunk-LLOSOTAT.mjs} +7 -2
- package/dist/chunk-LLOSOTAT.mjs.map +1 -0
- package/dist/{chunk-RT2BA4MP.mjs → chunk-PF5HUDUP.mjs} +11 -2
- package/dist/{chunk-RT2BA4MP.mjs.map → chunk-PF5HUDUP.mjs.map} +1 -1
- package/dist/{chunk-VPUIM2ZY.mjs → chunk-TS7TVUBD.mjs} +2 -2
- package/dist/components/chat/Chat.js +17 -2
- package/dist/components/chat/Chat.js.map +1 -1
- package/dist/components/chat/Chat.mjs +3 -3
- package/dist/components/chat/Modal.js +23 -3
- package/dist/components/chat/Modal.js.map +1 -1
- package/dist/components/chat/Modal.mjs +5 -5
- package/dist/components/chat/Popup.js +23 -3
- package/dist/components/chat/Popup.js.map +1 -1
- package/dist/components/chat/Popup.mjs +6 -6
- package/dist/components/chat/Sidebar.js +23 -3
- package/dist/components/chat/Sidebar.js.map +1 -1
- package/dist/components/chat/Sidebar.mjs +6 -6
- package/dist/components/chat/Window.js +6 -1
- package/dist/components/chat/Window.js.map +1 -1
- package/dist/components/chat/Window.mjs +1 -1
- package/dist/components/chat/index.js +23 -3
- package/dist/components/chat/index.js.map +1 -1
- package/dist/components/chat/index.mjs +7 -7
- package/dist/components/dev-console/console.js +17 -2
- package/dist/components/dev-console/console.js.map +1 -1
- package/dist/components/dev-console/console.mjs +2 -2
- package/dist/components/dev-console/index.js +17 -2
- package/dist/components/dev-console/index.js.map +1 -1
- package/dist/components/dev-console/index.mjs +2 -2
- package/dist/components/dev-console/utils.js +10 -1
- package/dist/components/dev-console/utils.js.map +1 -1
- package/dist/components/dev-console/utils.mjs +1 -1
- package/dist/components/index.js +23 -3
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +7 -7
- package/dist/index.js +23 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -7
- package/package.json +7 -7
- package/src/components/chat/Window.tsx +12 -1
- package/src/components/dev-console/console.tsx +11 -1
- package/src/components/dev-console/utils.ts +10 -1
- package/dist/chunk-B7DNOYVQ.mjs.map +0 -1
- package/dist/chunk-M5A56FBF.mjs.map +0 -1
- /package/dist/{chunk-IN42MBI2.mjs.map → chunk-64STG5VG.mjs.map} +0 -0
- /package/dist/{chunk-NS5XXT5G.mjs.map → chunk-E6UH55HG.mjs.map} +0 -0
- /package/dist/{chunk-6TWACO5V.mjs.map → chunk-KISORA5S.mjs.map} +0 -0
- /package/dist/{chunk-VPUIM2ZY.mjs.map → chunk-TS7TVUBD.mjs.map} +0 -0
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
CopilotModal
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-KISORA5S.mjs";
|
|
4
|
+
import "../../chunk-LLOSOTAT.mjs";
|
|
5
5
|
import "../../chunk-SE6DAYSX.mjs";
|
|
6
6
|
import "../../chunk-UC3Y7MWX.mjs";
|
|
7
|
-
import "../../chunk-
|
|
7
|
+
import "../../chunk-TS7TVUBD.mjs";
|
|
8
8
|
import "../../chunk-V7W6IM2V.mjs";
|
|
9
9
|
import "../../chunk-KSCXPA74.mjs";
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
10
|
+
import "../../chunk-D6QNFZXK.mjs";
|
|
11
|
+
import "../../chunk-PF5HUDUP.mjs";
|
|
12
12
|
import "../../chunk-OTPAZXVR.mjs";
|
|
13
13
|
import "../../chunk-U6J5DGOE.mjs";
|
|
14
14
|
import "../../chunk-YQFVRDNC.mjs";
|
|
@@ -396,7 +396,12 @@ var Window = ({
|
|
|
396
396
|
return;
|
|
397
397
|
}
|
|
398
398
|
const parentElement = (_a = windowRef.current) == null ? void 0 : _a.parentElement;
|
|
399
|
-
|
|
399
|
+
let className = "";
|
|
400
|
+
if (event.target instanceof HTMLElement) {
|
|
401
|
+
className = event.target.className;
|
|
402
|
+
}
|
|
403
|
+
if (open && parentElement && !parentElement.contains(event.target) && // prevent closing the window when clicking on the debug menu
|
|
404
|
+
!className.includes("copilotKitDebugMenu")) {
|
|
400
405
|
setOpen(false);
|
|
401
406
|
}
|
|
402
407
|
},
|
|
@@ -1482,9 +1487,18 @@ function getPublishedCopilotKitVersion(current, forceCheck = false) {
|
|
|
1482
1487
|
});
|
|
1483
1488
|
}
|
|
1484
1489
|
function logReadables(context) {
|
|
1485
|
-
|
|
1490
|
+
const readables = context.getContextString([], import_react_core5.defaultCopilotContextCategories).trim();
|
|
1491
|
+
if (readables.length === 0) {
|
|
1492
|
+
console.log("No readables found");
|
|
1493
|
+
return;
|
|
1494
|
+
}
|
|
1495
|
+
console.log(readables);
|
|
1486
1496
|
}
|
|
1487
1497
|
function logActions(context) {
|
|
1498
|
+
if (Object.values(context.actions).length === 0) {
|
|
1499
|
+
console.log("No actions found");
|
|
1500
|
+
return;
|
|
1501
|
+
}
|
|
1488
1502
|
for (const action of Object.values(context.actions)) {
|
|
1489
1503
|
console.group(action.name);
|
|
1490
1504
|
console.log("name", action.name);
|
|
@@ -1602,7 +1616,13 @@ function CopilotDevConsole() {
|
|
|
1602
1616
|
setVersionStatus("checking");
|
|
1603
1617
|
getPublishedCopilotKitVersion(currentVersion, force).then((v) => {
|
|
1604
1618
|
setLatestVersion(v.latest);
|
|
1605
|
-
|
|
1619
|
+
let versionOk = false;
|
|
1620
|
+
if (v.current === v.latest) {
|
|
1621
|
+
versionOk = true;
|
|
1622
|
+
} else if (/[a-zA-Z]/.test(v.current)) {
|
|
1623
|
+
versionOk = true;
|
|
1624
|
+
}
|
|
1625
|
+
if (versionOk) {
|
|
1606
1626
|
setVersionStatus("latest");
|
|
1607
1627
|
} else if (v.severity !== "low") {
|
|
1608
1628
|
setVersionStatus("outdated");
|