@copilotkit/react-ui 0.22.0-function-calling-fixes.2 → 0.22.0-mme-cloud.0

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.
Files changed (45) hide show
  1. package/.turbo/turbo-build.log +186 -190
  2. package/CHANGELOG.md +4 -28
  3. package/dist/components/chat/Button.mjs +6 -30
  4. package/dist/components/chat/Button.mjs.map +1 -1
  5. package/dist/components/chat/Chat.mjs +16 -1198
  6. package/dist/components/chat/Chat.mjs.map +1 -1
  7. package/dist/components/chat/ChatContext.mjs +7 -217
  8. package/dist/components/chat/ChatContext.mjs.map +1 -1
  9. package/dist/components/chat/CodeBlock.mjs +8 -483
  10. package/dist/components/chat/CodeBlock.mjs.map +1 -1
  11. package/dist/components/chat/Header.mjs +6 -23
  12. package/dist/components/chat/Header.mjs.map +1 -1
  13. package/dist/components/chat/Icons.mjs +14 -218
  14. package/dist/components/chat/Icons.mjs.map +1 -1
  15. package/dist/components/chat/Input.mjs +7 -116
  16. package/dist/components/chat/Input.mjs.map +1 -1
  17. package/dist/components/chat/Markdown.mjs +7 -547
  18. package/dist/components/chat/Markdown.mjs.map +1 -1
  19. package/dist/components/chat/Messages.mjs +9 -678
  20. package/dist/components/chat/Messages.mjs.map +1 -1
  21. package/dist/components/chat/Popup.mjs +17 -1207
  22. package/dist/components/chat/Popup.mjs.map +1 -1
  23. package/dist/components/chat/Response.mjs +6 -23
  24. package/dist/components/chat/Response.mjs.map +1 -1
  25. package/dist/components/chat/Sidebar.mjs +17 -1218
  26. package/dist/components/chat/Sidebar.mjs.map +1 -1
  27. package/dist/components/chat/Textarea.mjs +4 -48
  28. package/dist/components/chat/Textarea.mjs.map +1 -1
  29. package/dist/components/chat/Window.mjs +4 -105
  30. package/dist/components/chat/Window.mjs.map +1 -1
  31. package/dist/components/chat/index.mjs +24 -1225
  32. package/dist/components/chat/index.mjs.map +1 -1
  33. package/dist/components/chat/props.mjs +1 -0
  34. package/dist/components/index.mjs +25 -1225
  35. package/dist/components/index.mjs.map +1 -1
  36. package/dist/context/index.mjs +1 -0
  37. package/dist/hooks/index.mjs +1 -0
  38. package/dist/hooks/use-copy-to-clipboard.mjs +4 -21
  39. package/dist/hooks/use-copy-to-clipboard.mjs.map +1 -1
  40. package/dist/index.mjs +28 -1225
  41. package/dist/index.mjs.map +1 -1
  42. package/dist/lib/utils.mjs +3 -20
  43. package/dist/lib/utils.mjs.map +1 -1
  44. package/dist/types/index.mjs +1 -0
  45. package/package.json +6 -6
@@ -1,550 +1,10 @@
1
- var __defProp = Object.defineProperty;
2
- var __defProps = Object.defineProperties;
3
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
- var __spreadValues = (a, b) => {
9
- for (var prop in b || (b = {}))
10
- if (__hasOwnProp.call(b, prop))
11
- __defNormalProp(a, prop, b[prop]);
12
- if (__getOwnPropSymbols)
13
- for (var prop of __getOwnPropSymbols(b)) {
14
- if (__propIsEnum.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- }
17
- return a;
18
- };
19
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
- var __objRest = (source, exclude) => {
21
- var target = {};
22
- for (var prop in source)
23
- if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
24
- target[prop] = source[prop];
25
- if (source != null && __getOwnPropSymbols)
26
- for (var prop of __getOwnPropSymbols(source)) {
27
- if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
28
- target[prop] = source[prop];
29
- }
30
- return target;
31
- };
32
-
33
- // src/components/chat/Markdown.tsx
34
- import { memo as memo2 } from "react";
35
- import ReactMarkdown from "react-markdown";
36
-
37
- // src/components/chat/CodeBlock.tsx
38
- import { memo } from "react";
39
- import { Prism as SyntaxHighlighter } from "react-syntax-highlighter";
40
-
41
- // src/hooks/use-copy-to-clipboard.tsx
42
- import * as React from "react";
43
- function useCopyToClipboard({ timeout = 2e3 }) {
44
- const [isCopied, setIsCopied] = React.useState(false);
45
- const copyToClipboard = (value) => {
46
- var _a;
47
- if (typeof window === "undefined" || !((_a = navigator.clipboard) == null ? void 0 : _a.writeText)) {
48
- return;
49
- }
50
- if (!value) {
51
- return;
52
- }
53
- navigator.clipboard.writeText(value).then(() => {
54
- setIsCopied(true);
55
- setTimeout(() => {
56
- setIsCopied(false);
57
- }, timeout);
58
- });
59
- };
60
- return { isCopied, copyToClipboard };
61
- }
62
-
63
- // src/components/chat/Icons.tsx
64
- import { jsx, jsxs } from "react/jsx-runtime";
65
- function CheckIcon(_a) {
66
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
67
- return /* @__PURE__ */ jsx(
68
- "svg",
69
- __spreadProps(__spreadValues({
70
- xmlns: "http://www.w3.org/2000/svg",
71
- viewBox: "0 0 256 256",
72
- fill: "currentColor",
73
- style: { height: "1rem", width: "1rem" },
74
- className
75
- }, props), {
76
- children: /* @__PURE__ */ jsx("path", { d: "m229.66 77.66-128 128a8 8 0 0 1-11.32 0l-56-56a8 8 0 0 1 11.32-11.32L96 188.69 218.34 66.34a8 8 0 0 1 11.32 11.32Z" })
77
- })
78
- );
79
- }
80
- function DownloadIcon(_a) {
81
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
82
- return /* @__PURE__ */ jsx(
83
- "svg",
84
- __spreadProps(__spreadValues({
85
- xmlns: "http://www.w3.org/2000/svg",
86
- viewBox: "0 0 256 256",
87
- fill: "currentColor",
88
- style: { height: "1rem", width: "1rem" },
89
- className
90
- }, props), {
91
- children: /* @__PURE__ */ jsx("path", { d: "M224 152v56a16 16 0 0 1-16 16H48a16 16 0 0 1-16-16v-56a8 8 0 0 1 16 0v56h160v-56a8 8 0 0 1 16 0Zm-101.66 5.66a8 8 0 0 0 11.32 0l40-40a8 8 0 0 0-11.32-11.32L136 132.69V40a8 8 0 0 0-16 0v92.69l-26.34-26.35a8 8 0 0 0-11.32 11.32Z" })
92
- })
93
- );
94
- }
95
- function CopyIcon(_a) {
96
- var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
97
- return /* @__PURE__ */ jsx(
98
- "svg",
99
- __spreadProps(__spreadValues({
100
- xmlns: "http://www.w3.org/2000/svg",
101
- viewBox: "0 0 256 256",
102
- fill: "currentColor",
103
- style: { height: "1rem", width: "1rem" },
104
- className
105
- }, props), {
106
- children: /* @__PURE__ */ jsx("path", { d: "M216 32H88a8 8 0 0 0-8 8v40H40a8 8 0 0 0-8 8v128a8 8 0 0 0 8 8h128a8 8 0 0 0 8-8v-40h40a8 8 0 0 0 8-8V40a8 8 0 0 0-8-8Zm-56 176H48V96h112Zm48-48h-32V88a8 8 0 0 0-8-8H96V48h112Z" })
107
- })
108
- );
109
- }
110
-
111
- // src/components/chat/CodeBlock.tsx
112
- import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
113
- var programmingLanguages = {
114
- javascript: ".js",
115
- python: ".py",
116
- java: ".java",
117
- c: ".c",
118
- cpp: ".cpp",
119
- "c++": ".cpp",
120
- "c#": ".cs",
121
- ruby: ".rb",
122
- php: ".php",
123
- swift: ".swift",
124
- "objective-c": ".m",
125
- kotlin: ".kt",
126
- typescript: ".ts",
127
- go: ".go",
128
- perl: ".pl",
129
- rust: ".rs",
130
- scala: ".scala",
131
- haskell: ".hs",
132
- lua: ".lua",
133
- shell: ".sh",
134
- sql: ".sql",
135
- html: ".html",
136
- css: ".css"
137
- // add more file extensions here, make sure the key is same as language prop in CodeBlock.tsx component
138
- };
139
- var generateRandomString = (length, lowercase = false) => {
140
- const chars = "ABCDEFGHJKLMNPQRSTUVWXY3456789";
141
- let result = "";
142
- for (let i = 0; i < length; i++) {
143
- result += chars.charAt(Math.floor(Math.random() * chars.length));
144
- }
145
- return lowercase ? result.toLowerCase() : result;
146
- };
147
- var CodeBlock = memo(({ language, value }) => {
148
- const { isCopied, copyToClipboard } = useCopyToClipboard({ timeout: 2e3 });
149
- const downloadAsFile = () => {
150
- if (typeof window === "undefined") {
151
- return;
152
- }
153
- const fileExtension = programmingLanguages[language] || ".file";
154
- const suggestedFileName = `file-${generateRandomString(3, true)}${fileExtension}`;
155
- const fileName = window.prompt("Enter file name", suggestedFileName);
156
- if (!fileName) {
157
- return;
158
- }
159
- const blob = new Blob([value], { type: "text/plain" });
160
- const url = URL.createObjectURL(blob);
161
- const link = document.createElement("a");
162
- link.download = fileName;
163
- link.href = url;
164
- link.style.display = "none";
165
- document.body.appendChild(link);
166
- link.click();
167
- document.body.removeChild(link);
168
- URL.revokeObjectURL(url);
169
- };
170
- const onCopy = () => {
171
- if (isCopied)
172
- return;
173
- copyToClipboard(value);
174
- };
175
- return /* @__PURE__ */ jsxs2("div", { className: "copilotKitCodeBlock", children: [
176
- /* @__PURE__ */ jsxs2("div", { className: "copilotKitCodeBlockToolbar", children: [
177
- /* @__PURE__ */ jsx2("span", { className: "copilotKitCodeBlockToolbarLanguage", children: language }),
178
- /* @__PURE__ */ jsxs2("div", { className: "copilotKitCodeBlockToolbarButtons", children: [
179
- /* @__PURE__ */ jsxs2("button", { className: "copilotKitCodeBlockToolbarButton", onClick: downloadAsFile, children: [
180
- /* @__PURE__ */ jsx2(DownloadIcon, {}),
181
- /* @__PURE__ */ jsx2("span", { className: "sr-only", children: "Download" })
182
- ] }),
183
- /* @__PURE__ */ jsxs2("button", { className: "copilotKitCodeBlockToolbarButton", onClick: onCopy, children: [
184
- isCopied ? /* @__PURE__ */ jsx2(CheckIcon, {}) : /* @__PURE__ */ jsx2(CopyIcon, {}),
185
- /* @__PURE__ */ jsx2("span", { className: "sr-only", children: "Copy code" })
186
- ] })
187
- ] })
188
- ] }),
189
- /* @__PURE__ */ jsx2(
190
- SyntaxHighlighter,
191
- {
192
- language,
193
- style: highlightStyle,
194
- PreTag: "div",
195
- customStyle: {
196
- margin: 0,
197
- borderBottomLeftRadius: "0.375rem",
198
- borderBottomRightRadius: "0.375rem"
199
- },
200
- children: value
201
- }
202
- )
203
- ] });
204
- });
205
- CodeBlock.displayName = "CodeBlock";
206
- var highlightStyle = {
207
- 'pre[class*="language-"]': {
208
- color: "#d4d4d4",
209
- fontSize: "13px",
210
- textShadow: "none",
211
- fontFamily: 'Menlo, Monaco, Consolas, "Andale Mono", "Ubuntu Mono", "Courier New", monospace',
212
- direction: "ltr",
213
- textAlign: "left",
214
- whiteSpace: "pre",
215
- wordSpacing: "normal",
216
- wordBreak: "normal",
217
- lineHeight: "1.5",
218
- MozTabSize: "4",
219
- OTabSize: "4",
220
- tabSize: "4",
221
- WebkitHyphens: "none",
222
- MozHyphens: "none",
223
- msHyphens: "none",
224
- hyphens: "none",
225
- padding: "1em",
226
- margin: ".5em 0",
227
- overflow: "auto",
228
- background: "#1e1e1e"
229
- },
230
- 'code[class*="language-"]': {
231
- color: "#d4d4d4",
232
- fontSize: "13px",
233
- textShadow: "none",
234
- fontFamily: 'Menlo, Monaco, Consolas, "Andale Mono", "Ubuntu Mono", "Courier New", monospace',
235
- direction: "ltr",
236
- textAlign: "left",
237
- whiteSpace: "pre",
238
- wordSpacing: "normal",
239
- wordBreak: "normal",
240
- lineHeight: "1.5",
241
- MozTabSize: "4",
242
- OTabSize: "4",
243
- tabSize: "4",
244
- WebkitHyphens: "none",
245
- MozHyphens: "none",
246
- msHyphens: "none",
247
- hyphens: "none"
248
- },
249
- 'pre[class*="language-"]::selection': {
250
- textShadow: "none",
251
- background: "#264F78"
252
- },
253
- 'code[class*="language-"]::selection': {
254
- textShadow: "none",
255
- background: "#264F78"
256
- },
257
- 'pre[class*="language-"] *::selection': {
258
- textShadow: "none",
259
- background: "#264F78"
260
- },
261
- 'code[class*="language-"] *::selection': {
262
- textShadow: "none",
263
- background: "#264F78"
264
- },
265
- ':not(pre) > code[class*="language-"]': {
266
- padding: ".1em .3em",
267
- borderRadius: ".3em",
268
- color: "#db4c69",
269
- background: "#1e1e1e"
270
- },
271
- ".namespace": {
272
- Opacity: ".7"
273
- },
274
- "doctype.doctype-tag": {
275
- color: "#569CD6"
276
- },
277
- "doctype.name": {
278
- color: "#9cdcfe"
279
- },
280
- comment: {
281
- color: "#6a9955"
282
- },
283
- prolog: {
284
- color: "#6a9955"
285
- },
286
- punctuation: {
287
- color: "#d4d4d4"
288
- },
289
- ".language-html .language-css .token.punctuation": {
290
- color: "#d4d4d4"
291
- },
292
- ".language-html .language-javascript .token.punctuation": {
293
- color: "#d4d4d4"
294
- },
295
- property: {
296
- color: "#9cdcfe"
297
- },
298
- tag: {
299
- color: "#569cd6"
300
- },
301
- boolean: {
302
- color: "#569cd6"
303
- },
304
- number: {
305
- color: "#b5cea8"
306
- },
307
- constant: {
308
- color: "#9cdcfe"
309
- },
310
- symbol: {
311
- color: "#b5cea8"
312
- },
313
- inserted: {
314
- color: "#b5cea8"
315
- },
316
- unit: {
317
- color: "#b5cea8"
318
- },
319
- selector: {
320
- color: "#d7ba7d"
321
- },
322
- "attr-name": {
323
- color: "#9cdcfe"
324
- },
325
- string: {
326
- color: "#ce9178"
327
- },
328
- char: {
329
- color: "#ce9178"
330
- },
331
- builtin: {
332
- color: "#ce9178"
333
- },
334
- deleted: {
335
- color: "#ce9178"
336
- },
337
- ".language-css .token.string.url": {
338
- textDecoration: "underline"
339
- },
340
- operator: {
341
- color: "#d4d4d4"
342
- },
343
- entity: {
344
- color: "#569cd6"
345
- },
346
- "operator.arrow": {
347
- color: "#569CD6"
348
- },
349
- atrule: {
350
- color: "#ce9178"
351
- },
352
- "atrule.rule": {
353
- color: "#c586c0"
354
- },
355
- "atrule.url": {
356
- color: "#9cdcfe"
357
- },
358
- "atrule.url.function": {
359
- color: "#dcdcaa"
360
- },
361
- "atrule.url.punctuation": {
362
- color: "#d4d4d4"
363
- },
364
- keyword: {
365
- color: "#569CD6"
366
- },
367
- "keyword.module": {
368
- color: "#c586c0"
369
- },
370
- "keyword.control-flow": {
371
- color: "#c586c0"
372
- },
373
- function: {
374
- color: "#dcdcaa"
375
- },
376
- "function.maybe-class-name": {
377
- color: "#dcdcaa"
378
- },
379
- regex: {
380
- color: "#d16969"
381
- },
382
- important: {
383
- color: "#569cd6"
384
- },
385
- italic: {
386
- fontStyle: "italic"
387
- },
388
- "class-name": {
389
- color: "#4ec9b0"
390
- },
391
- "maybe-class-name": {
392
- color: "#4ec9b0"
393
- },
394
- console: {
395
- color: "#9cdcfe"
396
- },
397
- parameter: {
398
- color: "#9cdcfe"
399
- },
400
- interpolation: {
401
- color: "#9cdcfe"
402
- },
403
- "punctuation.interpolation-punctuation": {
404
- color: "#569cd6"
405
- },
406
- variable: {
407
- color: "#9cdcfe"
408
- },
409
- "imports.maybe-class-name": {
410
- color: "#9cdcfe"
411
- },
412
- "exports.maybe-class-name": {
413
- color: "#9cdcfe"
414
- },
415
- escape: {
416
- color: "#d7ba7d"
417
- },
418
- "tag.punctuation": {
419
- color: "#808080"
420
- },
421
- cdata: {
422
- color: "#808080"
423
- },
424
- "attr-value": {
425
- color: "#ce9178"
426
- },
427
- "attr-value.punctuation": {
428
- color: "#ce9178"
429
- },
430
- "attr-value.punctuation.attr-equals": {
431
- color: "#d4d4d4"
432
- },
433
- namespace: {
434
- color: "#4ec9b0"
435
- },
436
- 'pre[class*="language-javascript"]': {
437
- color: "#9cdcfe"
438
- },
439
- 'code[class*="language-javascript"]': {
440
- color: "#9cdcfe"
441
- },
442
- 'pre[class*="language-jsx"]': {
443
- color: "#9cdcfe"
444
- },
445
- 'code[class*="language-jsx"]': {
446
- color: "#9cdcfe"
447
- },
448
- 'pre[class*="language-typescript"]': {
449
- color: "#9cdcfe"
450
- },
451
- 'code[class*="language-typescript"]': {
452
- color: "#9cdcfe"
453
- },
454
- 'pre[class*="language-tsx"]': {
455
- color: "#9cdcfe"
456
- },
457
- 'code[class*="language-tsx"]': {
458
- color: "#9cdcfe"
459
- },
460
- 'pre[class*="language-css"]': {
461
- color: "#ce9178"
462
- },
463
- 'code[class*="language-css"]': {
464
- color: "#ce9178"
465
- },
466
- 'pre[class*="language-html"]': {
467
- color: "#d4d4d4"
468
- },
469
- 'code[class*="language-html"]': {
470
- color: "#d4d4d4"
471
- },
472
- ".language-regex .token.anchor": {
473
- color: "#dcdcaa"
474
- },
475
- ".language-html .token.punctuation": {
476
- color: "#808080"
477
- },
478
- 'pre[class*="language-"] > code[class*="language-"]': {
479
- position: "relative",
480
- zIndex: "1"
481
- },
482
- ".line-highlight.line-highlight": {
483
- background: "#f7ebc6",
484
- boxShadow: "inset 5px 0 0 #f7d87c",
485
- zIndex: "0"
486
- }
487
- };
488
-
489
- // src/components/chat/Markdown.tsx
490
- import remarkGfm from "remark-gfm";
491
- import remarkMath from "remark-math";
492
- import { jsx as jsx3 } from "react/jsx-runtime";
493
- var MemoizedReactMarkdown = memo2(
494
- ReactMarkdown,
495
- (prevProps, nextProps) => prevProps.children === nextProps.children && prevProps.className === nextProps.className
496
- );
497
- var Markdown = ({ content }) => {
498
- return /* @__PURE__ */ jsx3("div", { className: "copilotKitMarkdown", children: /* @__PURE__ */ jsx3(MemoizedReactMarkdown, { components, remarkPlugins: [remarkGfm, remarkMath], children: content }) });
499
- };
500
- var components = {
501
- p({ children }) {
502
- return /* @__PURE__ */ jsx3("p", { children });
503
- },
504
- a(_a) {
505
- var _b = _a, { children } = _b, props = __objRest(_b, ["children"]);
506
- return /* @__PURE__ */ jsx3(
507
- "a",
508
- __spreadProps(__spreadValues({
509
- style: { color: "blue", textDecoration: "underline" }
510
- }, props), {
511
- target: "_blank",
512
- rel: "noopener noreferrer",
513
- children
514
- })
515
- );
516
- },
517
- code(_c) {
518
- var _d = _c, { children, className, inline } = _d, props = __objRest(_d, ["children", "className", "inline"]);
519
- if (children.length) {
520
- if (children[0] == "\u258D") {
521
- return /* @__PURE__ */ jsx3(
522
- "span",
523
- {
524
- style: {
525
- animation: "pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite",
526
- marginTop: "0.25rem"
527
- },
528
- children: "\u258D"
529
- }
530
- );
531
- }
532
- children[0] = children[0].replace("`\u258D`", "\u258D");
533
- }
534
- const match = /language-(\w+)/.exec(className || "");
535
- if (inline) {
536
- return /* @__PURE__ */ jsx3("code", __spreadProps(__spreadValues({ className }, props), { children }));
537
- }
538
- return /* @__PURE__ */ jsx3(
539
- CodeBlock,
540
- __spreadValues({
541
- language: match && match[1] || "",
542
- value: String(children).replace(/\n$/, "")
543
- }, props),
544
- Math.random()
545
- );
546
- }
547
- };
1
+ import {
2
+ Markdown
3
+ } from "../../chunk-WDHLWSSU.mjs";
4
+ import "../../chunk-MBYUBR3F.mjs";
5
+ import "../../chunk-7YXG7D47.mjs";
6
+ import "../../chunk-54JAUBUJ.mjs";
7
+ import "../../chunk-MRXNTQOX.mjs";
548
8
  export {
549
9
  Markdown
550
10
  };
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/components/chat/Markdown.tsx","../../../src/components/chat/CodeBlock.tsx","../../../src/hooks/use-copy-to-clipboard.tsx","../../../src/components/chat/Icons.tsx"],"sourcesContent":["import { FC, memo } from \"react\";\nimport ReactMarkdown, { Options, Components } from \"react-markdown\";\nimport { CodeBlock } from \"./CodeBlock\";\nimport remarkGfm from \"remark-gfm\";\nimport remarkMath from \"remark-math\";\n\nconst MemoizedReactMarkdown: FC<Options> = memo(\n ReactMarkdown,\n (prevProps, nextProps) =>\n prevProps.children === nextProps.children && prevProps.className === nextProps.className,\n);\n\ntype MarkdownProps = {\n content: string;\n};\n\nexport const Markdown = ({ content }: MarkdownProps) => {\n return (\n <div className=\"copilotKitMarkdown\">\n <MemoizedReactMarkdown components={components} remarkPlugins={[remarkGfm, remarkMath]}>\n {content}\n </MemoizedReactMarkdown>\n </div>\n );\n};\n\nconst components: Components = {\n p({ children }) {\n return <p>{children}</p>;\n },\n a({ children, ...props }) {\n return (\n <a\n style={{ color: \"blue\", textDecoration: \"underline\" }}\n {...props}\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n {children}\n </a>\n );\n },\n code({ children, className, inline, ...props }) {\n if (children.length) {\n if (children[0] == \"▍\") {\n return (\n <span\n style={{\n animation: \"pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite\",\n marginTop: \"0.25rem\",\n }}\n >\n ▍\n </span>\n );\n }\n\n children[0] = (children[0] as string).replace(\"`▍`\", \"▍\");\n }\n\n const match = /language-(\\w+)/.exec(className || \"\");\n\n if (inline) {\n return (\n <code className={className} {...props}>\n {children}\n </code>\n );\n }\n\n return (\n <CodeBlock\n key={Math.random()}\n language={(match && match[1]) || \"\"}\n value={String(children).replace(/\\n$/, \"\")}\n {...props}\n />\n );\n },\n};\n","import { FC, memo } from \"react\";\nimport { Prism as SyntaxHighlighter } from \"react-syntax-highlighter\";\nimport { useCopyToClipboard } from \"../../hooks/use-copy-to-clipboard\";\nimport { CheckIcon, CopyIcon, DownloadIcon } from \"./Icons\";\n\ninterface CodeActionButtonProps {\n onClick: () => void;\n children: React.ReactNode;\n}\n\ninterface Props {\n language: string;\n value: string;\n}\n\ninterface languageMap {\n [key: string]: string | undefined;\n}\n\nexport const programmingLanguages: languageMap = {\n javascript: \".js\",\n python: \".py\",\n java: \".java\",\n c: \".c\",\n cpp: \".cpp\",\n \"c++\": \".cpp\",\n \"c#\": \".cs\",\n ruby: \".rb\",\n php: \".php\",\n swift: \".swift\",\n \"objective-c\": \".m\",\n kotlin: \".kt\",\n typescript: \".ts\",\n go: \".go\",\n perl: \".pl\",\n rust: \".rs\",\n scala: \".scala\",\n haskell: \".hs\",\n lua: \".lua\",\n shell: \".sh\",\n sql: \".sql\",\n html: \".html\",\n css: \".css\",\n // add more file extensions here, make sure the key is same as language prop in CodeBlock.tsx component\n};\n\nexport const generateRandomString = (length: number, lowercase = false) => {\n const chars = \"ABCDEFGHJKLMNPQRSTUVWXY3456789\"; // excluding similar looking characters like Z, 2, I, 1, O, 0\n let result = \"\";\n for (let i = 0; i < length; i++) {\n result += chars.charAt(Math.floor(Math.random() * chars.length));\n }\n return lowercase ? result.toLowerCase() : result;\n};\n\nconst CodeBlock: FC<Props> = memo(({ language, value }) => {\n const { isCopied, copyToClipboard } = useCopyToClipboard({ timeout: 2000 });\n\n const downloadAsFile = () => {\n if (typeof window === \"undefined\") {\n return;\n }\n const fileExtension = programmingLanguages[language] || \".file\";\n const suggestedFileName = `file-${generateRandomString(3, true)}${fileExtension}`;\n const fileName = window.prompt(\"Enter file name\" || \"\", suggestedFileName);\n\n if (!fileName) {\n // User pressed cancel on prompt.\n return;\n }\n\n const blob = new Blob([value], { type: \"text/plain\" });\n const url = URL.createObjectURL(blob);\n const link = document.createElement(\"a\");\n link.download = fileName;\n link.href = url;\n link.style.display = \"none\";\n document.body.appendChild(link);\n link.click();\n document.body.removeChild(link);\n URL.revokeObjectURL(url);\n };\n\n const onCopy = () => {\n if (isCopied) return;\n copyToClipboard(value);\n };\n\n return (\n <div className=\"copilotKitCodeBlock\">\n <div className=\"copilotKitCodeBlockToolbar\">\n <span className=\"copilotKitCodeBlockToolbarLanguage\">{language}</span>\n <div className=\"copilotKitCodeBlockToolbarButtons\">\n <button className=\"copilotKitCodeBlockToolbarButton\" onClick={downloadAsFile}>\n <DownloadIcon />\n <span className=\"sr-only\">Download</span>\n </button>\n <button className=\"copilotKitCodeBlockToolbarButton\" onClick={onCopy}>\n {isCopied ? <CheckIcon /> : <CopyIcon />}\n <span className=\"sr-only\">Copy code</span>\n </button>\n </div>\n </div>\n <SyntaxHighlighter\n language={language}\n style={highlightStyle}\n PreTag=\"div\"\n customStyle={{\n margin: 0,\n borderBottomLeftRadius: \"0.375rem\",\n borderBottomRightRadius: \"0.375rem\",\n }}\n >\n {value}\n </SyntaxHighlighter>\n </div>\n );\n});\nCodeBlock.displayName = \"CodeBlock\";\n\nexport { CodeBlock };\n\n// import { vscDarkPlus as highlightStyle } from \"react-syntax-highlighter/dist/esm/styles/prism\";\n// As a workaround, we inline the vscDarkPlus from react-syntax-highlighter.\n// Importing it as recommended in the documentation leads to build errors in the non app router\n// (Next.js classic) setup.\nconst highlightStyle: any = {\n 'pre[class*=\"language-\"]': {\n color: \"#d4d4d4\",\n fontSize: \"13px\",\n textShadow: \"none\",\n fontFamily: 'Menlo, Monaco, Consolas, \"Andale Mono\", \"Ubuntu Mono\", \"Courier New\", monospace',\n direction: \"ltr\",\n textAlign: \"left\",\n whiteSpace: \"pre\",\n wordSpacing: \"normal\",\n wordBreak: \"normal\",\n lineHeight: \"1.5\",\n MozTabSize: \"4\",\n OTabSize: \"4\",\n tabSize: \"4\",\n WebkitHyphens: \"none\",\n MozHyphens: \"none\",\n msHyphens: \"none\",\n hyphens: \"none\",\n padding: \"1em\",\n margin: \".5em 0\",\n overflow: \"auto\",\n background: \"#1e1e1e\",\n },\n 'code[class*=\"language-\"]': {\n color: \"#d4d4d4\",\n fontSize: \"13px\",\n textShadow: \"none\",\n fontFamily: 'Menlo, Monaco, Consolas, \"Andale Mono\", \"Ubuntu Mono\", \"Courier New\", monospace',\n direction: \"ltr\",\n textAlign: \"left\",\n whiteSpace: \"pre\",\n wordSpacing: \"normal\",\n wordBreak: \"normal\",\n lineHeight: \"1.5\",\n MozTabSize: \"4\",\n OTabSize: \"4\",\n tabSize: \"4\",\n WebkitHyphens: \"none\",\n MozHyphens: \"none\",\n msHyphens: \"none\",\n hyphens: \"none\",\n },\n 'pre[class*=\"language-\"]::selection': {\n textShadow: \"none\",\n background: \"#264F78\",\n },\n 'code[class*=\"language-\"]::selection': {\n textShadow: \"none\",\n background: \"#264F78\",\n },\n 'pre[class*=\"language-\"] *::selection': {\n textShadow: \"none\",\n background: \"#264F78\",\n },\n 'code[class*=\"language-\"] *::selection': {\n textShadow: \"none\",\n background: \"#264F78\",\n },\n ':not(pre) > code[class*=\"language-\"]': {\n padding: \".1em .3em\",\n borderRadius: \".3em\",\n color: \"#db4c69\",\n background: \"#1e1e1e\",\n },\n \".namespace\": {\n Opacity: \".7\",\n },\n \"doctype.doctype-tag\": {\n color: \"#569CD6\",\n },\n \"doctype.name\": {\n color: \"#9cdcfe\",\n },\n comment: {\n color: \"#6a9955\",\n },\n prolog: {\n color: \"#6a9955\",\n },\n punctuation: {\n color: \"#d4d4d4\",\n },\n \".language-html .language-css .token.punctuation\": {\n color: \"#d4d4d4\",\n },\n \".language-html .language-javascript .token.punctuation\": {\n color: \"#d4d4d4\",\n },\n property: {\n color: \"#9cdcfe\",\n },\n tag: {\n color: \"#569cd6\",\n },\n boolean: {\n color: \"#569cd6\",\n },\n number: {\n color: \"#b5cea8\",\n },\n constant: {\n color: \"#9cdcfe\",\n },\n symbol: {\n color: \"#b5cea8\",\n },\n inserted: {\n color: \"#b5cea8\",\n },\n unit: {\n color: \"#b5cea8\",\n },\n selector: {\n color: \"#d7ba7d\",\n },\n \"attr-name\": {\n color: \"#9cdcfe\",\n },\n string: {\n color: \"#ce9178\",\n },\n char: {\n color: \"#ce9178\",\n },\n builtin: {\n color: \"#ce9178\",\n },\n deleted: {\n color: \"#ce9178\",\n },\n \".language-css .token.string.url\": {\n textDecoration: \"underline\",\n },\n operator: {\n color: \"#d4d4d4\",\n },\n entity: {\n color: \"#569cd6\",\n },\n \"operator.arrow\": {\n color: \"#569CD6\",\n },\n atrule: {\n color: \"#ce9178\",\n },\n \"atrule.rule\": {\n color: \"#c586c0\",\n },\n \"atrule.url\": {\n color: \"#9cdcfe\",\n },\n \"atrule.url.function\": {\n color: \"#dcdcaa\",\n },\n \"atrule.url.punctuation\": {\n color: \"#d4d4d4\",\n },\n keyword: {\n color: \"#569CD6\",\n },\n \"keyword.module\": {\n color: \"#c586c0\",\n },\n \"keyword.control-flow\": {\n color: \"#c586c0\",\n },\n function: {\n color: \"#dcdcaa\",\n },\n \"function.maybe-class-name\": {\n color: \"#dcdcaa\",\n },\n regex: {\n color: \"#d16969\",\n },\n important: {\n color: \"#569cd6\",\n },\n italic: {\n fontStyle: \"italic\",\n },\n \"class-name\": {\n color: \"#4ec9b0\",\n },\n \"maybe-class-name\": {\n color: \"#4ec9b0\",\n },\n console: {\n color: \"#9cdcfe\",\n },\n parameter: {\n color: \"#9cdcfe\",\n },\n interpolation: {\n color: \"#9cdcfe\",\n },\n \"punctuation.interpolation-punctuation\": {\n color: \"#569cd6\",\n },\n variable: {\n color: \"#9cdcfe\",\n },\n \"imports.maybe-class-name\": {\n color: \"#9cdcfe\",\n },\n \"exports.maybe-class-name\": {\n color: \"#9cdcfe\",\n },\n escape: {\n color: \"#d7ba7d\",\n },\n \"tag.punctuation\": {\n color: \"#808080\",\n },\n cdata: {\n color: \"#808080\",\n },\n \"attr-value\": {\n color: \"#ce9178\",\n },\n \"attr-value.punctuation\": {\n color: \"#ce9178\",\n },\n \"attr-value.punctuation.attr-equals\": {\n color: \"#d4d4d4\",\n },\n namespace: {\n color: \"#4ec9b0\",\n },\n 'pre[class*=\"language-javascript\"]': {\n color: \"#9cdcfe\",\n },\n 'code[class*=\"language-javascript\"]': {\n color: \"#9cdcfe\",\n },\n 'pre[class*=\"language-jsx\"]': {\n color: \"#9cdcfe\",\n },\n 'code[class*=\"language-jsx\"]': {\n color: \"#9cdcfe\",\n },\n 'pre[class*=\"language-typescript\"]': {\n color: \"#9cdcfe\",\n },\n 'code[class*=\"language-typescript\"]': {\n color: \"#9cdcfe\",\n },\n 'pre[class*=\"language-tsx\"]': {\n color: \"#9cdcfe\",\n },\n 'code[class*=\"language-tsx\"]': {\n color: \"#9cdcfe\",\n },\n 'pre[class*=\"language-css\"]': {\n color: \"#ce9178\",\n },\n 'code[class*=\"language-css\"]': {\n color: \"#ce9178\",\n },\n 'pre[class*=\"language-html\"]': {\n color: \"#d4d4d4\",\n },\n 'code[class*=\"language-html\"]': {\n color: \"#d4d4d4\",\n },\n \".language-regex .token.anchor\": {\n color: \"#dcdcaa\",\n },\n \".language-html .token.punctuation\": {\n color: \"#808080\",\n },\n 'pre[class*=\"language-\"] > code[class*=\"language-\"]': {\n position: \"relative\",\n zIndex: \"1\",\n },\n \".line-highlight.line-highlight\": {\n background: \"#f7ebc6\",\n boxShadow: \"inset 5px 0 0 #f7d87c\",\n zIndex: \"0\",\n },\n};\n","import * as React from \"react\";\n\nexport interface useCopyToClipboardProps {\n timeout?: number;\n}\n\nexport function useCopyToClipboard({ timeout = 2000 }: useCopyToClipboardProps) {\n const [isCopied, setIsCopied] = React.useState<Boolean>(false);\n\n const copyToClipboard = (value: string) => {\n if (typeof window === \"undefined\" || !navigator.clipboard?.writeText) {\n return;\n }\n\n if (!value) {\n return;\n }\n\n navigator.clipboard.writeText(value).then(() => {\n setIsCopied(true);\n\n setTimeout(() => {\n setIsCopied(false);\n }, timeout);\n });\n };\n\n return { isCopied, copyToClipboard };\n}\n","import React from \"react\";\n\nexport const OpenIcon = (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 24 24\"\n fill=\"currentColor\"\n width=\"24\"\n height=\"24\"\n >\n <g transform=\"translate(24, 0) scale(-1, 1)\">\n <path\n fillRule=\"evenodd\"\n d=\"M5.337 21.718a6.707 6.707 0 01-.533-.074.75.75 0 01-.44-1.223 3.73 3.73 0 00.814-1.686c.023-.115-.022-.317-.254-.543C3.274 16.587 2.25 14.41 2.25 12c0-5.03 4.428-9 9.75-9s9.75 3.97 9.75 9c0 5.03-4.428 9-9.75 9-.833 0-1.643-.097-2.417-.279a6.721 6.721 0 01-4.246.997z\"\n clipRule=\"evenodd\"\n />\n </g>\n </svg>\n);\n\nexport const CloseIcon = (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n strokeWidth=\"1.5\"\n stroke=\"currentColor\"\n width=\"24\"\n height=\"24\"\n >\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" d=\"M19.5 8.25l-7.5 7.5-7.5-7.5\" />\n </svg>\n);\n\nexport const HeaderCloseIcon = (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n strokeWidth=\"1.5\"\n stroke=\"currentColor\"\n width=\"24\"\n height=\"24\"\n >\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" d=\"M6 18L18 6M6 6l12 12\" />\n </svg>\n);\n\nexport const SendIcon = (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n strokeWidth={1.5}\n stroke=\"currentColor\"\n width=\"24\"\n height=\"24\"\n >\n <path\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n d=\"M6 12L3.269 3.126A59.768 59.768 0 0121.485 12 59.77 59.77 0 013.27 20.876L5.999 12zm0 0h7.5\"\n />\n </svg>\n);\n\nexport const SpinnerIcon = (\n <svg\n style={{\n animation: \"copilotKitSpinAnimation 1s linear infinite\",\n color: \"rgb(107 114 128)\",\n }}\n width=\"24\"\n height=\"24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n >\n <circle\n style={{ opacity: 0.25 }}\n cx=\"12\"\n cy=\"12\"\n r=\"10\"\n stroke=\"currentColor\"\n strokeWidth=\"4\"\n ></circle>\n <path\n style={{ opacity: 0.75 }}\n fill=\"currentColor\"\n d=\"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z\"\n ></path>\n </svg>\n);\n\nexport const ActivityIcon = (\n <svg\n style={{\n display: \"inline-block\",\n marginLeft: \"0.25rem\",\n marginRight: \"0.25rem\",\n }}\n height=\"24\"\n width=\"24\"\n viewBox=\"0 0 27 27\"\n xmlns=\"http://www.w3.org/2000/svg\"\n fill=\"currentColor\"\n >\n <circle className=\"copilotKitActivityDot1\" cx=\"4\" cy=\"12\" r=\"3\" />\n <circle className=\"copilotKitActivityDot1 copilotKitActivityDot2\" cx=\"12\" cy=\"12\" r=\"3\" />\n <circle className=\"copilotKitActivityDot1 copilotKitActivityDot3\" cx=\"20\" cy=\"12\" r=\"3\" />\n </svg>\n);\n\nexport function CheckIcon({ className, ...props }: React.ComponentProps<\"svg\">) {\n return (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 256 256\"\n fill=\"currentColor\"\n style={{ height: \"1rem\", width: \"1rem\" }}\n className={className}\n {...props}\n >\n <path d=\"m229.66 77.66-128 128a8 8 0 0 1-11.32 0l-56-56a8 8 0 0 1 11.32-11.32L96 188.69 218.34 66.34a8 8 0 0 1 11.32 11.32Z\" />\n </svg>\n );\n}\n\nexport function DownloadIcon({ className, ...props }: React.ComponentProps<\"svg\">) {\n return (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 256 256\"\n fill=\"currentColor\"\n style={{ height: \"1rem\", width: \"1rem\" }}\n className={className}\n {...props}\n >\n <path d=\"M224 152v56a16 16 0 0 1-16 16H48a16 16 0 0 1-16-16v-56a8 8 0 0 1 16 0v56h160v-56a8 8 0 0 1 16 0Zm-101.66 5.66a8 8 0 0 0 11.32 0l40-40a8 8 0 0 0-11.32-11.32L136 132.69V40a8 8 0 0 0-16 0v92.69l-26.34-26.35a8 8 0 0 0-11.32 11.32Z\" />\n </svg>\n );\n}\n\nexport function CopyIcon({ className, ...props }: React.ComponentProps<\"svg\">) {\n return (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 256 256\"\n fill=\"currentColor\"\n style={{ height: \"1rem\", width: \"1rem\" }}\n className={className}\n {...props}\n >\n <path d=\"M216 32H88a8 8 0 0 0-8 8v40H40a8 8 0 0 0-8 8v128a8 8 0 0 0 8 8h128a8 8 0 0 0 8-8v-40h40a8 8 0 0 0 8-8V40a8 8 0 0 0-8-8Zm-56 176H48V96h112Zm48-48h-32V88a8 8 0 0 0-8-8H96V48h112Z\" />\n </svg>\n );\n}\n\nexport const StopIcon = (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 256 256\"\n fill=\"currentColor\"\n style={{ height: \"1rem\", width: \"1rem\" }}\n >\n <path d=\"M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24Zm0 192a88 88 0 1 1 88-88 88.1 88.1 0 0 1-88 88Zm24-120h-48a8 8 0 0 0-8 8v48a8 8 0 0 0 8 8h48a8 8 0 0 0 8-8v-48a8 8 0 0 0-8-8Zm-8 48h-32v-32h32Z\" />\n </svg>\n);\n\nexport const RegenerateIcon = (\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 256 256\"\n fill=\"currentColor\"\n style={{ height: \"1rem\", width: \"1rem\" }}\n >\n <path d=\"M197.67 186.37a8 8 0 0 1 0 11.29C196.58 198.73 170.82 224 128 224c-37.39 0-64.53-22.4-80-39.85V208a8 8 0 0 1-16 0v-48a8 8 0 0 1 8-8h48a8 8 0 0 1 0 16H55.44C67.76 183.35 93 208 128 208c36 0 58.14-21.46 58.36-21.68a8 8 0 0 1 11.31.05ZM216 40a8 8 0 0 0-8 8v23.85C192.53 54.4 165.39 32 128 32c-42.82 0-68.58 25.27-69.66 26.34a8 8 0 0 0 11.3 11.34C69.86 69.46 92 48 128 48c35 0 60.24 24.65 72.56 40H168a8 8 0 0 0 0 16h48a8 8 0 0 0 8-8V48a8 8 0 0 0-8-8Z\" />\n </svg>\n);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,SAAa,QAAAA,aAAY;AACzB,OAAO,mBAA4C;;;ACDnD,SAAa,YAAY;AACzB,SAAS,SAAS,yBAAyB;;;ACD3C,YAAY,WAAW;AAMhB,SAAS,mBAAmB,EAAE,UAAU,IAAK,GAA4B;AAC9E,QAAM,CAAC,UAAU,WAAW,IAAU,eAAkB,KAAK;AAE7D,QAAM,kBAAkB,CAAC,UAAkB;AAT7C;AAUI,QAAI,OAAO,WAAW,eAAe,GAAC,eAAU,cAAV,mBAAqB,YAAW;AACpE;AAAA,IACF;AAEA,QAAI,CAAC,OAAO;AACV;AAAA,IACF;AAEA,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