@copilotkit/react-ui 1.8.12-next.4 → 1.8.12-next.6
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 +18 -0
- package/dist/chunk-CGEAG65D.mjs +27 -0
- package/dist/chunk-CGEAG65D.mjs.map +1 -0
- package/dist/{chunk-SJWVHGKD.mjs → chunk-ECCHEFQV.mjs} +2 -2
- package/dist/chunk-EMIYIMQ6.mjs +110 -0
- package/dist/chunk-EMIYIMQ6.mjs.map +1 -0
- package/dist/{chunk-QXWJ7HYU.mjs → chunk-JZAMNIUD.mjs} +8 -8
- package/dist/{chunk-QXWJ7HYU.mjs.map → chunk-JZAMNIUD.mjs.map} +1 -1
- package/dist/{chunk-T5637OOY.mjs → chunk-KCV67665.mjs} +2 -2
- package/dist/{chunk-SLTG4L62.mjs → chunk-LUPGADWY.mjs} +4 -4
- package/dist/{chunk-POWCBXRY.mjs → chunk-RVLCPPEL.mjs} +4 -4
- package/dist/{chunk-Q2NFQTCQ.mjs → chunk-TIDV74OE.mjs} +7 -33
- package/dist/chunk-TIDV74OE.mjs.map +1 -0
- package/dist/{chunk-W2OWARTP.mjs → chunk-WN46UIN3.mjs} +7 -7
- package/dist/components/chat/Chat.js +151 -118
- package/dist/components/chat/Chat.js.map +1 -1
- package/dist/components/chat/Chat.mjs +7 -5
- package/dist/components/chat/Input.js +79 -46
- package/dist/components/chat/Input.js.map +1 -1
- package/dist/components/chat/Input.mjs +3 -1
- package/dist/components/chat/Modal.js +163 -162
- package/dist/components/chat/Modal.js.map +1 -1
- package/dist/components/chat/Modal.mjs +8 -7
- package/dist/components/chat/Popup.js +165 -164
- package/dist/components/chat/Popup.js.map +1 -1
- package/dist/components/chat/Popup.mjs +9 -8
- package/dist/components/chat/PoweredByTag.d.ts +7 -0
- package/dist/components/chat/PoweredByTag.js +56 -0
- package/dist/components/chat/PoweredByTag.js.map +1 -0
- package/dist/components/chat/PoweredByTag.mjs +9 -0
- package/dist/components/chat/PoweredByTag.mjs.map +1 -0
- package/dist/components/chat/Sidebar.js +165 -164
- package/dist/components/chat/Sidebar.js.map +1 -1
- package/dist/components/chat/Sidebar.mjs +9 -8
- package/dist/components/chat/Window.js +5 -37
- package/dist/components/chat/Window.js.map +1 -1
- package/dist/components/chat/Window.mjs +1 -2
- package/dist/components/chat/index.js +167 -166
- package/dist/components/chat/index.js.map +1 -1
- package/dist/components/chat/index.mjs +12 -11
- package/dist/components/chat/messages/RenderImageMessage.mjs +2 -2
- package/dist/components/chat/messages/RenderTextMessage.mjs +2 -2
- package/dist/components/index.js +167 -166
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +12 -11
- package/dist/index.css +23 -26
- package/dist/index.css.map +1 -1
- package/dist/index.js +167 -166
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +12 -11
- package/package.json +4 -4
- package/src/components/chat/Chat.tsx +1 -1
- package/src/components/chat/Input.tsx +6 -2
- package/src/components/chat/PoweredByTag.tsx +29 -0
- package/src/components/chat/Window.tsx +1 -24
- package/src/css/input.css +27 -0
- package/src/css/window.css +0 -29
- package/dist/chunk-IWBARPUZ.mjs +0 -102
- package/dist/chunk-IWBARPUZ.mjs.map +0 -1
- package/dist/chunk-Q2NFQTCQ.mjs.map +0 -1
- /package/dist/{chunk-SJWVHGKD.mjs.map → chunk-ECCHEFQV.mjs.map} +0 -0
- /package/dist/{chunk-T5637OOY.mjs.map → chunk-KCV67665.mjs.map} +0 -0
- /package/dist/{chunk-SLTG4L62.mjs.map → chunk-LUPGADWY.mjs.map} +0 -0
- /package/dist/{chunk-POWCBXRY.mjs.map → chunk-RVLCPPEL.mjs.map} +0 -0
- /package/dist/{chunk-W2OWARTP.mjs.map → chunk-WN46UIN3.mjs.map} +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
CopilotPopup
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
5
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-ECCHEFQV.mjs";
|
|
4
|
+
import "../../chunk-WN46UIN3.mjs";
|
|
5
|
+
import "../../chunk-TIDV74OE.mjs";
|
|
6
6
|
import "../../chunk-UH2UFL5W.mjs";
|
|
7
7
|
import "../../chunk-V7W6IM2V.mjs";
|
|
8
8
|
import "../../chunk-VGPQYMKJ.mjs";
|
|
@@ -12,17 +12,18 @@ import "../../chunk-KXE2JCUH.mjs";
|
|
|
12
12
|
import "../../chunk-NRA3CFEE.mjs";
|
|
13
13
|
import "../../chunk-BH6PCAAL.mjs";
|
|
14
14
|
import "../../chunk-UFN2VWSR.mjs";
|
|
15
|
-
import "../../chunk-
|
|
15
|
+
import "../../chunk-JZAMNIUD.mjs";
|
|
16
16
|
import "../../chunk-DSQGQJI4.mjs";
|
|
17
17
|
import "../../chunk-24TDU7MY.mjs";
|
|
18
|
-
import "../../chunk-
|
|
18
|
+
import "../../chunk-LUPGADWY.mjs";
|
|
19
19
|
import "../../chunk-XFCMZH2H.mjs";
|
|
20
|
-
import "../../chunk-
|
|
21
|
-
import "../../chunk-HWMFMBJC.mjs";
|
|
20
|
+
import "../../chunk-RVLCPPEL.mjs";
|
|
22
21
|
import "../../chunk-OZXUB3V7.mjs";
|
|
22
|
+
import "../../chunk-HWMFMBJC.mjs";
|
|
23
23
|
import "../../chunk-XZNY26GH.mjs";
|
|
24
24
|
import "../../chunk-PLHTVHUW.mjs";
|
|
25
|
-
import "../../chunk-
|
|
25
|
+
import "../../chunk-EMIYIMQ6.mjs";
|
|
26
|
+
import "../../chunk-CGEAG65D.mjs";
|
|
26
27
|
import "../../chunk-YQFVRDNC.mjs";
|
|
27
28
|
import "../../chunk-ABHUX6T6.mjs";
|
|
28
29
|
import "../../chunk-KENCH7RN.mjs";
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/components/chat/PoweredByTag.tsx
|
|
21
|
+
var PoweredByTag_exports = {};
|
|
22
|
+
__export(PoweredByTag_exports, {
|
|
23
|
+
PoweredByTag: () => PoweredByTag
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(PoweredByTag_exports);
|
|
26
|
+
|
|
27
|
+
// src/hooks/use-dark-mode.ts
|
|
28
|
+
var useDarkMode = () => {
|
|
29
|
+
if (typeof window === "undefined")
|
|
30
|
+
return false;
|
|
31
|
+
return document.documentElement.classList.contains("dark") || document.body.classList.contains("dark") || document.documentElement.getAttribute("data-theme") === "dark" || document.body.getAttribute("data-theme") === "dark" || window.matchMedia("(prefers-color-scheme: dark)").matches;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
// src/components/chat/PoweredByTag.tsx
|
|
35
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
36
|
+
function PoweredByTag({ showPoweredBy = true }) {
|
|
37
|
+
const isDark = useDarkMode();
|
|
38
|
+
if (!showPoweredBy) {
|
|
39
|
+
return null;
|
|
40
|
+
}
|
|
41
|
+
const poweredByStyle = {
|
|
42
|
+
visibility: "visible",
|
|
43
|
+
display: "block",
|
|
44
|
+
position: "static",
|
|
45
|
+
textAlign: "center",
|
|
46
|
+
fontSize: "12px",
|
|
47
|
+
padding: "3px 0",
|
|
48
|
+
color: isDark ? "rgb(69, 69, 69)" : "rgb(214, 214, 214)"
|
|
49
|
+
};
|
|
50
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "poweredBy", style: poweredByStyle, children: "Powered by CopilotKit" }) });
|
|
51
|
+
}
|
|
52
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
53
|
+
0 && (module.exports = {
|
|
54
|
+
PoweredByTag
|
|
55
|
+
});
|
|
56
|
+
//# sourceMappingURL=PoweredByTag.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/components/chat/PoweredByTag.tsx","../../../src/hooks/use-dark-mode.ts"],"sourcesContent":["import React from \"react\";\nimport { useDarkMode } from \"../../hooks/use-dark-mode\";\n\nexport function PoweredByTag({ showPoweredBy = true }: { showPoweredBy?: boolean }) {\n const isDark = useDarkMode();\n\n if (!showPoweredBy) {\n return null;\n }\n\n const poweredByStyle = {\n visibility: \"visible\",\n display: \"block\",\n position: \"static\",\n textAlign: \"center\",\n fontSize: \"12px\",\n padding: \"3px 0\",\n color: isDark ? \"rgb(69, 69, 69)\" : \"rgb(214, 214, 214)\",\n };\n\n return (\n <div>\n {/*@ts-expect-error -- expecting position not to be a string, but it can be.*/}\n <p className=\"poweredBy\" style={poweredByStyle}>\n Powered by CopilotKit\n </p>\n </div>\n );\n}\n","export const useDarkMode = () => {\n if (typeof window === \"undefined\") return false;\n return (\n document.documentElement.classList.contains(\"dark\") ||\n document.body.classList.contains(\"dark\") ||\n document.documentElement.getAttribute(\"data-theme\") === \"dark\" ||\n document.body.getAttribute(\"data-theme\") === \"dark\" ||\n window.matchMedia(\"(prefers-color-scheme: dark)\").matches\n );\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAO,IAAM,cAAc,MAAM;AAC/B,MAAI,OAAO,WAAW;AAAa,WAAO;AAC1C,SACE,SAAS,gBAAgB,UAAU,SAAS,MAAM,KAClD,SAAS,KAAK,UAAU,SAAS,MAAM,KACvC,SAAS,gBAAgB,aAAa,YAAY,MAAM,UACxD,SAAS,KAAK,aAAa,YAAY,MAAM,UAC7C,OAAO,WAAW,8BAA8B,EAAE;AAEtD;;;ADcM;AApBC,SAAS,aAAa,EAAE,gBAAgB,KAAK,GAAgC;AAClF,QAAM,SAAS,YAAY;AAE3B,MAAI,CAAC,eAAe;AAClB,WAAO;AAAA,EACT;AAEA,QAAM,iBAAiB;AAAA,IACrB,YAAY;AAAA,IACZ,SAAS;AAAA,IACT,UAAU;AAAA,IACV,WAAW;AAAA,IACX,UAAU;AAAA,IACV,SAAS;AAAA,IACT,OAAO,SAAS,oBAAoB;AAAA,EACtC;AAEA,SACE,4CAAC,SAEC,sDAAC,OAAE,WAAU,aAAY,OAAO,gBAAgB,mCAEhD,GACF;AAEJ;","names":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|