@copilotkit/react-ui 1.7.2-next.2 → 1.8.0-next.3
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 +12 -0
- package/dist/{chunk-QXTRFMPM.mjs → chunk-2LRE4W6A.mjs} +13 -11
- package/dist/chunk-2LRE4W6A.mjs.map +1 -0
- package/dist/{chunk-QXQDIFOC.mjs → chunk-5GNYGURH.mjs} +48 -37
- package/dist/chunk-5GNYGURH.mjs.map +1 -0
- package/dist/{chunk-CBBFRI3Q.mjs → chunk-5JY5QJ2W.mjs} +9 -5
- package/dist/chunk-5JY5QJ2W.mjs.map +1 -0
- package/dist/{chunk-OFYI4UU4.mjs → chunk-7RIBDD4K.mjs} +19 -3
- package/dist/chunk-7RIBDD4K.mjs.map +1 -0
- package/dist/{chunk-YAGE7RCE.mjs → chunk-CGVOCLHN.mjs} +2 -2
- package/dist/chunk-FBYETUFL.mjs +118 -0
- package/dist/chunk-FBYETUFL.mjs.map +1 -0
- package/dist/chunk-GDJAAFIK.mjs +24 -0
- package/dist/chunk-GDJAAFIK.mjs.map +1 -0
- package/dist/{chunk-6FTRYYR5.mjs → chunk-GJME6MK4.mjs} +72 -62
- package/dist/chunk-GJME6MK4.mjs.map +1 -0
- package/dist/{chunk-AELKLZSG.mjs → chunk-KG6DW6R2.mjs} +10 -10
- package/dist/{chunk-DLG7BZTA.mjs → chunk-LKCAF2HG.mjs} +2 -2
- package/dist/{chunk-R2O33F44.mjs → chunk-LXCH2BIB.mjs} +2 -2
- package/dist/chunk-ORSMX3SE.mjs +244 -0
- package/dist/chunk-ORSMX3SE.mjs.map +1 -0
- package/dist/{chunk-UPTB2MVO.mjs → chunk-PCTCOQK2.mjs} +4 -10
- package/dist/chunk-PCTCOQK2.mjs.map +1 -0
- package/dist/{chunk-ZIF5JJCH.mjs → chunk-QGK5GOSC.mjs} +24 -53
- package/dist/chunk-QGK5GOSC.mjs.map +1 -0
- package/dist/{chunk-WGAZXTUA.mjs → chunk-TOQ7P4DO.mjs} +6 -9
- package/dist/chunk-TOQ7P4DO.mjs.map +1 -0
- package/dist/{chunk-3XAXY2Z3.mjs → chunk-UZTZXMYS.mjs} +2 -2
- package/dist/{chunk-RQNJNK2W.mjs → chunk-VC4NO5QZ.mjs} +2 -2
- package/dist/{chunk-YQ3D5IQV.mjs → chunk-XNQO5AZZ.mjs} +2 -5
- package/dist/chunk-XNQO5AZZ.mjs.map +1 -0
- package/dist/chunk-YC4NBUGE.mjs +97 -0
- package/dist/chunk-YC4NBUGE.mjs.map +1 -0
- package/dist/components/chat/Button.js.map +1 -1
- package/dist/components/chat/Button.mjs +3 -3
- package/dist/components/chat/Chat.d.ts +17 -1
- package/dist/components/chat/Chat.js +378 -905
- package/dist/components/chat/Chat.js.map +1 -1
- package/dist/components/chat/Chat.mjs +11 -18
- package/dist/components/chat/ChatContext.d.ts +20 -0
- package/dist/components/chat/ChatContext.js +44 -74
- package/dist/components/chat/ChatContext.js.map +1 -1
- package/dist/components/chat/ChatContext.mjs +2 -2
- package/dist/components/chat/CodeBlock.js +58 -82
- package/dist/components/chat/CodeBlock.js.map +1 -1
- package/dist/components/chat/CodeBlock.mjs +2 -2
- package/dist/components/chat/Header.js +516 -4
- package/dist/components/chat/Header.js.map +1 -1
- package/dist/components/chat/Header.mjs +10 -3
- package/dist/components/chat/Icons.d.ts +10 -9
- package/dist/components/chat/Icons.js +125 -164
- package/dist/components/chat/Icons.js.map +1 -1
- package/dist/components/chat/Icons.mjs +9 -5
- package/dist/components/chat/Input.d.ts +1 -1
- package/dist/components/chat/Input.js +11 -9
- package/dist/components/chat/Input.js.map +1 -1
- package/dist/components/chat/Input.mjs +3 -3
- package/dist/components/chat/Markdown.js +58 -56
- package/dist/components/chat/Markdown.js.map +1 -1
- package/dist/components/chat/Markdown.mjs +3 -3
- package/dist/components/chat/Messages.d.ts +1 -1
- package/dist/components/chat/Messages.js +70 -60
- package/dist/components/chat/Messages.js.map +1 -1
- package/dist/components/chat/Messages.mjs +3 -3
- package/dist/components/chat/Modal.js +1708 -1749
- package/dist/components/chat/Modal.js.map +1 -1
- package/dist/components/chat/Modal.mjs +21 -21
- package/dist/components/chat/Popup.js +1708 -1749
- package/dist/components/chat/Popup.js.map +1 -1
- package/dist/components/chat/Popup.mjs +22 -22
- package/dist/components/chat/Response.js.map +1 -1
- package/dist/components/chat/Response.mjs +3 -3
- package/dist/components/chat/Sidebar.js +1710 -1751
- package/dist/components/chat/Sidebar.js.map +1 -1
- package/dist/components/chat/Sidebar.mjs +22 -22
- package/dist/components/chat/Suggestion.js +4 -40
- package/dist/components/chat/Suggestion.js.map +1 -1
- package/dist/components/chat/Suggestion.mjs +2 -2
- package/dist/components/chat/Window.js.map +1 -1
- package/dist/components/chat/Window.mjs +3 -3
- package/dist/components/chat/index.js +1710 -1751
- package/dist/components/chat/index.js.map +1 -1
- package/dist/components/chat/index.mjs +24 -24
- package/dist/components/chat/messages/AssistantMessage.js +211 -59
- package/dist/components/chat/messages/AssistantMessage.js.map +1 -1
- package/dist/components/chat/messages/AssistantMessage.mjs +5 -5
- package/dist/components/chat/messages/RenderTextMessage.js +18 -2
- package/dist/components/chat/messages/RenderTextMessage.js.map +1 -1
- package/dist/components/chat/messages/RenderTextMessage.mjs +1 -1
- package/dist/components/chat/props.d.ts +53 -0
- package/dist/components/chat/props.js.map +1 -1
- package/dist/components/dev-console/console.js +51 -233
- package/dist/components/dev-console/console.js.map +1 -1
- package/dist/components/dev-console/console.mjs +3 -3
- package/dist/components/dev-console/index.js +51 -233
- package/dist/components/dev-console/index.js.map +1 -1
- package/dist/components/dev-console/index.mjs +3 -3
- package/dist/components/help-modal/index.js +29 -147
- package/dist/components/help-modal/index.js.map +1 -1
- package/dist/components/help-modal/index.mjs +1 -1
- package/dist/components/help-modal/modal.js +29 -147
- package/dist/components/help-modal/modal.js.map +1 -1
- package/dist/components/help-modal/modal.mjs +1 -1
- package/dist/components/index.js +1683 -1724
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +28 -28
- package/dist/index.css +254 -90
- package/dist/index.css.map +1 -1
- package/dist/index.js +1692 -1733
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +28 -28
- package/dist/types/css.d.ts +7 -1
- package/dist/types/css.js.map +1 -1
- package/package.json +4 -4
- package/src/components/chat/Chat.tsx +59 -22
- package/src/components/chat/ChatContext.tsx +29 -1
- package/src/components/chat/CodeBlock.tsx +2 -4
- package/src/components/chat/Header.tsx +8 -3
- package/src/components/chat/Icons.tsx +108 -108
- package/src/components/chat/Input.tsx +42 -38
- package/src/components/chat/Markdown.tsx +0 -3
- package/src/components/chat/Messages.tsx +68 -56
- package/src/components/chat/Suggestion.tsx +2 -3
- package/src/components/chat/messages/AssistantMessage.tsx +95 -3
- package/src/components/chat/messages/RenderTextMessage.tsx +17 -1
- package/src/components/chat/props.ts +66 -0
- package/src/components/dev-console/console.tsx +16 -54
- package/src/components/help-modal/modal.tsx +38 -101
- package/src/css/button.css +15 -4
- package/src/css/colors.css +27 -6
- package/src/css/console.css +46 -39
- package/src/css/header.css +22 -5
- package/src/css/input.css +24 -17
- package/src/css/markdown.css +2 -1
- package/src/css/messages.css +125 -15
- package/src/css/panel.css +1 -0
- package/src/css/suggestions.css +14 -6
- package/src/types/css.ts +7 -1
- package/dist/chunk-3VNMQWGT.mjs +0 -25
- package/dist/chunk-3VNMQWGT.mjs.map +0 -1
- package/dist/chunk-6FTRYYR5.mjs.map +0 -1
- package/dist/chunk-CBBFRI3Q.mjs.map +0 -1
- package/dist/chunk-FZC7X5PK.mjs +0 -262
- package/dist/chunk-FZC7X5PK.mjs.map +0 -1
- package/dist/chunk-OFYI4UU4.mjs.map +0 -1
- package/dist/chunk-QXQDIFOC.mjs.map +0 -1
- package/dist/chunk-QXTRFMPM.mjs.map +0 -1
- package/dist/chunk-TI7SY2RI.mjs +0 -164
- package/dist/chunk-TI7SY2RI.mjs.map +0 -1
- package/dist/chunk-UPTB2MVO.mjs.map +0 -1
- package/dist/chunk-VEC45H6Q.mjs +0 -18
- package/dist/chunk-VEC45H6Q.mjs.map +0 -1
- package/dist/chunk-WGAZXTUA.mjs.map +0 -1
- package/dist/chunk-YQ3D5IQV.mjs.map +0 -1
- package/dist/chunk-ZIF5JJCH.mjs.map +0 -1
- /package/dist/{chunk-YAGE7RCE.mjs.map → chunk-CGVOCLHN.mjs.map} +0 -0
- /package/dist/{chunk-AELKLZSG.mjs.map → chunk-KG6DW6R2.mjs.map} +0 -0
- /package/dist/{chunk-DLG7BZTA.mjs.map → chunk-LKCAF2HG.mjs.map} +0 -0
- /package/dist/{chunk-R2O33F44.mjs.map → chunk-LXCH2BIB.mjs.map} +0 -0
- /package/dist/{chunk-3XAXY2Z3.mjs.map → chunk-UZTZXMYS.mjs.map} +0 -0
- /package/dist/{chunk-RQNJNK2W.mjs.map → chunk-VC4NO5QZ.mjs.map} +0 -0
|
@@ -1,73 +1,58 @@
|
|
|
1
|
-
import React, { useMemo, useState } from "react";
|
|
2
|
-
import { CloseIcon
|
|
1
|
+
import React, { useMemo, useState, useRef, useEffect } from "react";
|
|
2
|
+
import { CloseIcon } from "./icons";
|
|
3
3
|
|
|
4
4
|
export function CopilotKitHelpModal() {
|
|
5
5
|
const [showHelpModal, setShowHelpModal] = useState(false);
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const [emailError, setEmailError] = useState("");
|
|
9
|
-
const [submitting, setSubmitting] = useState(false);
|
|
6
|
+
const buttonRef = useRef<HTMLButtonElement>(null);
|
|
7
|
+
const popoverRef = useRef<HTMLDivElement>(null);
|
|
10
8
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
9
|
+
// Close popover when clicking outside
|
|
10
|
+
useEffect(() => {
|
|
11
|
+
const handleClickOutside = (event: MouseEvent) => {
|
|
12
|
+
if (
|
|
13
|
+
popoverRef.current &&
|
|
14
|
+
!popoverRef.current.contains(event.target as Node) &&
|
|
15
|
+
buttonRef.current &&
|
|
16
|
+
!buttonRef.current.contains(event.target as Node)
|
|
17
|
+
) {
|
|
18
|
+
setShowHelpModal(false);
|
|
19
|
+
}
|
|
20
|
+
};
|
|
15
21
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
if (email?.length > 0 && !validateEmail(email)) {
|
|
20
|
-
setEmailError("Please enter a valid email address");
|
|
21
|
-
return;
|
|
22
|
+
if (showHelpModal) {
|
|
23
|
+
document.addEventListener("mousedown", handleClickOutside);
|
|
22
24
|
}
|
|
23
|
-
setSubmitting(true);
|
|
24
|
-
|
|
25
|
-
await fetch("https://api.segment.io/v1/track", {
|
|
26
|
-
method: "POST",
|
|
27
|
-
headers: {
|
|
28
|
-
"Content-Type": "application/json",
|
|
29
|
-
},
|
|
30
|
-
body: JSON.stringify({
|
|
31
|
-
event: "oss.dev-console.help",
|
|
32
|
-
anonymousId: window.crypto.randomUUID(),
|
|
33
|
-
properties: { email, text: issueDescription },
|
|
34
|
-
writeKey: "q0gQqvGYyw9pNyhIocNzefSYKGO1aiwW",
|
|
35
|
-
}),
|
|
36
|
-
});
|
|
37
25
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
setSubmitting(false);
|
|
43
|
-
setShowHelpModal(false);
|
|
44
|
-
};
|
|
26
|
+
return () => {
|
|
27
|
+
document.removeEventListener("mousedown", handleClickOutside);
|
|
28
|
+
};
|
|
29
|
+
}, [showHelpModal]);
|
|
45
30
|
|
|
46
31
|
const HelpButton = () => (
|
|
47
32
|
<button
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
className="
|
|
33
|
+
ref={buttonRef}
|
|
34
|
+
onClick={() => setShowHelpModal(!showHelpModal)}
|
|
35
|
+
className="copilotKitDebugMenuTriggerButton relative"
|
|
51
36
|
aria-label="Open Help"
|
|
52
37
|
>
|
|
53
38
|
Help
|
|
54
39
|
</button>
|
|
55
40
|
);
|
|
56
41
|
|
|
57
|
-
const submitButtonDisabled = useMemo(
|
|
58
|
-
() => submitting || !!emailError || issueDescription == null || issueDescription?.length == 0,
|
|
59
|
-
[submitting, emailError, issueDescription],
|
|
60
|
-
);
|
|
61
|
-
|
|
62
42
|
return (
|
|
63
|
-
|
|
43
|
+
<div className="relative">
|
|
64
44
|
<HelpButton />
|
|
65
45
|
{showHelpModal && (
|
|
66
46
|
<div
|
|
67
|
-
|
|
68
|
-
|
|
47
|
+
ref={popoverRef}
|
|
48
|
+
className="absolute mt-2 z-50"
|
|
49
|
+
style={{
|
|
50
|
+
top: "100%",
|
|
51
|
+
right: "-120px",
|
|
52
|
+
width: "380px",
|
|
53
|
+
}}
|
|
69
54
|
>
|
|
70
|
-
<div className="bg-white rounded-lg shadow-xl
|
|
55
|
+
<div className="bg-white rounded-lg shadow-xl w-full p-4 flex-col relative">
|
|
71
56
|
<button
|
|
72
57
|
className="absolute text-gray-400 hover:text-gray-600 focus:outline-none"
|
|
73
58
|
style={{ top: "10px", right: "10px" }}
|
|
@@ -80,7 +65,7 @@ export function CopilotKitHelpModal() {
|
|
|
80
65
|
<h2 className="text-2xl font-bold">Help Options</h2>
|
|
81
66
|
</div>
|
|
82
67
|
<div className="space-y-4 mb-4">
|
|
83
|
-
<div className="
|
|
68
|
+
<div className="copilotKitHelpItemButton">
|
|
84
69
|
<a
|
|
85
70
|
href="https://docs.copilotkit.ai/coagents/troubleshooting/common-issues"
|
|
86
71
|
target="_blank"
|
|
@@ -89,7 +74,7 @@ export function CopilotKitHelpModal() {
|
|
|
89
74
|
Visit the Troubleshooting and FAQ section in the docs
|
|
90
75
|
</a>
|
|
91
76
|
</div>
|
|
92
|
-
<div className="
|
|
77
|
+
<div className="copilotKitHelpItemButton">
|
|
93
78
|
<a
|
|
94
79
|
href="https://go.copilotkit.ai/dev-console-support-discord"
|
|
95
80
|
target="_blank"
|
|
@@ -98,7 +83,7 @@ export function CopilotKitHelpModal() {
|
|
|
98
83
|
Go to Discord Support Channel (Community Support)
|
|
99
84
|
</a>
|
|
100
85
|
</div>
|
|
101
|
-
<div className="
|
|
86
|
+
<div className="copilotKitHelpItemButton">
|
|
102
87
|
<a
|
|
103
88
|
href="https://go.copilotkit.ai/dev-console-support-slack"
|
|
104
89
|
target="_blank"
|
|
@@ -108,57 +93,9 @@ export function CopilotKitHelpModal() {
|
|
|
108
93
|
</a>
|
|
109
94
|
</div>
|
|
110
95
|
</div>
|
|
111
|
-
<form onSubmit={handleSubmit} className="flex flex-col space-y-2">
|
|
112
|
-
<div>
|
|
113
|
-
<label htmlFor="feedback" className="block text-sm font-medium text-gray-700 mb-1">
|
|
114
|
-
Let us know what your issue is:
|
|
115
|
-
</label>
|
|
116
|
-
<textarea
|
|
117
|
-
id="feedback"
|
|
118
|
-
rows={4}
|
|
119
|
-
className="w-full px-3 py-2 text-gray-700 border rounded-lg focus:outline-none focus:border-blue-500"
|
|
120
|
-
placeholder="A Loom link / screen recording is always great!"
|
|
121
|
-
onChange={(e) => setIssueDescription(e.target.value)}
|
|
122
|
-
value={issueDescription}
|
|
123
|
-
required
|
|
124
|
-
></textarea>
|
|
125
|
-
</div>
|
|
126
|
-
<div>
|
|
127
|
-
<label htmlFor="email" className="block text-sm font-medium text-gray-700 mb-1">
|
|
128
|
-
Email (optional):
|
|
129
|
-
</label>
|
|
130
|
-
<input
|
|
131
|
-
type="email"
|
|
132
|
-
id="email"
|
|
133
|
-
className={`w-full px-3 py-2 text-gray-700 border rounded-lg focus:outline-none focus:border-blue-500 ${emailError ? "border-red-500" : ""}`}
|
|
134
|
-
placeholder="Enter your email for follow-up"
|
|
135
|
-
onChange={(e) => {
|
|
136
|
-
setEmail(e.target.value);
|
|
137
|
-
setEmailError("");
|
|
138
|
-
}}
|
|
139
|
-
value={email}
|
|
140
|
-
/>
|
|
141
|
-
{emailError && <p className="text-red-500 text-sm mt-1">{emailError}</p>}
|
|
142
|
-
</div>
|
|
143
|
-
<div className="bg-gray-50 px-4 py-4 sm:px-6 sm:flex sm:flex-row-reverse rounded-b-lg">
|
|
144
|
-
<button
|
|
145
|
-
type="submit"
|
|
146
|
-
onClick={handleSubmit}
|
|
147
|
-
disabled={submitButtonDisabled}
|
|
148
|
-
style={
|
|
149
|
-
submitButtonDisabled
|
|
150
|
-
? { backgroundColor: "rgb(216, 216, 216)", color: "rgb(129, 129, 129)" }
|
|
151
|
-
: undefined
|
|
152
|
-
}
|
|
153
|
-
className="w-full inline-flex justify-center rounded-md border border-transparent shadow-sm px-4 py-2 bg-blue-500 text-base font-medium text-white hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-blue-500 sm:ml-3 sm:w-auto sm:text-sm disabled:shadow-none"
|
|
154
|
-
>
|
|
155
|
-
{submitting ? <LoadingSpinnerIcon color="white" /> : "Submit"}
|
|
156
|
-
</button>
|
|
157
|
-
</div>
|
|
158
|
-
</form>
|
|
159
96
|
</div>
|
|
160
97
|
</div>
|
|
161
98
|
)}
|
|
162
|
-
|
|
99
|
+
</div>
|
|
163
100
|
);
|
|
164
101
|
}
|
package/src/css/button.css
CHANGED
|
@@ -5,22 +5,25 @@
|
|
|
5
5
|
align-items: center;
|
|
6
6
|
justify-content: center;
|
|
7
7
|
border-radius: 50%;
|
|
8
|
-
border: 1px solid
|
|
8
|
+
border: 1px solid var(--copilot-kit-contrast-color);
|
|
9
9
|
outline: none;
|
|
10
10
|
position: relative;
|
|
11
11
|
transform: scale(1);
|
|
12
|
-
transition:
|
|
12
|
+
transition: all 0.2s ease;
|
|
13
13
|
background-color: var(--copilot-kit-primary-color);
|
|
14
14
|
color: var(--copilot-kit-contrast-color);
|
|
15
15
|
cursor: pointer;
|
|
16
|
+
box-shadow: var(--copilot-kit-shadow-sm);
|
|
16
17
|
}
|
|
17
18
|
|
|
18
19
|
.copilotKitButton:hover {
|
|
19
|
-
transform: scale(1.
|
|
20
|
+
transform: scale(1.05);
|
|
21
|
+
box-shadow: var(--copilot-kit-shadow-md);
|
|
20
22
|
}
|
|
21
23
|
|
|
22
24
|
.copilotKitButton:active {
|
|
23
|
-
transform: scale(0.
|
|
25
|
+
transform: scale(0.95);
|
|
26
|
+
box-shadow: var(--copilot-kit-shadow-sm);
|
|
24
27
|
}
|
|
25
28
|
|
|
26
29
|
.copilotKitButtonIcon {
|
|
@@ -31,6 +34,14 @@
|
|
|
31
34
|
top: 50%;
|
|
32
35
|
left: 50%;
|
|
33
36
|
transform: translate(-50%, -50%);
|
|
37
|
+
display: flex;
|
|
38
|
+
align-items: center;
|
|
39
|
+
justify-content: center;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.copilotKitButtonIcon svg {
|
|
43
|
+
width: 1.5rem;
|
|
44
|
+
height: 1.5rem;
|
|
34
45
|
}
|
|
35
46
|
|
|
36
47
|
/* State when the chat is open */
|
package/src/css/colors.css
CHANGED
|
@@ -1,12 +1,33 @@
|
|
|
1
1
|
html {
|
|
2
|
-
--copilot-kit-primary-color: rgb(
|
|
3
|
-
--copilot-kit-contrast-color: rgb(255 255 255);
|
|
4
|
-
--copilot-kit-secondary-color: rgb(
|
|
5
|
-
--copilot-kit-secondary-contrast-color: rgb(0 0 0);
|
|
2
|
+
--copilot-kit-primary-color: rgb(28, 28, 28);
|
|
3
|
+
--copilot-kit-contrast-color: rgb(255, 255, 255);
|
|
4
|
+
--copilot-kit-secondary-color: rgb(83, 83, 83);
|
|
6
5
|
--copilot-kit-background-color: rgb(255 255 255);
|
|
7
|
-
--copilot-kit-muted-color: rgb(
|
|
8
|
-
--copilot-kit-
|
|
6
|
+
--copilot-kit-muted-color: rgb(200 200 200);
|
|
7
|
+
--copilot-kit-text-light-color: rgb(255 255 255);
|
|
8
|
+
--copilot-kit-text-dark-color: rgb(28, 28, 28);
|
|
9
|
+
--copilot-kit-separator-color: rgb(200 200 200);
|
|
9
10
|
--copilot-kit-scrollbar-color: rgba(0, 0, 0, 0.2);
|
|
11
|
+
--copilot-kit-header-color: rgb(255 255 255);
|
|
10
12
|
--copilot-kit-response-button-color: #333;
|
|
11
13
|
--copilot-kit-response-button-background-color: #fff;
|
|
14
|
+
--copilot-kit-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
|
|
15
|
+
--copilot-kit-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
|
|
16
|
+
--copilot-kit-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
|
17
|
+
|
|
18
|
+
.variant-blue {
|
|
19
|
+
--copilot-kit-primary-color: rgb(59 130 246);
|
|
20
|
+
--copilot-kit-contrast-color: rgb(255 255 255);
|
|
21
|
+
--copilot-kit-secondary-color: rgb(243 244 246);
|
|
22
|
+
--copilot-kit-background-color: rgb(255 255 255);
|
|
23
|
+
--copilot-kit-muted-color: rgb(200 200 200);
|
|
24
|
+
--copilot-kit-text-color: rgb(106 106 106);
|
|
25
|
+
--copilot-kit-separator-color: rgb(200 200 200);
|
|
26
|
+
--copilot-kit-scrollbar-color: rgba(0, 0, 0, 0.2);
|
|
27
|
+
--copilot-kit-response-button-color: #333;
|
|
28
|
+
--copilot-kit-response-button-background-color: #fff;
|
|
29
|
+
--copilot-kit-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
|
|
30
|
+
--copilot-kit-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
|
|
31
|
+
--copilot-kit-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
|
32
|
+
}
|
|
12
33
|
}
|
package/src/css/console.css
CHANGED
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
.copilotKitDevConsole {
|
|
2
|
-
background-color: #f3f4f6;
|
|
3
|
-
padding-left: 10px;
|
|
4
|
-
padding-right: 10px;
|
|
5
2
|
display: flex;
|
|
6
3
|
align-items: center;
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
padding-bottom: 10px;
|
|
4
|
+
gap: 5px;
|
|
5
|
+
margin: 0 15px;
|
|
10
6
|
}
|
|
11
7
|
|
|
12
8
|
.copilotKitDevConsole.copilotKitDevConsoleWarnOutdated {
|
|
@@ -14,23 +10,20 @@
|
|
|
14
10
|
}
|
|
15
11
|
|
|
16
12
|
.copilotKitDevConsole .copilotKitVersionInfo {
|
|
17
|
-
flex: 1;
|
|
18
|
-
margin-left: 18px;
|
|
19
13
|
display: flex;
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
margin-top: 10px;
|
|
14
|
+
position: absolute;
|
|
15
|
+
bottom: -25px;
|
|
16
|
+
padding: 3px 5px;
|
|
17
|
+
left: 0;
|
|
18
|
+
width: 100%;
|
|
19
|
+
justify-content: center;
|
|
20
|
+
gap: 10px;
|
|
21
|
+
font-size: 0.8rem;
|
|
22
|
+
align-items: center;
|
|
23
|
+
background: #ebb305;
|
|
31
24
|
}
|
|
32
25
|
|
|
33
|
-
.copilotKitDevConsole .copilotKitVersionInfo
|
|
26
|
+
.copilotKitDevConsole .copilotKitVersionInfo button {
|
|
34
27
|
font-size: 11px;
|
|
35
28
|
font-weight: normal;
|
|
36
29
|
font-family: monospace;
|
|
@@ -47,37 +40,33 @@
|
|
|
47
40
|
text-overflow: ellipsis;
|
|
48
41
|
}
|
|
49
42
|
|
|
50
|
-
.copilotKitDevConsole .copilotKitVersionInfo
|
|
43
|
+
.copilotKitDevConsole .copilotKitVersionInfo aside {
|
|
51
44
|
display: inline;
|
|
52
45
|
font-weight: normal;
|
|
53
46
|
color: #7f7a7a;
|
|
54
47
|
margin-left: 5px;
|
|
55
48
|
}
|
|
56
49
|
|
|
57
|
-
.copilotKitDevConsole .copilotKitVersionInfo
|
|
58
|
-
font-size: 11px;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.copilotKitDevConsole .copilotKitVersionInfo section svg {
|
|
50
|
+
.copilotKitDevConsole .copilotKitVersionInfo svg {
|
|
62
51
|
margin-left: 3px;
|
|
63
52
|
margin-top: -3px;
|
|
64
53
|
}
|
|
65
54
|
|
|
66
|
-
.copilotKitDevConsole .
|
|
55
|
+
.copilotKitDevConsole .copilotKitDebugMenuTriggerButton {
|
|
67
56
|
font-size: 11px;
|
|
68
57
|
font-weight: bold;
|
|
69
58
|
display: flex;
|
|
70
|
-
|
|
59
|
+
padding: 0 10px;
|
|
71
60
|
height: 30px;
|
|
72
|
-
background-color:
|
|
73
|
-
border: 1px solid
|
|
74
|
-
border-radius:
|
|
61
|
+
background-color: transparent;
|
|
62
|
+
border: 1px solid var(--copilot-kit-muted-color);
|
|
63
|
+
border-radius: 20px;
|
|
75
64
|
align-items: center;
|
|
76
65
|
justify-content: center;
|
|
77
66
|
outline: none;
|
|
78
67
|
}
|
|
79
68
|
|
|
80
|
-
.
|
|
69
|
+
.copilotKitDebugMenuTriggerButton.compact {
|
|
81
70
|
width: 35px;
|
|
82
71
|
color: black;
|
|
83
72
|
justify-content: center;
|
|
@@ -85,19 +74,21 @@
|
|
|
85
74
|
font-size: 8px;
|
|
86
75
|
}
|
|
87
76
|
|
|
88
|
-
.copilotKitDevConsole .
|
|
89
|
-
background-color:
|
|
77
|
+
.copilotKitDevConsole .copilotKitDebugMenuTriggerButton:hover {
|
|
78
|
+
background-color: color-mix(in srgb, var(--copilot-kit-dev-console-bg) 95%, black);
|
|
90
79
|
}
|
|
91
80
|
|
|
92
|
-
.copilotKitDevConsole .
|
|
81
|
+
.copilotKitDevConsole .copilotKitDebugMenuTriggerButton > svg {
|
|
93
82
|
margin-left: 10px;
|
|
94
83
|
}
|
|
95
84
|
|
|
96
85
|
.copilotKitDebugMenu {
|
|
97
|
-
|
|
86
|
+
--copilot-kit-dev-console-bg: #f8f8fa;
|
|
87
|
+
--copilot-kit-dev-console-border: color-mix(in srgb, var(--copilot-kit-dev-console-bg) 80%, black);
|
|
98
88
|
margin-top: 2px;
|
|
99
89
|
border-radius: 6px;
|
|
100
|
-
|
|
90
|
+
background-color: var(--copilot-kit-dev-console-bg);
|
|
91
|
+
border: 1px solid var(--copilot-kit-dev-console-border);
|
|
101
92
|
padding: 0.25rem;
|
|
102
93
|
outline: none;
|
|
103
94
|
font-size: 13px;
|
|
@@ -117,7 +108,7 @@
|
|
|
117
108
|
}
|
|
118
109
|
|
|
119
110
|
.copilotKitDebugMenuItem:hover {
|
|
120
|
-
background-color:
|
|
111
|
+
background-color: color-mix(in srgb, var(--copilot-kit-dev-console-bg) 92%, black);
|
|
121
112
|
border-radius: 4px;
|
|
122
113
|
}
|
|
123
114
|
|
|
@@ -129,6 +120,22 @@
|
|
|
129
120
|
.copilotKitDebugMenu hr {
|
|
130
121
|
height: 1px;
|
|
131
122
|
border: none; /* Remove 3D look */
|
|
132
|
-
background-color:
|
|
123
|
+
background-color: var(--copilot-kit-dev-console-border);
|
|
133
124
|
margin: 0.25rem;
|
|
134
125
|
}
|
|
126
|
+
|
|
127
|
+
.copilotKitHelpItemButton {
|
|
128
|
+
display: block;
|
|
129
|
+
text-align: center;
|
|
130
|
+
width: 100%;
|
|
131
|
+
padding: 4px 6px;
|
|
132
|
+
border-radius: 15px;
|
|
133
|
+
font-size: 0.8rem;
|
|
134
|
+
border: 1px solid var(--copilot-kit-muted-color);
|
|
135
|
+
color: var(--copilot-kit-text-color);
|
|
136
|
+
box-shadow: 0 5px 5px 0px rgba(0,0,0,.01),0 2px 3px 0px rgba(0,0,0,.02);
|
|
137
|
+
background-color: var(--copilot-kit-dev-console-bg);
|
|
138
|
+
}
|
|
139
|
+
.copilotKitHelpItemButton:hover {
|
|
140
|
+
background-color: #f9f9f9;
|
|
141
|
+
}
|
package/src/css/header.css
CHANGED
|
@@ -2,23 +2,29 @@
|
|
|
2
2
|
height: 56px;
|
|
3
3
|
font-weight: 500;
|
|
4
4
|
display: flex;
|
|
5
|
-
justify-content: center;
|
|
6
5
|
align-items: center;
|
|
7
6
|
position: relative;
|
|
8
|
-
background-color: var(--copilot-kit-primary-color);
|
|
9
7
|
color: var(--copilot-kit-contrast-color);
|
|
10
8
|
border-top-left-radius: 0;
|
|
11
9
|
border-top-right-radius: 0;
|
|
12
10
|
border-bottom: 1px solid var(--copilot-kit-separator-color);
|
|
11
|
+
padding-left: 1.5rem;
|
|
12
|
+
background-color: var(--copilot-kit-header-color); /* Adjust opacity to your preference */
|
|
13
|
+
justify-content: space-between;
|
|
14
|
+
z-index: 2;
|
|
13
15
|
}
|
|
14
16
|
|
|
15
17
|
.copilotKitSidebar .copilotKitHeader {
|
|
16
18
|
border-radius: 0;
|
|
17
19
|
}
|
|
18
20
|
|
|
21
|
+
.copilotKitHeaderControls {
|
|
22
|
+
display: flex;
|
|
23
|
+
}
|
|
24
|
+
|
|
19
25
|
@media (min-width: 640px) {
|
|
20
26
|
.copilotKitHeader {
|
|
21
|
-
padding-left:
|
|
27
|
+
padding-left: 1.5rem;
|
|
22
28
|
padding-right: 24px;
|
|
23
29
|
border-top-left-radius: 8px;
|
|
24
30
|
border-top-right-radius: 8px;
|
|
@@ -27,15 +33,26 @@
|
|
|
27
33
|
|
|
28
34
|
.copilotKitHeader > button {
|
|
29
35
|
border: 0;
|
|
30
|
-
padding:
|
|
36
|
+
padding: 8px;
|
|
31
37
|
position: absolute;
|
|
32
38
|
top: 50%;
|
|
33
39
|
right: 16px;
|
|
34
40
|
transform: translateY(-50%);
|
|
35
41
|
outline: none;
|
|
36
|
-
color: var(--copilot-kit-
|
|
42
|
+
color: var(--copilot-kit-muted-color);
|
|
37
43
|
background-color: transparent;
|
|
38
44
|
cursor: pointer;
|
|
45
|
+
border-radius: 50%;
|
|
46
|
+
display: flex;
|
|
47
|
+
align-items: center;
|
|
48
|
+
justify-content: center;
|
|
49
|
+
transition: background-color 0.2s ease;
|
|
50
|
+
width: 35px;
|
|
51
|
+
height: 35px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.copilotKitHeader > button:hover {
|
|
55
|
+
color: color-mix(in srgb, var(--copilot-kit-muted-color) 80%, black);
|
|
39
56
|
}
|
|
40
57
|
|
|
41
58
|
.copilotKitHeader > button:focus {
|
package/src/css/input.css
CHANGED
|
@@ -1,20 +1,23 @@
|
|
|
1
1
|
.copilotKitInput {
|
|
2
|
-
border-top: 1px solid var(--copilot-kit-separator-color);
|
|
3
|
-
padding-left: 2rem;
|
|
4
|
-
padding-right: 1rem;
|
|
5
|
-
padding-top: 1rem;
|
|
6
|
-
padding-bottom: 1rem;
|
|
7
2
|
display: flex;
|
|
8
|
-
|
|
3
|
+
flex-direction: column;
|
|
9
4
|
cursor: text;
|
|
10
5
|
position: relative;
|
|
11
|
-
|
|
12
|
-
border-
|
|
13
|
-
|
|
6
|
+
background-color: #fbfbfb;
|
|
7
|
+
border-radius: 20px;
|
|
8
|
+
border: 1px solid var(--copilot-kit-separator-color);
|
|
9
|
+
padding: 12px 14px;
|
|
10
|
+
height: 75px;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.copilotKitInputContainer {
|
|
14
|
+
width: 95%;
|
|
15
|
+
margin: 0 auto;
|
|
16
|
+
padding: 0 0 15px 0;
|
|
14
17
|
}
|
|
15
18
|
|
|
16
19
|
.copilotKitInput > .copilotKitInputControls > button {
|
|
17
|
-
padding: 0
|
|
20
|
+
padding: 0;
|
|
18
21
|
cursor: pointer;
|
|
19
22
|
transition-property: transform;
|
|
20
23
|
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
@@ -36,7 +39,8 @@
|
|
|
36
39
|
text-shadow: none;
|
|
37
40
|
display: inline-block;
|
|
38
41
|
text-align: center;
|
|
39
|
-
|
|
42
|
+
width: 24px;
|
|
43
|
+
height: 24px;
|
|
40
44
|
}
|
|
41
45
|
|
|
42
46
|
.copilotKitInput > .copilotKitInputControls > button:not([disabled]) {
|
|
@@ -44,15 +48,18 @@
|
|
|
44
48
|
}
|
|
45
49
|
|
|
46
50
|
.copilotKitInput > .copilotKitInputControls > button:not([disabled]):hover {
|
|
47
|
-
|
|
51
|
+
color: color-mix(in srgb, var(--copilot-kit-primary-color) 80%, black);
|
|
52
|
+
transform: scale(1.05);
|
|
48
53
|
}
|
|
49
54
|
|
|
50
55
|
.copilotKitInput > .copilotKitInputControls > button[disabled] {
|
|
51
56
|
color: var(--copilot-kit-muted-color);
|
|
57
|
+
cursor: default;
|
|
52
58
|
}
|
|
53
59
|
|
|
54
60
|
.copilotKitInputControls {
|
|
55
61
|
display: flex;
|
|
62
|
+
gap: 3px;
|
|
56
63
|
}
|
|
57
64
|
|
|
58
65
|
.copilotKitInput > textarea {
|
|
@@ -66,23 +73,23 @@
|
|
|
66
73
|
-moz-osx-font-smoothing: grayscale;
|
|
67
74
|
cursor: text;
|
|
68
75
|
font-size: 0.875rem;
|
|
69
|
-
line-height: 1.
|
|
76
|
+
line-height: 1.5rem;
|
|
70
77
|
margin: 0;
|
|
71
78
|
padding: 0;
|
|
72
79
|
font-family: inherit;
|
|
73
80
|
font-weight: inherit;
|
|
74
|
-
color: var(--copilot-kit-
|
|
81
|
+
color: var(--copilot-kit-text-color);
|
|
75
82
|
border: 0px;
|
|
76
|
-
background-color:
|
|
83
|
+
background-color: #fbfbfb;
|
|
77
84
|
}
|
|
78
85
|
|
|
79
86
|
.copilotKitInput > textarea::placeholder {
|
|
80
|
-
color:
|
|
87
|
+
color: #808080;
|
|
81
88
|
opacity: 1;
|
|
82
89
|
}
|
|
83
90
|
|
|
84
91
|
.copilotKitInput > .copilotKitInputControls > button.copilotKitPushToTalkRecording {
|
|
85
|
-
background-color:
|
|
92
|
+
background-color: #ec0000;
|
|
86
93
|
color: white;
|
|
87
94
|
border-radius: 50%;
|
|
88
95
|
animation: copilotKitPulseAnimation 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
|
package/src/css/markdown.css
CHANGED
|
@@ -45,6 +45,8 @@
|
|
|
45
45
|
.copilotKitMarkdown p {
|
|
46
46
|
padding: 0px;
|
|
47
47
|
margin: 0px;
|
|
48
|
+
line-height: 1.75;
|
|
49
|
+
font-size: 1rem;
|
|
48
50
|
}
|
|
49
51
|
|
|
50
52
|
.copilotKitMarkdown p:not(:last-child),
|
|
@@ -126,7 +128,6 @@
|
|
|
126
128
|
line-height: 1.25rem;
|
|
127
129
|
font-weight: 500;
|
|
128
130
|
height: 2.5rem;
|
|
129
|
-
width: 2.5rem;
|
|
130
131
|
padding: 3px;
|
|
131
132
|
margin: 2px;
|
|
132
133
|
}
|