@liveblocks/react-ui 2.25.0-aiprivatebeta7 → 2.25.0-aiprivatebeta9
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/dist/_private/index.cjs +14 -10
- package/dist/_private/index.cjs.map +1 -1
- package/dist/_private/index.d.cts +200 -105
- package/dist/_private/index.d.ts +200 -105
- package/dist/_private/index.js +10 -5
- package/dist/_private/index.js.map +1 -1
- package/dist/components/AiChat.cjs +85 -120
- package/dist/components/AiChat.cjs.map +1 -1
- package/dist/components/AiChat.js +87 -122
- package/dist/components/AiChat.js.map +1 -1
- package/dist/components/AiTool.cjs +164 -0
- package/dist/components/AiTool.cjs.map +1 -0
- package/dist/components/AiTool.js +162 -0
- package/dist/components/AiTool.js.map +1 -0
- package/dist/components/Comment.cjs +5 -3
- package/dist/components/Comment.cjs.map +1 -1
- package/dist/components/Comment.js +6 -4
- package/dist/components/Comment.js.map +1 -1
- package/dist/components/InboxNotificationList.cjs +11 -3
- package/dist/components/InboxNotificationList.cjs.map +1 -1
- package/dist/components/InboxNotificationList.js +12 -4
- package/dist/components/InboxNotificationList.js.map +1 -1
- package/dist/components/Thread.cjs +3 -3
- package/dist/components/Thread.cjs.map +1 -1
- package/dist/components/Thread.js +3 -3
- package/dist/components/Thread.js.map +1 -1
- package/dist/components/internal/AiChatAssistantMessage.cjs +53 -229
- package/dist/components/internal/AiChatAssistantMessage.cjs.map +1 -1
- package/dist/components/internal/AiChatAssistantMessage.js +55 -231
- package/dist/components/internal/AiChatAssistantMessage.js.map +1 -1
- package/dist/components/internal/AiChatComposer.cjs +29 -17
- package/dist/components/internal/AiChatComposer.cjs.map +1 -1
- package/dist/components/internal/AiChatComposer.js +29 -17
- package/dist/components/internal/AiChatComposer.js.map +1 -1
- package/dist/components/internal/AiChatUserMessage.cjs +17 -10
- package/dist/components/internal/AiChatUserMessage.cjs.map +1 -1
- package/dist/components/internal/AiChatUserMessage.js +17 -10
- package/dist/components/internal/AiChatUserMessage.js.map +1 -1
- package/dist/components/internal/Button.cjs.map +1 -1
- package/dist/components/internal/Button.js.map +1 -1
- package/dist/components/internal/CodeBlock.cjs +72 -0
- package/dist/components/internal/CodeBlock.cjs.map +1 -0
- package/dist/components/internal/CodeBlock.js +70 -0
- package/dist/components/internal/CodeBlock.js.map +1 -0
- package/dist/components/internal/Emoji.cjs +12 -4
- package/dist/components/internal/Emoji.cjs.map +1 -1
- package/dist/components/internal/Emoji.js +12 -4
- package/dist/components/internal/Emoji.js.map +1 -1
- package/dist/components/internal/Prose.cjs +37 -0
- package/dist/components/internal/Prose.cjs.map +1 -0
- package/dist/components/internal/Prose.js +35 -0
- package/dist/components/internal/Prose.js.map +1 -0
- package/dist/icon.cjs +2 -0
- package/dist/icon.cjs.map +1 -1
- package/dist/icon.js +1 -0
- package/dist/icon.js.map +1 -1
- package/dist/icons/{Resolve.cjs → CheckCircle.cjs} +3 -3
- package/dist/icons/CheckCircle.cjs.map +1 -0
- package/dist/icons/{Resolve.js → CheckCircle.js} +3 -3
- package/dist/icons/CheckCircle.js.map +1 -0
- package/dist/icons/{Resolved.cjs → CheckCircleFill.cjs} +3 -3
- package/dist/icons/CheckCircleFill.cjs.map +1 -0
- package/dist/icons/{Resolved.js → CheckCircleFill.js} +3 -3
- package/dist/icons/CheckCircleFill.js.map +1 -0
- package/dist/icons/index.cjs +4 -4
- package/dist/icons/index.js +2 -2
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +68 -14
- package/dist/index.d.ts +68 -14
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/overrides.cjs +2 -8
- package/dist/overrides.cjs.map +1 -1
- package/dist/overrides.js +2 -8
- package/dist/overrides.js.map +1 -1
- package/dist/primitives/AiChatComposer/index.cjs +1 -2
- package/dist/primitives/AiChatComposer/index.cjs.map +1 -1
- package/dist/primitives/AiChatComposer/index.js +1 -2
- package/dist/primitives/AiChatComposer/index.js.map +1 -1
- package/dist/primitives/AiMessage/contexts.cjs +18 -0
- package/dist/primitives/AiMessage/contexts.cjs.map +1 -0
- package/dist/primitives/AiMessage/contexts.js +15 -0
- package/dist/primitives/AiMessage/contexts.js.map +1 -0
- package/dist/primitives/AiMessage/index.cjs +133 -0
- package/dist/primitives/AiMessage/index.cjs.map +1 -0
- package/dist/primitives/AiMessage/index.js +131 -0
- package/dist/primitives/AiMessage/index.js.map +1 -0
- package/dist/primitives/{internal/Collapsible → Collapsible}/index.cjs +39 -17
- package/dist/primitives/Collapsible/index.cjs.map +1 -0
- package/dist/primitives/{internal/Collapsible → Collapsible}/index.js +37 -15
- package/dist/primitives/Collapsible/index.js.map +1 -0
- package/dist/primitives/{internal/Markdown.cjs → Markdown.cjs} +150 -83
- package/dist/primitives/Markdown.cjs.map +1 -0
- package/dist/primitives/{internal/Markdown.js → Markdown.js} +151 -83
- package/dist/primitives/Markdown.js.map +1 -0
- package/dist/primitives/index.cjs +4 -6
- package/dist/primitives/index.cjs.map +1 -1
- package/dist/primitives/index.d.cts +2 -79
- package/dist/primitives/index.d.ts +2 -79
- package/dist/primitives/index.js +4 -6
- package/dist/primitives/index.js.map +1 -1
- package/dist/utils/ErrorBoundary.cjs +48 -0
- package/dist/utils/ErrorBoundary.cjs.map +1 -0
- package/dist/utils/ErrorBoundary.js +45 -0
- package/dist/utils/ErrorBoundary.js.map +1 -0
- package/dist/utils/use-visible.cjs +63 -45
- package/dist/utils/use-visible.cjs.map +1 -1
- package/dist/utils/use-visible.js +64 -46
- package/dist/utils/use-visible.js.map +1 -1
- package/dist/version.cjs +1 -1
- package/dist/version.js +1 -1
- package/package.json +5 -5
- package/src/styles/constants.css +1 -1
- package/src/styles/dark/index.css +7 -3
- package/src/styles/index.css +584 -238
- package/src/styles/utils.css +1 -1
- package/styles/dark/attributes.css +1 -1
- package/styles/dark/attributes.css.map +1 -1
- package/styles/dark/media-query.css +1 -1
- package/styles/dark/media-query.css.map +1 -1
- package/styles.css +1 -1
- package/styles.css.map +1 -1
- package/dist/icons/Resolve.cjs.map +0 -1
- package/dist/icons/Resolve.js.map +0 -1
- package/dist/icons/Resolved.cjs.map +0 -1
- package/dist/icons/Resolved.js.map +0 -1
- package/dist/primitives/internal/Collapsible/index.cjs.map +0 -1
- package/dist/primitives/internal/Collapsible/index.js.map +0 -1
- package/dist/primitives/internal/Emoji.cjs +0 -32
- package/dist/primitives/internal/Emoji.cjs.map +0 -1
- package/dist/primitives/internal/Emoji.js +0 -30
- package/dist/primitives/internal/Emoji.js.map +0 -1
- package/dist/primitives/internal/Markdown.cjs.map +0 -1
- package/dist/primitives/internal/Markdown.js.map +0 -1
|
@@ -1,14 +1,22 @@
|
|
|
1
1
|
import { jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { forwardRef } from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { EMOJI_FONT_FAMILY } from '../../constants.js';
|
|
4
4
|
import { classNames } from '../../utils/class-names.js';
|
|
5
5
|
|
|
6
6
|
const Emoji = forwardRef(
|
|
7
|
-
({ className, ...props }, forwardedRef) => {
|
|
8
|
-
return /* @__PURE__ */ jsx(
|
|
7
|
+
({ emoji, className, style, ...props }, forwardedRef) => {
|
|
8
|
+
return /* @__PURE__ */ jsx("span", {
|
|
9
|
+
role: "img",
|
|
10
|
+
"aria-label": emoji,
|
|
11
|
+
"data-emoji": emoji,
|
|
9
12
|
className: classNames("lb-emoji", className),
|
|
13
|
+
style: {
|
|
14
|
+
...style,
|
|
15
|
+
fontFamily: EMOJI_FONT_FAMILY
|
|
16
|
+
},
|
|
10
17
|
...props,
|
|
11
|
-
ref: forwardedRef
|
|
18
|
+
ref: forwardedRef,
|
|
19
|
+
children: emoji
|
|
12
20
|
});
|
|
13
21
|
}
|
|
14
22
|
);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Emoji.js","sources":["../../../src/components/internal/Emoji.tsx"],"sourcesContent":["import { forwardRef } from \"react\";\n\nimport
|
|
1
|
+
{"version":3,"file":"Emoji.js","sources":["../../../src/components/internal/Emoji.tsx"],"sourcesContent":["import { type ComponentProps, forwardRef } from \"react\";\n\nimport { EMOJI_FONT_FAMILY } from \"../../constants\";\nimport { classNames } from \"../../utils/class-names\";\n\ninterface EmojiProps extends ComponentProps<\"span\"> {\n emoji: string;\n}\n\nexport const Emoji = forwardRef<HTMLSpanElement, EmojiProps>(\n ({ emoji, className, style, ...props }, forwardedRef) => {\n return (\n <span\n role=\"img\"\n aria-label={emoji}\n data-emoji={emoji}\n className={classNames(\"lb-emoji\", className)}\n style={{\n ...style,\n fontFamily: EMOJI_FONT_FAMILY,\n }}\n {...props}\n ref={forwardedRef}\n >\n {emoji}\n </span>\n );\n }\n);\n"],"names":[],"mappings":";;;;;AASO,MAAM,KAAQ,GAAA,UAAA;AAAA,EACnB,CAAC,EAAE,KAAA,EAAO,WAAW,KAAU,EAAA,GAAA,KAAA,IAAS,YAAiB,KAAA;AACvD,IAAA,uBACG,GAAA,CAAA,MAAA,EAAA;AAAA,MACC,IAAK,EAAA,KAAA;AAAA,MACL,YAAY,EAAA,KAAA;AAAA,MACZ,YAAY,EAAA,KAAA;AAAA,MACZ,SAAA,EAAW,UAAW,CAAA,UAAA,EAAY,SAAS,CAAA;AAAA,MAC3C,KAAO,EAAA;AAAA,QACL,GAAG,KAAA;AAAA,QACH,UAAY,EAAA,iBAAA;AAAA,OACd;AAAA,MACC,GAAG,KAAA;AAAA,MACJ,GAAK,EAAA,YAAA;AAAA,MAEJ,QAAA,EAAA,KAAA;AAAA,KACH,CAAA,CAAA;AAAA,GAEJ;AACF;;;;"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
+
var components = require('../../components.cjs');
|
|
5
|
+
var Markdown = require('../../primitives/Markdown.cjs');
|
|
6
|
+
var classNames = require('../../utils/class-names.cjs');
|
|
7
|
+
var CodeBlock$1 = require('./CodeBlock.cjs');
|
|
8
|
+
|
|
9
|
+
function Link({ href, title, children }) {
|
|
10
|
+
const { Anchor } = components.useComponents();
|
|
11
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Anchor, {
|
|
12
|
+
href,
|
|
13
|
+
title,
|
|
14
|
+
children
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
function CodeBlock({ language, code }) {
|
|
18
|
+
return /* @__PURE__ */ jsxRuntime.jsx(CodeBlock$1.CodeBlock, {
|
|
19
|
+
title: language || "Plain text",
|
|
20
|
+
code
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
const markdownComponents = {
|
|
24
|
+
Link,
|
|
25
|
+
CodeBlock
|
|
26
|
+
};
|
|
27
|
+
function Prose({ content, className, ...props }) {
|
|
28
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Markdown.Markdown, {
|
|
29
|
+
content,
|
|
30
|
+
components: markdownComponents,
|
|
31
|
+
className: classNames.classNames("lb-prose", className),
|
|
32
|
+
...props
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
exports.Prose = Prose;
|
|
37
|
+
//# sourceMappingURL=Prose.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Prose.cjs","sources":["../../../src/components/internal/Prose.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\n\nimport { useComponents } from \"../../components\";\nimport type {\n MarkdownComponents,\n MarkdownComponentsCodeBlockProps,\n MarkdownComponentsLinkProps,\n} from \"../../primitives/Markdown\";\nimport { Markdown } from \"../../primitives/Markdown\";\nimport { classNames } from \"../../utils/class-names\";\nimport { CodeBlock as DefaultCodeBlock } from \"./CodeBlock\";\n\ninterface ProseProps extends ComponentProps<\"div\"> {\n content: string;\n}\n\nfunction Link({ href, title, children }: MarkdownComponentsLinkProps) {\n const { Anchor } = useComponents();\n\n return (\n <Anchor href={href} title={title}>\n {children}\n </Anchor>\n );\n}\n\nfunction CodeBlock({ language, code }: MarkdownComponentsCodeBlockProps) {\n return <DefaultCodeBlock title={language || \"Plain text\"} code={code} />;\n}\n\nconst markdownComponents: Partial<MarkdownComponents> = {\n Link,\n CodeBlock,\n};\n\n/**\n * This component renders Markdown content with `lb-prose`\n * styles and custom components (code blocks, etc)\n */\nexport function Prose({ content, className, ...props }: ProseProps) {\n return (\n <Markdown\n content={content}\n components={markdownComponents}\n className={classNames(\"lb-prose\", className)}\n {...props}\n />\n );\n}\n"],"names":["useComponents","jsx","DefaultCodeBlock","Markdown","classNames"],"mappings":";;;;;;;;AAgBA,SAAS,IAAK,CAAA,EAAE,IAAM,EAAA,KAAA,EAAO,UAAyC,EAAA;AACpE,EAAM,MAAA,EAAE,MAAO,EAAA,GAAIA,wBAAc,EAAA,CAAA;AAEjC,EAAA,uBACGC,cAAA,CAAA,MAAA,EAAA;AAAA,IAAO,IAAA;AAAA,IAAY,KAAA;AAAA,IACjB,QAAA;AAAA,GACH,CAAA,CAAA;AAEJ,CAAA;AAEA,SAAS,SAAU,CAAA,EAAE,QAAU,EAAA,IAAA,EAA0C,EAAA;AACvE,EAAA,uBAAQA,cAAA,CAAAC,qBAAA,EAAA;AAAA,IAAiB,OAAO,QAAY,IAAA,YAAA;AAAA,IAAc,IAAA;AAAA,GAAY,CAAA,CAAA;AACxE,CAAA;AAEA,MAAM,kBAAkD,GAAA;AAAA,EACtD,IAAA;AAAA,EACA,SAAA;AACF,CAAA,CAAA;AAMO,SAAS,KAAM,CAAA,EAAE,OAAS,EAAA,SAAA,EAAA,GAAc,OAAqB,EAAA;AAClE,EAAA,uBACGD,cAAA,CAAAE,iBAAA,EAAA;AAAA,IACC,OAAA;AAAA,IACA,UAAY,EAAA,kBAAA;AAAA,IACZ,SAAA,EAAWC,qBAAW,CAAA,UAAA,EAAY,SAAS,CAAA;AAAA,IAC1C,GAAG,KAAA;AAAA,GACN,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { useComponents } from '../../components.js';
|
|
3
|
+
import { Markdown } from '../../primitives/Markdown.js';
|
|
4
|
+
import { classNames } from '../../utils/class-names.js';
|
|
5
|
+
import { CodeBlock as CodeBlock$1 } from './CodeBlock.js';
|
|
6
|
+
|
|
7
|
+
function Link({ href, title, children }) {
|
|
8
|
+
const { Anchor } = useComponents();
|
|
9
|
+
return /* @__PURE__ */ jsx(Anchor, {
|
|
10
|
+
href,
|
|
11
|
+
title,
|
|
12
|
+
children
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
function CodeBlock({ language, code }) {
|
|
16
|
+
return /* @__PURE__ */ jsx(CodeBlock$1, {
|
|
17
|
+
title: language || "Plain text",
|
|
18
|
+
code
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
const markdownComponents = {
|
|
22
|
+
Link,
|
|
23
|
+
CodeBlock
|
|
24
|
+
};
|
|
25
|
+
function Prose({ content, className, ...props }) {
|
|
26
|
+
return /* @__PURE__ */ jsx(Markdown, {
|
|
27
|
+
content,
|
|
28
|
+
components: markdownComponents,
|
|
29
|
+
className: classNames("lb-prose", className),
|
|
30
|
+
...props
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export { Prose };
|
|
35
|
+
//# sourceMappingURL=Prose.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Prose.js","sources":["../../../src/components/internal/Prose.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\n\nimport { useComponents } from \"../../components\";\nimport type {\n MarkdownComponents,\n MarkdownComponentsCodeBlockProps,\n MarkdownComponentsLinkProps,\n} from \"../../primitives/Markdown\";\nimport { Markdown } from \"../../primitives/Markdown\";\nimport { classNames } from \"../../utils/class-names\";\nimport { CodeBlock as DefaultCodeBlock } from \"./CodeBlock\";\n\ninterface ProseProps extends ComponentProps<\"div\"> {\n content: string;\n}\n\nfunction Link({ href, title, children }: MarkdownComponentsLinkProps) {\n const { Anchor } = useComponents();\n\n return (\n <Anchor href={href} title={title}>\n {children}\n </Anchor>\n );\n}\n\nfunction CodeBlock({ language, code }: MarkdownComponentsCodeBlockProps) {\n return <DefaultCodeBlock title={language || \"Plain text\"} code={code} />;\n}\n\nconst markdownComponents: Partial<MarkdownComponents> = {\n Link,\n CodeBlock,\n};\n\n/**\n * This component renders Markdown content with `lb-prose`\n * styles and custom components (code blocks, etc)\n */\nexport function Prose({ content, className, ...props }: ProseProps) {\n return (\n <Markdown\n content={content}\n components={markdownComponents}\n className={classNames(\"lb-prose\", className)}\n {...props}\n />\n );\n}\n"],"names":["DefaultCodeBlock"],"mappings":";;;;;;AAgBA,SAAS,IAAK,CAAA,EAAE,IAAM,EAAA,KAAA,EAAO,UAAyC,EAAA;AACpE,EAAM,MAAA,EAAE,MAAO,EAAA,GAAI,aAAc,EAAA,CAAA;AAEjC,EAAA,uBACG,GAAA,CAAA,MAAA,EAAA;AAAA,IAAO,IAAA;AAAA,IAAY,KAAA;AAAA,IACjB,QAAA;AAAA,GACH,CAAA,CAAA;AAEJ,CAAA;AAEA,SAAS,SAAU,CAAA,EAAE,QAAU,EAAA,IAAA,EAA0C,EAAA;AACvE,EAAA,uBAAQ,GAAA,CAAAA,WAAA,EAAA;AAAA,IAAiB,OAAO,QAAY,IAAA,YAAA;AAAA,IAAc,IAAA;AAAA,GAAY,CAAA,CAAA;AACxE,CAAA;AAEA,MAAM,kBAAkD,GAAA;AAAA,EACtD,IAAA;AAAA,EACA,SAAA;AACF,CAAA,CAAA;AAMO,SAAS,KAAM,CAAA,EAAE,OAAS,EAAA,SAAA,EAAA,GAAc,OAAqB,EAAA;AAClE,EAAA,uBACG,GAAA,CAAA,QAAA,EAAA;AAAA,IACC,OAAA;AAAA,IACA,UAAY,EAAA,kBAAA;AAAA,IACZ,SAAA,EAAW,UAAW,CAAA,UAAA,EAAY,SAAS,CAAA;AAAA,IAC1C,GAAG,KAAA;AAAA,GACN,CAAA,CAAA;AAEJ;;;;"}
|
package/dist/icon.cjs
CHANGED
|
@@ -11,6 +11,7 @@ var BellCrossed = require('./icons/BellCrossed.cjs');
|
|
|
11
11
|
var Blockquote = require('./icons/Blockquote.cjs');
|
|
12
12
|
var Bold = require('./icons/Bold.cjs');
|
|
13
13
|
var Check = require('./icons/Check.cjs');
|
|
14
|
+
var CheckCircle = require('./icons/CheckCircle.cjs');
|
|
14
15
|
var ChevronDown = require('./icons/ChevronDown.cjs');
|
|
15
16
|
var ChevronLeft = require('./icons/ChevronLeft.cjs');
|
|
16
17
|
var ChevronRight = require('./icons/ChevronRight.cjs');
|
|
@@ -58,6 +59,7 @@ exports.BellCrossed = BellCrossed.BellCrossedIcon;
|
|
|
58
59
|
exports.Blockquote = Blockquote.BlockquoteIcon;
|
|
59
60
|
exports.Bold = Bold.BoldIcon;
|
|
60
61
|
exports.Check = Check.CheckIcon;
|
|
62
|
+
exports.CheckCircle = CheckCircle.CheckCircleIcon;
|
|
61
63
|
exports.ChevronDown = ChevronDown.ChevronDownIcon;
|
|
62
64
|
exports.ChevronLeft = ChevronLeft.ChevronLeftIcon;
|
|
63
65
|
exports.ChevronRight = ChevronRight.ChevronRightIcon;
|
package/dist/icon.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icon.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"icon.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/icon.js
CHANGED
|
@@ -9,6 +9,7 @@ export { BellCrossedIcon as BellCrossed } from './icons/BellCrossed.js';
|
|
|
9
9
|
export { BlockquoteIcon as Blockquote } from './icons/Blockquote.js';
|
|
10
10
|
export { BoldIcon as Bold } from './icons/Bold.js';
|
|
11
11
|
export { CheckIcon as Check } from './icons/Check.js';
|
|
12
|
+
export { CheckCircleIcon as CheckCircle } from './icons/CheckCircle.js';
|
|
12
13
|
export { ChevronDownIcon as ChevronDown } from './icons/ChevronDown.js';
|
|
13
14
|
export { ChevronLeftIcon as ChevronLeft } from './icons/ChevronLeft.js';
|
|
14
15
|
export { ChevronRightIcon as ChevronRight } from './icons/ChevronRight.js';
|
package/dist/icon.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icon.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"icon.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var Icon = require('../components/internal/Icon.cjs');
|
|
5
5
|
|
|
6
|
-
function
|
|
6
|
+
function CheckCircleIcon(props) {
|
|
7
7
|
return /* @__PURE__ */ jsxRuntime.jsxs(Icon.Icon, {
|
|
8
8
|
...props,
|
|
9
9
|
children: [
|
|
@@ -19,5 +19,5 @@ function ResolveIcon(props) {
|
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
exports.
|
|
23
|
-
//# sourceMappingURL=
|
|
22
|
+
exports.CheckCircleIcon = CheckCircleIcon;
|
|
23
|
+
//# sourceMappingURL=CheckCircle.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CheckCircle.cjs","sources":["../../src/icons/CheckCircle.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\n\nimport { Icon } from \"../components/internal/Icon\";\n\nexport function CheckCircleIcon(props: ComponentProps<\"svg\">) {\n return (\n <Icon {...props}>\n <circle cx={10} cy={10} r={7} />\n <path d=\"m13 8-4 4-2-2\" />\n </Icon>\n );\n}\n"],"names":["jsxs","Icon","jsx"],"mappings":";;;;;AAIO,SAAS,gBAAgB,KAA8B,EAAA;AAC5D,EAAA,uBACGA,eAAA,CAAAC,SAAA,EAAA;AAAA,IAAM,GAAG,KAAA;AAAA,IACR,QAAA,EAAA;AAAA,sBAACC,cAAA,CAAA,QAAA,EAAA;AAAA,QAAO,EAAI,EAAA,EAAA;AAAA,QAAI,EAAI,EAAA,EAAA;AAAA,QAAI,CAAG,EAAA,CAAA;AAAA,OAAG,CAAA;AAAA,sBAC7BA,cAAA,CAAA,MAAA,EAAA;AAAA,QAAK,CAAE,EAAA,eAAA;AAAA,OAAgB,CAAA;AAAA,KAAA;AAAA,GAC1B,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Icon } from '../components/internal/Icon.js';
|
|
3
3
|
|
|
4
|
-
function
|
|
4
|
+
function CheckCircleIcon(props) {
|
|
5
5
|
return /* @__PURE__ */ jsxs(Icon, {
|
|
6
6
|
...props,
|
|
7
7
|
children: [
|
|
@@ -17,5 +17,5 @@ function ResolveIcon(props) {
|
|
|
17
17
|
});
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
-
export {
|
|
21
|
-
//# sourceMappingURL=
|
|
20
|
+
export { CheckCircleIcon };
|
|
21
|
+
//# sourceMappingURL=CheckCircle.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CheckCircle.js","sources":["../../src/icons/CheckCircle.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\n\nimport { Icon } from \"../components/internal/Icon\";\n\nexport function CheckCircleIcon(props: ComponentProps<\"svg\">) {\n return (\n <Icon {...props}>\n <circle cx={10} cy={10} r={7} />\n <path d=\"m13 8-4 4-2-2\" />\n </Icon>\n );\n}\n"],"names":[],"mappings":";;;AAIO,SAAS,gBAAgB,KAA8B,EAAA;AAC5D,EAAA,uBACG,IAAA,CAAA,IAAA,EAAA;AAAA,IAAM,GAAG,KAAA;AAAA,IACR,QAAA,EAAA;AAAA,sBAAC,GAAA,CAAA,QAAA,EAAA;AAAA,QAAO,EAAI,EAAA,EAAA;AAAA,QAAI,EAAI,EAAA,EAAA;AAAA,QAAI,CAAG,EAAA,CAAA;AAAA,OAAG,CAAA;AAAA,sBAC7B,GAAA,CAAA,MAAA,EAAA;AAAA,QAAK,CAAE,EAAA,eAAA;AAAA,OAAgB,CAAA;AAAA,KAAA;AAAA,GAC1B,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var Icon = require('../components/internal/Icon.cjs');
|
|
5
5
|
|
|
6
|
-
function
|
|
6
|
+
function CheckCircleFillIcon(props) {
|
|
7
7
|
return /* @__PURE__ */ jsxRuntime.jsxs(Icon.Icon, {
|
|
8
8
|
...props,
|
|
9
9
|
children: [
|
|
@@ -21,5 +21,5 @@ function ResolvedIcon(props) {
|
|
|
21
21
|
});
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
-
exports.
|
|
25
|
-
//# sourceMappingURL=
|
|
24
|
+
exports.CheckCircleFillIcon = CheckCircleFillIcon;
|
|
25
|
+
//# sourceMappingURL=CheckCircleFill.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CheckCircleFill.cjs","sources":["../../src/icons/CheckCircleFill.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\n\nimport { Icon } from \"../components/internal/Icon\";\n\nexport function CheckCircleFillIcon(props: ComponentProps<\"svg\">) {\n return (\n <Icon {...props}>\n <circle cx={10} cy={10} r={7} fill=\"currentColor\" />\n <path d=\"m13 8-4 4-2-2\" stroke=\"var(--lb-icon-background)\" />\n </Icon>\n );\n}\n"],"names":["jsxs","Icon","jsx"],"mappings":";;;;;AAIO,SAAS,oBAAoB,KAA8B,EAAA;AAChE,EAAA,uBACGA,eAAA,CAAAC,SAAA,EAAA;AAAA,IAAM,GAAG,KAAA;AAAA,IACR,QAAA,EAAA;AAAA,sBAACC,cAAA,CAAA,QAAA,EAAA;AAAA,QAAO,EAAI,EAAA,EAAA;AAAA,QAAI,EAAI,EAAA,EAAA;AAAA,QAAI,CAAG,EAAA,CAAA;AAAA,QAAG,IAAK,EAAA,cAAA;AAAA,OAAe,CAAA;AAAA,sBACjDA,cAAA,CAAA,MAAA,EAAA;AAAA,QAAK,CAAE,EAAA,eAAA;AAAA,QAAgB,MAAO,EAAA,2BAAA;AAAA,OAA4B,CAAA;AAAA,KAAA;AAAA,GAC7D,CAAA,CAAA;AAEJ;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
2
|
import { Icon } from '../components/internal/Icon.js';
|
|
3
3
|
|
|
4
|
-
function
|
|
4
|
+
function CheckCircleFillIcon(props) {
|
|
5
5
|
return /* @__PURE__ */ jsxs(Icon, {
|
|
6
6
|
...props,
|
|
7
7
|
children: [
|
|
@@ -19,5 +19,5 @@ function ResolvedIcon(props) {
|
|
|
19
19
|
});
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
export {
|
|
23
|
-
//# sourceMappingURL=
|
|
22
|
+
export { CheckCircleFillIcon };
|
|
23
|
+
//# sourceMappingURL=CheckCircleFill.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CheckCircleFill.js","sources":["../../src/icons/CheckCircleFill.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\n\nimport { Icon } from \"../components/internal/Icon\";\n\nexport function CheckCircleFillIcon(props: ComponentProps<\"svg\">) {\n return (\n <Icon {...props}>\n <circle cx={10} cy={10} r={7} fill=\"currentColor\" />\n <path d=\"m13 8-4 4-2-2\" stroke=\"var(--lb-icon-background)\" />\n </Icon>\n );\n}\n"],"names":[],"mappings":";;;AAIO,SAAS,oBAAoB,KAA8B,EAAA;AAChE,EAAA,uBACG,IAAA,CAAA,IAAA,EAAA;AAAA,IAAM,GAAG,KAAA;AAAA,IACR,QAAA,EAAA;AAAA,sBAAC,GAAA,CAAA,QAAA,EAAA;AAAA,QAAO,EAAI,EAAA,EAAA;AAAA,QAAI,EAAI,EAAA,EAAA;AAAA,QAAI,CAAG,EAAA,CAAA;AAAA,QAAG,IAAK,EAAA,cAAA;AAAA,OAAe,CAAA;AAAA,sBACjD,GAAA,CAAA,MAAA,EAAA;AAAA,QAAK,CAAE,EAAA,eAAA;AAAA,QAAgB,MAAO,EAAA,2BAAA;AAAA,OAA4B,CAAA;AAAA,KAAA;AAAA,GAC7D,CAAA,CAAA;AAEJ;;;;"}
|
package/dist/icons/index.cjs
CHANGED
|
@@ -10,6 +10,8 @@ var BellCrossed = require('./BellCrossed.cjs');
|
|
|
10
10
|
var Blockquote = require('./Blockquote.cjs');
|
|
11
11
|
var Bold = require('./Bold.cjs');
|
|
12
12
|
var Check = require('./Check.cjs');
|
|
13
|
+
var CheckCircle = require('./CheckCircle.cjs');
|
|
14
|
+
var CheckCircleFill = require('./CheckCircleFill.cjs');
|
|
13
15
|
var ChevronDown = require('./ChevronDown.cjs');
|
|
14
16
|
var ChevronLeft = require('./ChevronLeft.cjs');
|
|
15
17
|
var ChevronRight = require('./ChevronRight.cjs');
|
|
@@ -33,8 +35,6 @@ var ListUnordered = require('./ListUnordered.cjs');
|
|
|
33
35
|
var Mention = require('./Mention.cjs');
|
|
34
36
|
var QuestionMark = require('./QuestionMark.cjs');
|
|
35
37
|
var Redo = require('./Redo.cjs');
|
|
36
|
-
var Resolve = require('./Resolve.cjs');
|
|
37
|
-
var Resolved = require('./Resolved.cjs');
|
|
38
38
|
var Restore = require('./Restore.cjs');
|
|
39
39
|
var Retry = require('./Retry.cjs');
|
|
40
40
|
var Search = require('./Search.cjs');
|
|
@@ -63,6 +63,8 @@ exports.BellCrossedIcon = BellCrossed.BellCrossedIcon;
|
|
|
63
63
|
exports.BlockquoteIcon = Blockquote.BlockquoteIcon;
|
|
64
64
|
exports.BoldIcon = Bold.BoldIcon;
|
|
65
65
|
exports.CheckIcon = Check.CheckIcon;
|
|
66
|
+
exports.CheckCircleIcon = CheckCircle.CheckCircleIcon;
|
|
67
|
+
exports.CheckCircleFillIcon = CheckCircleFill.CheckCircleFillIcon;
|
|
66
68
|
exports.ChevronDownIcon = ChevronDown.ChevronDownIcon;
|
|
67
69
|
exports.ChevronLeftIcon = ChevronLeft.ChevronLeftIcon;
|
|
68
70
|
exports.ChevronRightIcon = ChevronRight.ChevronRightIcon;
|
|
@@ -86,8 +88,6 @@ exports.ListUnorderedIcon = ListUnordered.ListUnorderedIcon;
|
|
|
86
88
|
exports.MentionIcon = Mention.MentionIcon;
|
|
87
89
|
exports.QuestionMarkIcon = QuestionMark.QuestionMarkIcon;
|
|
88
90
|
exports.RedoIcon = Redo.RedoIcon;
|
|
89
|
-
exports.ResolveIcon = Resolve.ResolveIcon;
|
|
90
|
-
exports.ResolvedIcon = Resolved.ResolvedIcon;
|
|
91
91
|
exports.RestoreIcon = Restore.RestoreIcon;
|
|
92
92
|
exports.RetryIcon = Retry.RetryIcon;
|
|
93
93
|
exports.SearchIcon = Search.SearchIcon;
|
package/dist/icons/index.js
CHANGED
|
@@ -8,6 +8,8 @@ export { BellCrossedIcon } from './BellCrossed.js';
|
|
|
8
8
|
export { BlockquoteIcon } from './Blockquote.js';
|
|
9
9
|
export { BoldIcon } from './Bold.js';
|
|
10
10
|
export { CheckIcon } from './Check.js';
|
|
11
|
+
export { CheckCircleIcon } from './CheckCircle.js';
|
|
12
|
+
export { CheckCircleFillIcon } from './CheckCircleFill.js';
|
|
11
13
|
export { ChevronDownIcon } from './ChevronDown.js';
|
|
12
14
|
export { ChevronLeftIcon } from './ChevronLeft.js';
|
|
13
15
|
export { ChevronRightIcon } from './ChevronRight.js';
|
|
@@ -31,8 +33,6 @@ export { ListUnorderedIcon } from './ListUnordered.js';
|
|
|
31
33
|
export { MentionIcon } from './Mention.js';
|
|
32
34
|
export { QuestionMarkIcon } from './QuestionMark.js';
|
|
33
35
|
export { RedoIcon } from './Redo.js';
|
|
34
|
-
export { ResolveIcon } from './Resolve.js';
|
|
35
|
-
export { ResolvedIcon } from './Resolved.js';
|
|
36
36
|
export { RestoreIcon } from './Restore.js';
|
|
37
37
|
export { RetryIcon } from './Retry.js';
|
|
38
38
|
export { SearchIcon } from './Search.js';
|
package/dist/index.cjs
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
var core = require('@liveblocks/core');
|
|
4
4
|
var version = require('./version.cjs');
|
|
5
5
|
var AiChat = require('./components/AiChat.cjs');
|
|
6
|
+
var AiTool = require('./components/AiTool.cjs');
|
|
6
7
|
var Comment = require('./components/Comment.cjs');
|
|
7
8
|
var Composer = require('./components/Composer.cjs');
|
|
8
9
|
var HistoryVersionSummary = require('./components/HistoryVersionSummary.cjs');
|
|
@@ -17,6 +18,7 @@ var overrides = require('./overrides.cjs');
|
|
|
17
18
|
core.detectDupes(version.PKG_NAME, version.PKG_VERSION, version.PKG_FORMAT);
|
|
18
19
|
|
|
19
20
|
exports.AiChat = AiChat.AiChat;
|
|
21
|
+
exports.AiTool = AiTool.AiTool;
|
|
20
22
|
exports.Comment = Comment.Comment;
|
|
21
23
|
exports.Composer = Composer.Composer;
|
|
22
24
|
exports.HistoryVersionSummary = HistoryVersionSummary.HistoryVersionSummary;
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../src/index.ts"],"sourcesContent":["import { detectDupes } from \"@liveblocks/core\";\n\nimport { PKG_FORMAT, PKG_NAME, PKG_VERSION } from \"./version\";\n\ndetectDupes(PKG_NAME, PKG_VERSION, PKG_FORMAT);\n\nexport type { AiChatProps } from \"./components/AiChat\";\nexport { AiChat } from \"./components/AiChat\";\nexport type { CommentProps } from \"./components/Comment\";\nexport { Comment } from \"./components/Comment\";\nexport type { ComposerProps } from \"./components/Composer\";\nexport { Composer } from \"./components/Composer\";\nexport type { HistoryVersionSummaryProps } from \"./components/HistoryVersionSummary\";\nexport { HistoryVersionSummary } from \"./components/HistoryVersionSummary\";\nexport type { HistoryVersionSummaryListProps } from \"./components/HistoryVersionSummaryList\";\nexport { HistoryVersionSummaryList } from \"./components/HistoryVersionSummaryList\";\nexport type {\n InboxNotificationAvatarProps,\n InboxNotificationCustomKindProps,\n InboxNotificationCustomProps,\n InboxNotificationIconProps,\n InboxNotificationProps,\n InboxNotificationTextMentionKindProps,\n InboxNotificationTextMentionProps,\n InboxNotificationThreadKindProps,\n InboxNotificationThreadProps,\n} from \"./components/InboxNotification\";\nexport { InboxNotification } from \"./components/InboxNotification\";\nexport type { InboxNotificationListProps } from \"./components/InboxNotificationList\";\nexport { InboxNotificationList } from \"./components/InboxNotificationList\";\nexport type { ThreadProps } from \"./components/Thread\";\nexport { Thread } from \"./components/Thread\";\nexport { LiveblocksUIConfig } from \"./config\";\nexport * as Icon from \"./icon\";\nexport type {\n CommentOverrides,\n ComposerOverrides,\n GlobalOverrides,\n InboxNotificationOverrides,\n LocalizationOverrides,\n Overrides,\n ThreadOverrides,\n} from \"./overrides\";\nexport { useOverrides } from \"./overrides\";\nexport type { ComposerSubmitComment } from \"./primitives\";\nexport type {\n CommentAttachmentArgs,\n ComposerBodyMark,\n ComposerBodyMarks,\n} from \"./types\";\n"],"names":["detectDupes","PKG_NAME","PKG_VERSION","PKG_FORMAT"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../src/index.ts"],"sourcesContent":["import { detectDupes } from \"@liveblocks/core\";\n\nimport { PKG_FORMAT, PKG_NAME, PKG_VERSION } from \"./version\";\n\ndetectDupes(PKG_NAME, PKG_VERSION, PKG_FORMAT);\n\nexport type { AiChatProps } from \"./components/AiChat\";\nexport { AiChat } from \"./components/AiChat\";\nexport type { AiToolIconProps, AiToolProps } from \"./components/AiTool\";\nexport { AiTool } from \"./components/AiTool\";\nexport type { CommentProps } from \"./components/Comment\";\nexport { Comment } from \"./components/Comment\";\nexport type { ComposerProps } from \"./components/Composer\";\nexport { Composer } from \"./components/Composer\";\nexport type { HistoryVersionSummaryProps } from \"./components/HistoryVersionSummary\";\nexport { HistoryVersionSummary } from \"./components/HistoryVersionSummary\";\nexport type { HistoryVersionSummaryListProps } from \"./components/HistoryVersionSummaryList\";\nexport { HistoryVersionSummaryList } from \"./components/HistoryVersionSummaryList\";\nexport type {\n InboxNotificationAvatarProps,\n InboxNotificationCustomKindProps,\n InboxNotificationCustomProps,\n InboxNotificationIconProps,\n InboxNotificationProps,\n InboxNotificationTextMentionKindProps,\n InboxNotificationTextMentionProps,\n InboxNotificationThreadKindProps,\n InboxNotificationThreadProps,\n} from \"./components/InboxNotification\";\nexport { InboxNotification } from \"./components/InboxNotification\";\nexport type { InboxNotificationListProps } from \"./components/InboxNotificationList\";\nexport { InboxNotificationList } from \"./components/InboxNotificationList\";\nexport type { ThreadProps } from \"./components/Thread\";\nexport { Thread } from \"./components/Thread\";\nexport { LiveblocksUIConfig } from \"./config\";\nexport * as Icon from \"./icon\";\nexport type {\n CommentOverrides,\n ComposerOverrides,\n GlobalOverrides,\n InboxNotificationOverrides,\n LocalizationOverrides,\n Overrides,\n ThreadOverrides,\n} from \"./overrides\";\nexport { useOverrides } from \"./overrides\";\nexport type { ComposerSubmitComment } from \"./primitives\";\nexport type {\n CommentAttachmentArgs,\n ComposerBodyMark,\n ComposerBodyMarks,\n} from \"./types\";\n"],"names":["detectDupes","PKG_NAME","PKG_VERSION","PKG_FORMAT"],"mappings":";;;;;;;;;;;;;;;;;AAIAA,gBAAY,CAAAC,gBAAA,EAAUC,qBAAaC,kBAAU,CAAA;;;;;;;;;;;;;;;"}
|
package/dist/index.d.cts
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import { CommentAttachment, AiKnowledgeSource,
|
|
2
|
+
import { ComponentType, ComponentPropsWithoutRef, ElementType, ReactNode, ComponentProps, FormEvent, RefAttributes, MouseEvent, PropsWithChildren } from 'react';
|
|
3
|
+
import { CommentAttachment, AiKnowledgeSource, AiOpaqueToolDefinition, AiToolTypePack, JsonObject, ToolResultData, AiToolExecuteCallback, CommentBody, BaseMetadata, DM, CommentData, HistoryVersion, InboxNotificationData, InboxNotificationThreadData, InboxNotificationTextMentionData, InboxNotificationCustomData, KDAD, ThreadData } from '@liveblocks/core';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
|
|
6
|
+
interface GlobalComponents {
|
|
7
|
+
Anchor: ComponentType<ComponentPropsWithoutRef<"a">> | "a";
|
|
8
|
+
}
|
|
9
|
+
type Components = GlobalComponents;
|
|
10
|
+
|
|
6
11
|
type Direction = "ltr" | "rtl";
|
|
7
12
|
type SlotProp = {
|
|
8
13
|
/**
|
|
@@ -76,15 +81,11 @@ interface ComposerOverrides {
|
|
|
76
81
|
interface AiChatComposerOverrides {
|
|
77
82
|
AI_CHAT_COMPOSER_PLACEHOLDER: string;
|
|
78
83
|
AI_CHAT_COMPOSER_SEND: string;
|
|
79
|
-
AI_CHAT_COMPOSER_ATTACH_FILES: string;
|
|
80
|
-
AI_CHAT_COMPOSER_REMOVE_ATTACHMENT: string;
|
|
81
84
|
AI_CHAT_COMPOSER_ABORT: string;
|
|
82
85
|
}
|
|
83
86
|
interface AiChatMessageOverrides {
|
|
84
87
|
AI_CHAT_MESSAGE_DELETED: string;
|
|
85
88
|
AI_CHAT_MESSAGE_THINKING: string;
|
|
86
|
-
AI_CHAT_MESSAGE_COPY: string;
|
|
87
|
-
AI_CHAT_MESSAGE_TRY_AGAIN: string;
|
|
88
89
|
}
|
|
89
90
|
interface AiChatOverrides {
|
|
90
91
|
AI_CHAT_MESSAGES_ERROR: (error: Error) => ReactNode;
|
|
@@ -116,6 +117,12 @@ interface HistoryVersionPreviewOverrides {
|
|
|
116
117
|
type Overrides = LocalizationOverrides & GlobalOverrides & ComposerOverrides & CommentOverrides & ThreadOverrides & InboxNotificationOverrides & HistoryVersionPreviewOverrides & AiChatComposerOverrides & AiChatMessageOverrides & AiChatOverrides;
|
|
117
118
|
declare function useOverrides(overrides?: Partial<Overrides>): Overrides;
|
|
118
119
|
|
|
120
|
+
type AiChatComponentsEmptyProps = Record<string, never>;
|
|
121
|
+
type AiChatComponentsLoadingProps = Record<string, never>;
|
|
122
|
+
type AiChatComponents = {
|
|
123
|
+
Empty: ComponentType<AiChatComponentsEmptyProps>;
|
|
124
|
+
Loading: ComponentType<AiChatComponentsLoadingProps>;
|
|
125
|
+
};
|
|
119
126
|
interface AiChatProps extends ComponentProps<"div"> {
|
|
120
127
|
/**
|
|
121
128
|
* The id of the chat the composer belongs to.
|
|
@@ -131,19 +138,68 @@ interface AiChatProps extends ComponentProps<"div"> {
|
|
|
131
138
|
copilotId?: string;
|
|
132
139
|
/**
|
|
133
140
|
* The contextual knowledge to include in the chat. May be used by the assistant when generating responses.
|
|
141
|
+
* Any knowledge you provide via this prop will be added to any already globally registered knowledge via <RegisterAiKnowledge />.
|
|
134
142
|
*/
|
|
135
|
-
|
|
143
|
+
knowledge?: AiKnowledgeSource[];
|
|
136
144
|
/**
|
|
137
145
|
* Tool definitions to make available within this chat. May be used by the assistant when generating responses.
|
|
138
146
|
*/
|
|
139
|
-
tools?: Record<string,
|
|
147
|
+
tools?: Record<string, AiOpaqueToolDefinition>;
|
|
148
|
+
/**
|
|
149
|
+
* The layout of the chat and its composer.
|
|
150
|
+
*/
|
|
151
|
+
layout?: "inset" | "compact";
|
|
140
152
|
/**
|
|
141
153
|
* Override the component's strings.
|
|
142
154
|
*/
|
|
143
155
|
overrides?: Partial<GlobalOverrides & AiChatMessageOverrides & AiChatComposerOverrides & AiChatOverrides>;
|
|
156
|
+
/**
|
|
157
|
+
* Override the component's components.
|
|
158
|
+
*/
|
|
159
|
+
components?: Partial<GlobalComponents & AiChatComponents>;
|
|
144
160
|
}
|
|
145
161
|
declare const AiChat: react.ForwardRefExoticComponent<Omit<AiChatProps, "ref"> & react.RefAttributes<HTMLDivElement>>;
|
|
146
162
|
|
|
163
|
+
interface AiToolProps extends Omit<ComponentProps<"div">, "title" | "children"> {
|
|
164
|
+
/**
|
|
165
|
+
* The tool's title.
|
|
166
|
+
*
|
|
167
|
+
* By default, a human-readable version of the tool's name is used:
|
|
168
|
+
* - `"showTodo"` → "Show todo"
|
|
169
|
+
* - `"get_weather"` → "Get weather"
|
|
170
|
+
*/
|
|
171
|
+
title?: string;
|
|
172
|
+
/**
|
|
173
|
+
* An optional icon displayed next to the title.
|
|
174
|
+
*/
|
|
175
|
+
icon?: ReactNode;
|
|
176
|
+
/**
|
|
177
|
+
* The content shown in the tool.
|
|
178
|
+
*/
|
|
179
|
+
children?: ReactNode;
|
|
180
|
+
}
|
|
181
|
+
type AiToolIconProps = ComponentProps<"div">;
|
|
182
|
+
type AiToolInspectorProps = ComponentProps<"div">;
|
|
183
|
+
/**
|
|
184
|
+
* @private This API will change, and is not considered stable. DO NOT RELY on it.
|
|
185
|
+
*
|
|
186
|
+
* This component can be used to build human-in-the-loop interfaces.
|
|
187
|
+
*/
|
|
188
|
+
interface AiToolConfirmationProps<A extends JsonObject, R extends ToolResultData> extends ComponentProps<"div"> {
|
|
189
|
+
args?: A;
|
|
190
|
+
confirm: AiToolExecuteCallback<A, R>;
|
|
191
|
+
cancel: AiToolExecuteCallback<A, R>;
|
|
192
|
+
variant?: "default" | "destructive";
|
|
193
|
+
}
|
|
194
|
+
declare function AiToolIcon({ className, ...props }: AiToolIconProps): react_jsx_runtime.JSX.Element;
|
|
195
|
+
declare function AiToolInspector({ className, ...props }: AiToolInspectorProps): react_jsx_runtime.JSX.Element;
|
|
196
|
+
declare function AiToolConfirmation<TPack extends AiToolTypePack, A extends JsonObject = TPack["A"], R extends ToolResultData = TPack["R"]>({ children, variant, confirm, cancel, className, ...props }: AiToolConfirmationProps<A, R>): react_jsx_runtime.JSX.Element | null;
|
|
197
|
+
declare const AiTool: react.ForwardRefExoticComponent<Omit<AiToolProps, "ref"> & react.RefAttributes<HTMLDivElement>> & {
|
|
198
|
+
Icon: typeof AiToolIcon;
|
|
199
|
+
Inspector: typeof AiToolInspector;
|
|
200
|
+
Confirmation: typeof AiToolConfirmation;
|
|
201
|
+
};
|
|
202
|
+
|
|
147
203
|
interface ComposerEditorMentionProps {
|
|
148
204
|
/**
|
|
149
205
|
* Whether the mention is selected.
|
|
@@ -437,11 +493,6 @@ type HistoryVersionSummaryListProps = ComponentPropsWithoutRef<"ol">;
|
|
|
437
493
|
*/
|
|
438
494
|
declare const HistoryVersionSummaryList: react.ForwardRefExoticComponent<Omit<react.DetailedHTMLProps<react.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & react.RefAttributes<HTMLOListElement>>;
|
|
439
495
|
|
|
440
|
-
interface GlobalComponents {
|
|
441
|
-
Anchor: ComponentType<ComponentPropsWithoutRef<"a">> | "a";
|
|
442
|
-
}
|
|
443
|
-
type Components = GlobalComponents;
|
|
444
|
-
|
|
445
496
|
interface AvatarProps extends ComponentProps<"div"> {
|
|
446
497
|
/**
|
|
447
498
|
* The user ID to display the avatar for.
|
|
@@ -745,6 +796,8 @@ declare function BoldIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.E
|
|
|
745
796
|
|
|
746
797
|
declare function CheckIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
747
798
|
|
|
799
|
+
declare function CheckCircleIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
800
|
+
|
|
748
801
|
declare function ChevronDownIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
749
802
|
|
|
750
803
|
declare function ChevronLeftIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
@@ -825,6 +878,7 @@ declare namespace icon {
|
|
|
825
878
|
BlockquoteIcon as Blockquote,
|
|
826
879
|
BoldIcon as Bold,
|
|
827
880
|
CheckIcon as Check,
|
|
881
|
+
CheckCircleIcon as CheckCircle,
|
|
828
882
|
ChevronDownIcon as ChevronDown,
|
|
829
883
|
ChevronLeftIcon as ChevronLeft,
|
|
830
884
|
ChevronRightIcon as ChevronRight,
|
|
@@ -862,4 +916,4 @@ declare namespace icon {
|
|
|
862
916
|
};
|
|
863
917
|
}
|
|
864
918
|
|
|
865
|
-
export { AiChat, AiChatProps, Comment, CommentAttachmentArgs, CommentOverrides, CommentProps, Composer, ComposerBodyMark, ComposerBodyMarks, ComposerOverrides, ComposerProps, ComposerSubmitComment, GlobalOverrides, HistoryVersionSummary, HistoryVersionSummaryList, HistoryVersionSummaryListProps, HistoryVersionSummaryProps, icon as Icon, InboxNotification, InboxNotificationAvatarProps, InboxNotificationCustomKindProps, InboxNotificationCustomProps, InboxNotificationIconProps, InboxNotificationList, InboxNotificationListProps, InboxNotificationOverrides, InboxNotificationProps, InboxNotificationTextMentionKindProps, InboxNotificationTextMentionProps, InboxNotificationThreadKindProps, InboxNotificationThreadProps, LiveblocksUIConfig, LocalizationOverrides, Overrides, Thread, ThreadOverrides, ThreadProps, useOverrides };
|
|
919
|
+
export { AiChat, AiChatProps, AiTool, AiToolIconProps, AiToolProps, Comment, CommentAttachmentArgs, CommentOverrides, CommentProps, Composer, ComposerBodyMark, ComposerBodyMarks, ComposerOverrides, ComposerProps, ComposerSubmitComment, GlobalOverrides, HistoryVersionSummary, HistoryVersionSummaryList, HistoryVersionSummaryListProps, HistoryVersionSummaryProps, icon as Icon, InboxNotification, InboxNotificationAvatarProps, InboxNotificationCustomKindProps, InboxNotificationCustomProps, InboxNotificationIconProps, InboxNotificationList, InboxNotificationListProps, InboxNotificationOverrides, InboxNotificationProps, InboxNotificationTextMentionKindProps, InboxNotificationTextMentionProps, InboxNotificationThreadKindProps, InboxNotificationThreadProps, LiveblocksUIConfig, LocalizationOverrides, Overrides, Thread, ThreadOverrides, ThreadProps, useOverrides };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,13 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import { CommentAttachment, AiKnowledgeSource,
|
|
2
|
+
import { ComponentType, ComponentPropsWithoutRef, ElementType, ReactNode, ComponentProps, FormEvent, RefAttributes, MouseEvent, PropsWithChildren } from 'react';
|
|
3
|
+
import { CommentAttachment, AiKnowledgeSource, AiOpaqueToolDefinition, AiToolTypePack, JsonObject, ToolResultData, AiToolExecuteCallback, CommentBody, BaseMetadata, DM, CommentData, HistoryVersion, InboxNotificationData, InboxNotificationThreadData, InboxNotificationTextMentionData, InboxNotificationCustomData, KDAD, ThreadData } from '@liveblocks/core';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
|
|
6
|
+
interface GlobalComponents {
|
|
7
|
+
Anchor: ComponentType<ComponentPropsWithoutRef<"a">> | "a";
|
|
8
|
+
}
|
|
9
|
+
type Components = GlobalComponents;
|
|
10
|
+
|
|
6
11
|
type Direction = "ltr" | "rtl";
|
|
7
12
|
type SlotProp = {
|
|
8
13
|
/**
|
|
@@ -76,15 +81,11 @@ interface ComposerOverrides {
|
|
|
76
81
|
interface AiChatComposerOverrides {
|
|
77
82
|
AI_CHAT_COMPOSER_PLACEHOLDER: string;
|
|
78
83
|
AI_CHAT_COMPOSER_SEND: string;
|
|
79
|
-
AI_CHAT_COMPOSER_ATTACH_FILES: string;
|
|
80
|
-
AI_CHAT_COMPOSER_REMOVE_ATTACHMENT: string;
|
|
81
84
|
AI_CHAT_COMPOSER_ABORT: string;
|
|
82
85
|
}
|
|
83
86
|
interface AiChatMessageOverrides {
|
|
84
87
|
AI_CHAT_MESSAGE_DELETED: string;
|
|
85
88
|
AI_CHAT_MESSAGE_THINKING: string;
|
|
86
|
-
AI_CHAT_MESSAGE_COPY: string;
|
|
87
|
-
AI_CHAT_MESSAGE_TRY_AGAIN: string;
|
|
88
89
|
}
|
|
89
90
|
interface AiChatOverrides {
|
|
90
91
|
AI_CHAT_MESSAGES_ERROR: (error: Error) => ReactNode;
|
|
@@ -116,6 +117,12 @@ interface HistoryVersionPreviewOverrides {
|
|
|
116
117
|
type Overrides = LocalizationOverrides & GlobalOverrides & ComposerOverrides & CommentOverrides & ThreadOverrides & InboxNotificationOverrides & HistoryVersionPreviewOverrides & AiChatComposerOverrides & AiChatMessageOverrides & AiChatOverrides;
|
|
117
118
|
declare function useOverrides(overrides?: Partial<Overrides>): Overrides;
|
|
118
119
|
|
|
120
|
+
type AiChatComponentsEmptyProps = Record<string, never>;
|
|
121
|
+
type AiChatComponentsLoadingProps = Record<string, never>;
|
|
122
|
+
type AiChatComponents = {
|
|
123
|
+
Empty: ComponentType<AiChatComponentsEmptyProps>;
|
|
124
|
+
Loading: ComponentType<AiChatComponentsLoadingProps>;
|
|
125
|
+
};
|
|
119
126
|
interface AiChatProps extends ComponentProps<"div"> {
|
|
120
127
|
/**
|
|
121
128
|
* The id of the chat the composer belongs to.
|
|
@@ -131,19 +138,68 @@ interface AiChatProps extends ComponentProps<"div"> {
|
|
|
131
138
|
copilotId?: string;
|
|
132
139
|
/**
|
|
133
140
|
* The contextual knowledge to include in the chat. May be used by the assistant when generating responses.
|
|
141
|
+
* Any knowledge you provide via this prop will be added to any already globally registered knowledge via <RegisterAiKnowledge />.
|
|
134
142
|
*/
|
|
135
|
-
|
|
143
|
+
knowledge?: AiKnowledgeSource[];
|
|
136
144
|
/**
|
|
137
145
|
* Tool definitions to make available within this chat. May be used by the assistant when generating responses.
|
|
138
146
|
*/
|
|
139
|
-
tools?: Record<string,
|
|
147
|
+
tools?: Record<string, AiOpaqueToolDefinition>;
|
|
148
|
+
/**
|
|
149
|
+
* The layout of the chat and its composer.
|
|
150
|
+
*/
|
|
151
|
+
layout?: "inset" | "compact";
|
|
140
152
|
/**
|
|
141
153
|
* Override the component's strings.
|
|
142
154
|
*/
|
|
143
155
|
overrides?: Partial<GlobalOverrides & AiChatMessageOverrides & AiChatComposerOverrides & AiChatOverrides>;
|
|
156
|
+
/**
|
|
157
|
+
* Override the component's components.
|
|
158
|
+
*/
|
|
159
|
+
components?: Partial<GlobalComponents & AiChatComponents>;
|
|
144
160
|
}
|
|
145
161
|
declare const AiChat: react.ForwardRefExoticComponent<Omit<AiChatProps, "ref"> & react.RefAttributes<HTMLDivElement>>;
|
|
146
162
|
|
|
163
|
+
interface AiToolProps extends Omit<ComponentProps<"div">, "title" | "children"> {
|
|
164
|
+
/**
|
|
165
|
+
* The tool's title.
|
|
166
|
+
*
|
|
167
|
+
* By default, a human-readable version of the tool's name is used:
|
|
168
|
+
* - `"showTodo"` → "Show todo"
|
|
169
|
+
* - `"get_weather"` → "Get weather"
|
|
170
|
+
*/
|
|
171
|
+
title?: string;
|
|
172
|
+
/**
|
|
173
|
+
* An optional icon displayed next to the title.
|
|
174
|
+
*/
|
|
175
|
+
icon?: ReactNode;
|
|
176
|
+
/**
|
|
177
|
+
* The content shown in the tool.
|
|
178
|
+
*/
|
|
179
|
+
children?: ReactNode;
|
|
180
|
+
}
|
|
181
|
+
type AiToolIconProps = ComponentProps<"div">;
|
|
182
|
+
type AiToolInspectorProps = ComponentProps<"div">;
|
|
183
|
+
/**
|
|
184
|
+
* @private This API will change, and is not considered stable. DO NOT RELY on it.
|
|
185
|
+
*
|
|
186
|
+
* This component can be used to build human-in-the-loop interfaces.
|
|
187
|
+
*/
|
|
188
|
+
interface AiToolConfirmationProps<A extends JsonObject, R extends ToolResultData> extends ComponentProps<"div"> {
|
|
189
|
+
args?: A;
|
|
190
|
+
confirm: AiToolExecuteCallback<A, R>;
|
|
191
|
+
cancel: AiToolExecuteCallback<A, R>;
|
|
192
|
+
variant?: "default" | "destructive";
|
|
193
|
+
}
|
|
194
|
+
declare function AiToolIcon({ className, ...props }: AiToolIconProps): react_jsx_runtime.JSX.Element;
|
|
195
|
+
declare function AiToolInspector({ className, ...props }: AiToolInspectorProps): react_jsx_runtime.JSX.Element;
|
|
196
|
+
declare function AiToolConfirmation<TPack extends AiToolTypePack, A extends JsonObject = TPack["A"], R extends ToolResultData = TPack["R"]>({ children, variant, confirm, cancel, className, ...props }: AiToolConfirmationProps<A, R>): react_jsx_runtime.JSX.Element | null;
|
|
197
|
+
declare const AiTool: react.ForwardRefExoticComponent<Omit<AiToolProps, "ref"> & react.RefAttributes<HTMLDivElement>> & {
|
|
198
|
+
Icon: typeof AiToolIcon;
|
|
199
|
+
Inspector: typeof AiToolInspector;
|
|
200
|
+
Confirmation: typeof AiToolConfirmation;
|
|
201
|
+
};
|
|
202
|
+
|
|
147
203
|
interface ComposerEditorMentionProps {
|
|
148
204
|
/**
|
|
149
205
|
* Whether the mention is selected.
|
|
@@ -437,11 +493,6 @@ type HistoryVersionSummaryListProps = ComponentPropsWithoutRef<"ol">;
|
|
|
437
493
|
*/
|
|
438
494
|
declare const HistoryVersionSummaryList: react.ForwardRefExoticComponent<Omit<react.DetailedHTMLProps<react.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & react.RefAttributes<HTMLOListElement>>;
|
|
439
495
|
|
|
440
|
-
interface GlobalComponents {
|
|
441
|
-
Anchor: ComponentType<ComponentPropsWithoutRef<"a">> | "a";
|
|
442
|
-
}
|
|
443
|
-
type Components = GlobalComponents;
|
|
444
|
-
|
|
445
496
|
interface AvatarProps extends ComponentProps<"div"> {
|
|
446
497
|
/**
|
|
447
498
|
* The user ID to display the avatar for.
|
|
@@ -745,6 +796,8 @@ declare function BoldIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.E
|
|
|
745
796
|
|
|
746
797
|
declare function CheckIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
747
798
|
|
|
799
|
+
declare function CheckCircleIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
800
|
+
|
|
748
801
|
declare function ChevronDownIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
749
802
|
|
|
750
803
|
declare function ChevronLeftIcon(props: ComponentProps<"svg">): react_jsx_runtime.JSX.Element;
|
|
@@ -825,6 +878,7 @@ declare namespace icon {
|
|
|
825
878
|
BlockquoteIcon as Blockquote,
|
|
826
879
|
BoldIcon as Bold,
|
|
827
880
|
CheckIcon as Check,
|
|
881
|
+
CheckCircleIcon as CheckCircle,
|
|
828
882
|
ChevronDownIcon as ChevronDown,
|
|
829
883
|
ChevronLeftIcon as ChevronLeft,
|
|
830
884
|
ChevronRightIcon as ChevronRight,
|
|
@@ -862,4 +916,4 @@ declare namespace icon {
|
|
|
862
916
|
};
|
|
863
917
|
}
|
|
864
918
|
|
|
865
|
-
export { AiChat, AiChatProps, Comment, CommentAttachmentArgs, CommentOverrides, CommentProps, Composer, ComposerBodyMark, ComposerBodyMarks, ComposerOverrides, ComposerProps, ComposerSubmitComment, GlobalOverrides, HistoryVersionSummary, HistoryVersionSummaryList, HistoryVersionSummaryListProps, HistoryVersionSummaryProps, icon as Icon, InboxNotification, InboxNotificationAvatarProps, InboxNotificationCustomKindProps, InboxNotificationCustomProps, InboxNotificationIconProps, InboxNotificationList, InboxNotificationListProps, InboxNotificationOverrides, InboxNotificationProps, InboxNotificationTextMentionKindProps, InboxNotificationTextMentionProps, InboxNotificationThreadKindProps, InboxNotificationThreadProps, LiveblocksUIConfig, LocalizationOverrides, Overrides, Thread, ThreadOverrides, ThreadProps, useOverrides };
|
|
919
|
+
export { AiChat, AiChatProps, AiTool, AiToolIconProps, AiToolProps, Comment, CommentAttachmentArgs, CommentOverrides, CommentProps, Composer, ComposerBodyMark, ComposerBodyMarks, ComposerOverrides, ComposerProps, ComposerSubmitComment, GlobalOverrides, HistoryVersionSummary, HistoryVersionSummaryList, HistoryVersionSummaryListProps, HistoryVersionSummaryProps, icon as Icon, InboxNotification, InboxNotificationAvatarProps, InboxNotificationCustomKindProps, InboxNotificationCustomProps, InboxNotificationIconProps, InboxNotificationList, InboxNotificationListProps, InboxNotificationOverrides, InboxNotificationProps, InboxNotificationTextMentionKindProps, InboxNotificationTextMentionProps, InboxNotificationThreadKindProps, InboxNotificationThreadProps, LiveblocksUIConfig, LocalizationOverrides, Overrides, Thread, ThreadOverrides, ThreadProps, useOverrides };
|