@antdv-next/x 0.0.4 → 0.2.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 (56) hide show
  1. package/LICENSE +21 -0
  2. package/dist/_utils/vue.d.ts +2 -0
  3. package/dist/_utils/vue.js +16 -0
  4. package/dist/actions/Actions.js +4 -3
  5. package/dist/actions/ActionsAudio.js +1 -1
  6. package/dist/actions/ActionsCopy.js +5 -5
  7. package/dist/actions/ActionsFeedback.js +1 -1
  8. package/dist/actions/ActionsItem.js +1 -1
  9. package/dist/attachments/PlaceholderUploader.d.ts +16 -0
  10. package/dist/attachments/PlaceholderUploader.js +31 -5
  11. package/dist/attachments/index.d.ts +8 -1
  12. package/dist/attachments/index.js +8 -2
  13. package/dist/bubble/Bubble.js +6 -9
  14. package/dist/bubble/BubbleList.js +5 -5
  15. package/dist/bubble/Divider.js +2 -2
  16. package/dist/bubble/System.js +1 -1
  17. package/dist/code-highlighter/CodeHighlighter.js +3 -14
  18. package/dist/code-highlighter/shiki.d.ts +4 -0
  19. package/dist/code-highlighter/shiki.js +73 -0
  20. package/dist/conversations/Creation.js +1 -1
  21. package/dist/conversations/GroupTitle.d.ts +22 -2
  22. package/dist/conversations/GroupTitle.js +25 -3
  23. package/dist/conversations/Item.d.ts +1 -1
  24. package/dist/conversations/Item.js +1 -4
  25. package/dist/conversations/index.d.ts +10 -1
  26. package/dist/conversations/index.js +13 -1
  27. package/dist/conversations/interface.d.ts +7 -0
  28. package/dist/file-card/FileCard.js +2 -2
  29. package/dist/file-card/List.js +2 -2
  30. package/dist/file-card/components/File.d.ts +6 -6
  31. package/dist/file-card/components/File.js +2 -2
  32. package/dist/index.esm.js +287 -158
  33. package/dist/index.js +0 -25
  34. package/dist/index.umd.js +292 -162
  35. package/dist/mermaid/Mermaid.d.ts +6 -1
  36. package/dist/mermaid/Mermaid.js +27 -6
  37. package/dist/mermaid/index.d.ts +1 -1
  38. package/dist/mermaid/loader.d.ts +6 -0
  39. package/dist/mermaid/loader.js +33 -0
  40. package/dist/mermaid/mermaid-core.d.js +0 -0
  41. package/dist/package.js +1 -1
  42. package/dist/prompts/Prompts.js +7 -8
  43. package/dist/sender/Sender.js +1 -1
  44. package/dist/sender/SenderHeader.js +1 -1
  45. package/dist/sender/SenderSwitch.js +1 -1
  46. package/dist/sources/Sources.js +2 -5
  47. package/dist/sources/components/CarouselCard.js +1 -4
  48. package/dist/suggestion/Suggestion.js +2 -5
  49. package/dist/think/Think.js +1 -1
  50. package/dist/thought-chain/Item.js +4 -7
  51. package/dist/thought-chain/Node.js +1 -4
  52. package/dist/thought-chain/ThoughtChain.js +1 -1
  53. package/dist/welcome/index.js +1 -1
  54. package/dist/x-provider/index.js +1 -1
  55. package/global.d.ts +61 -18
  56. package/package.json +3 -2
@@ -1,5 +1,5 @@
1
- import { CSSProperties, PropType, StyleValue, VNodeChild, HTMLAttributes } from 'vue';
2
1
  import { MermaidConfig } from 'mermaid';
2
+ import { CSSProperties, PropType, StyleValue, VNodeChild, HTMLAttributes } from 'vue';
3
3
  import { ItemType } from '../actions';
4
4
  import { CodeHighlighterProps } from '../code-highlighter';
5
5
  export type MermaidSemanticType = "root" | "header" | "graph" | "code";
@@ -28,6 +28,11 @@ export interface MermaidProps extends Omit<HTMLAttributes, "content" | "class" |
28
28
  export interface MermaidRef {
29
29
  nativeElement: HTMLDivElement;
30
30
  }
31
+ export interface MermaidCustomActionSlotInfo {
32
+ item: ItemType;
33
+ index: number;
34
+ originNode: VNodeChild;
35
+ }
31
36
  declare enum RenderType {
32
37
  Code = "code",
33
38
  Image = "image"
@@ -1,15 +1,16 @@
1
1
  import useXComponentConfig from "../_utils/hooks/use-x-component-config.js";
2
+ import { isEmptyNode } from "../_utils/vue.js";
2
3
  import warning from "../_utils/warning.js";
3
4
  import ActionsWithSub from "../actions/index.js";
4
5
  import localeValues from "../locale/en_US.js";
5
6
  import useLocale from "../locale/useLocale.js";
6
7
  import code_highlighter_default from "../code-highlighter/index.js";
8
+ import { initializeMermaid, parseMermaid, renderMermaid } from "./loader.js";
7
9
  import style_default from "./style/index.js";
8
10
  import { computed, createVNode, defineComponent, mergeProps, onBeforeUnmount, ref, useAttrs, watch } from "vue";
9
11
  import { useConfig } from "antdv-next/dist/config-provider/context";
10
12
  import { Button, Segmented, Tooltip } from "antdv-next";
11
13
  import { DownloadOutlined, ZoomInOutlined, ZoomOutOutlined } from "@antdv-next/icons";
12
- import mermaid from "mermaid";
13
14
  //#region components/mermaid/Mermaid.tsx
14
15
  var RenderType = /* @__PURE__ */ function(RenderType) {
15
16
  RenderType["Code"] = "code";
@@ -55,7 +56,7 @@ function throttle(fn, wait) {
55
56
  return throttled;
56
57
  }
57
58
  var XMermaid = /* @__PURE__ */ defineComponent({
58
- name: "XMermaid",
59
+ name: "AxMermaid",
59
60
  inheritAttrs: false,
60
61
  props: {
61
62
  content: {
@@ -168,6 +169,26 @@ var XMermaid = /* @__PURE__ */ defineComponent({
168
169
  const { class: _class, style: _style, ...rest } = attrs;
169
170
  return rest;
170
171
  });
172
+ const getNamedSlot = (name) => slots[name] ?? slots[name.replace(/[A-Z]/g, (s) => `-${s.toLowerCase()}`)];
173
+ const resolvedCustomActions = computed(() => mergedActions.value.customActions.map((item, index) => {
174
+ const iconSlotInfo = {
175
+ item,
176
+ index,
177
+ originNode: item.icon
178
+ };
179
+ const iconFromSlot = getNamedSlot("customActionIconRender")?.(iconSlotInfo);
180
+ const actionSlotInfo = {
181
+ item,
182
+ index,
183
+ originNode: item.actionRender !== void 0 ? typeof item.actionRender === "function" ? item.actionRender(item) : item.actionRender : void 0
184
+ };
185
+ const actionFromSlot = getNamedSlot("customActionRender")?.(actionSlotInfo);
186
+ return {
187
+ ...item,
188
+ icon: iconFromSlot !== void 0 && !isEmptyNode(iconFromSlot) ? iconFromSlot : item.icon,
189
+ actionRender: actionFromSlot !== void 0 && !isEmptyNode(actionFromSlot) ? actionFromSlot : item.actionRender
190
+ };
191
+ }));
171
192
  function applySvgTransform() {
172
193
  if (mergedRenderType.value !== RenderType.Image) return;
173
194
  const svgEl = graphRef.value?.querySelector("svg");
@@ -186,8 +207,8 @@ var XMermaid = /* @__PURE__ */ defineComponent({
186
207
  const graphEl = graphRef.value;
187
208
  if (!graphEl) return;
188
209
  try {
189
- if (await mermaid.parse(props.content, { suppressErrors: true }) === false) throw new Error("Invalid Mermaid syntax");
190
- const { svg } = await mermaid.render(`${renderBaseId}-${idSeed++}-${props.content.length || 0}`, props.content);
210
+ if (await parseMermaid(props.content, { suppressErrors: true }) === false) throw new Error("Invalid Mermaid syntax");
211
+ const { svg } = await renderMermaid(`${renderBaseId}-${idSeed++}-${props.content.length || 0}`, props.content);
191
212
  graphEl.innerHTML = svg;
192
213
  applySvgTransform();
193
214
  } catch (error) {
@@ -295,7 +316,7 @@ var XMermaid = /* @__PURE__ */ defineComponent({
295
316
  key: "copy",
296
317
  actionRender: () => createVNode(ActionsWithSub.Copy, { "text": props.content }, null)
297
318
  });
298
- return [...items, ...mergedActions.value.customActions];
319
+ return [...items, ...resolvedCustomActions.value];
299
320
  });
300
321
  function renderHeader() {
301
322
  if (props.header === null) return null;
@@ -320,7 +341,7 @@ var XMermaid = /* @__PURE__ */ defineComponent({
320
341
  if (next !== void 0) internalRenderType.value = next;
321
342
  });
322
343
  watch(() => props.config, (nextConfig) => {
323
- mermaid.initialize({
344
+ initializeMermaid({
324
345
  startOnLoad: false,
325
346
  securityLevel: "strict",
326
347
  theme: "default",
@@ -1,3 +1,3 @@
1
1
  import { default as Mermaid } from './Mermaid';
2
- export type { MermaidActions, MermaidProps, MermaidRef, MermaidRenderType, MermaidSemanticType, } from './Mermaid';
2
+ export type { MermaidActions, MermaidCustomActionSlotInfo, MermaidProps, MermaidRef, MermaidRenderType, MermaidSemanticType, } from './Mermaid';
3
3
  export default Mermaid;
@@ -0,0 +1,6 @@
1
+ import { MermaidConfig } from 'mermaid';
2
+ type MermaidInstance = (typeof import("mermaid/dist/mermaid.core.mjs"))["default"];
3
+ export declare function initializeMermaid(config: MermaidConfig): void;
4
+ export declare function parseMermaid(content: string, options?: Parameters<MermaidInstance["parse"]>[1]): Promise<false | import('mermaid').ParseResult>;
5
+ export declare function renderMermaid(id: string, content: string, container?: Element): Promise<import('mermaid').RenderResult>;
6
+ export {};
@@ -0,0 +1,33 @@
1
+ //#region components/mermaid/loader.ts
2
+ var mermaidInstance = null;
3
+ var mermaidPromise = null;
4
+ var pendingInitializeConfig = null;
5
+ async function loadMermaid() {
6
+ if (mermaidInstance) return mermaidInstance;
7
+ if (!mermaidPromise) mermaidPromise = import("mermaid/dist/mermaid.core.mjs").then((mod) => mod.default).then((instance) => {
8
+ mermaidInstance = instance;
9
+ if (pendingInitializeConfig) {
10
+ instance.initialize(pendingInitializeConfig);
11
+ pendingInitializeConfig = null;
12
+ }
13
+ return instance;
14
+ });
15
+ return mermaidPromise;
16
+ }
17
+ function initializeMermaid(config) {
18
+ pendingInitializeConfig = config;
19
+ if (mermaidInstance) {
20
+ mermaidInstance.initialize(config);
21
+ pendingInitializeConfig = null;
22
+ return;
23
+ }
24
+ loadMermaid();
25
+ }
26
+ async function parseMermaid(content, options) {
27
+ return (await loadMermaid()).parse(content, options);
28
+ }
29
+ async function renderMermaid(id, content, container) {
30
+ return (await loadMermaid()).render(id, content, container);
31
+ }
32
+ //#endregion
33
+ export { initializeMermaid, parseMermaid, renderMermaid };
File without changes
package/dist/package.js CHANGED
@@ -1,4 +1,4 @@
1
1
  //#region package.json
2
- var version = "0.0.4";
2
+ var version = "0.2.0";
3
3
  //#endregion
4
4
  export { version };
@@ -1,4 +1,5 @@
1
1
  import useXComponentConfig from "../_utils/hooks/use-x-component-config.js";
2
+ import { hasRenderableNode } from "../_utils/vue.js";
2
3
  import style_default from "./style/index.js";
3
4
  import { computed, createVNode, defineComponent, mergeProps, nextTick, onMounted, ref, useAttrs } from "vue";
4
5
  import { useConfig } from "antdv-next/dist/config-provider/context";
@@ -19,12 +20,8 @@ function getItemDomAttrs(item) {
19
20
  delete domAttrs.children;
20
21
  return domAttrs;
21
22
  }
22
- function hasRenderableNode(node) {
23
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
24
- return node !== null && node !== void 0 && node !== false;
25
- }
26
23
  var XPrompts = /* @__PURE__ */ defineComponent({
27
- name: "XPrompts",
24
+ name: "AxPrompts",
28
25
  inheritAttrs: false,
29
26
  props: {
30
27
  items: {
@@ -144,8 +141,10 @@ var XPrompts = /* @__PURE__ */ defineComponent({
144
141
  };
145
142
  });
146
143
  const triggerItemClick = (item, nested) => {
147
- if (nested || item.disabled) return;
148
- emit("itemClick", { data: item });
144
+ if (item.disabled || !nested && hasChildren(item)) return;
145
+ const info = { data: item };
146
+ props.onItemClick?.(info);
147
+ emit("itemClick", info);
149
148
  };
150
149
  const renderTitle = () => {
151
150
  if (slots.title) return slots.title({ originNode: props.title });
@@ -190,7 +189,7 @@ var XPrompts = /* @__PURE__ */ defineComponent({
190
189
  }
191
190
  ],
192
191
  "style": [nested ? mergedStyles.value.subItem : mergedStyles.value.item, item.style],
193
- "onClick": () => triggerItemClick(item, itemHasChildren)
192
+ "onClick": () => triggerItemClick(item, nested)
194
193
  }), [hasRenderableNode(iconNode) && createVNode("div", { "class": `${props.prefixCls}-icon` }, [iconNode]), createVNode("div", {
195
194
  "class": [`${props.prefixCls}-content`, mergedClasses.value.itemContent],
196
195
  "style": mergedStyles.value.itemContent
@@ -19,7 +19,7 @@ var sharedRenderComponents = {
19
19
  SpeechButton: SpeechButton_default
20
20
  };
21
21
  var Sender_default = /* @__PURE__ */ defineComponent({
22
- name: "XSender",
22
+ name: "AxSender",
23
23
  inheritAttrs: false,
24
24
  props: {
25
25
  prefixCls: {
@@ -5,7 +5,7 @@ import { Button } from "antdv-next";
5
5
  import { CloseOutlined } from "@antdv-next/icons";
6
6
  //#region components/sender/SenderHeader.tsx
7
7
  var SenderHeader_default = /* @__PURE__ */ defineComponent({
8
- name: "XSenderHeader",
8
+ name: "AxSenderHeader",
9
9
  props: {
10
10
  open: {
11
11
  type: Boolean,
@@ -5,7 +5,7 @@ import { useConfig } from "antdv-next/dist/config-provider/context";
5
5
  import { Button } from "antdv-next";
6
6
  //#region components/sender/SenderSwitch.tsx
7
7
  var SenderSwitch_default = /* @__PURE__ */ defineComponent({
8
- name: "XSenderSwitch",
8
+ name: "AxSenderSwitch",
9
9
  inheritAttrs: false,
10
10
  props: {
11
11
  prefixCls: {
@@ -1,5 +1,6 @@
1
1
  import useXComponentConfig from "../_utils/hooks/use-x-component-config.js";
2
2
  import initCollapseTransition from "../_utils/transition.js";
3
+ import { hasRenderableNode } from "../_utils/vue.js";
3
4
  import CarouselCard from "./components/CarouselCard.js";
4
5
  import style_default from "./style/index.js";
5
6
  import { Fragment, Transition, computed, createVNode, defineComponent, mergeProps, ref, useAttrs } from "vue";
@@ -7,12 +8,8 @@ import { useConfig } from "antdv-next/dist/config-provider/context";
7
8
  import { Popover } from "antdv-next";
8
9
  import { RightOutlined } from "@antdv-next/icons";
9
10
  //#region components/sources/Sources.tsx
10
- var hasRenderableNode = (node) => {
11
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
12
- return node !== null && node !== void 0 && node !== false;
13
- };
14
11
  var XSources = /* @__PURE__ */ defineComponent({
15
- name: "XSources",
12
+ name: "AxSources",
16
13
  inheritAttrs: false,
17
14
  props: {
18
15
  prefixCls: {
@@ -1,11 +1,8 @@
1
+ import { hasRenderableNode } from "../../_utils/vue.js";
1
2
  import { createVNode, defineComponent, nextTick, ref, watch } from "vue";
2
3
  import { Carousel } from "antdv-next";
3
4
  import { LeftOutlined, RightOutlined } from "@antdv-next/icons";
4
5
  //#region components/sources/components/CarouselCard.tsx
5
- var hasRenderableNode = (node) => {
6
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
7
- return node !== null && node !== void 0 && node !== false;
8
- };
9
6
  var CarouselCard = /* @__PURE__ */ defineComponent({
10
7
  name: "XSourcesCarouselCard",
11
8
  props: {
@@ -1,16 +1,13 @@
1
1
  import useXComponentConfig from "../_utils/hooks/use-x-component-config.js";
2
+ import { hasRenderableNode } from "../_utils/vue.js";
2
3
  import style_default from "./style/index.js";
3
4
  import useActive from "./useActive.js";
4
5
  import { computed, createVNode, defineComponent, mergeProps, ref, useAttrs, watch } from "vue";
5
6
  import { useConfig } from "antdv-next/dist/config-provider/context";
6
7
  import { Cascader, Flex } from "antdv-next";
7
8
  //#region components/suggestion/Suggestion.tsx
8
- var hasRenderableNode = (node) => {
9
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
10
- return node !== null && node !== void 0 && node !== false;
11
- };
12
9
  var XSuggestion = /* @__PURE__ */ defineComponent({
13
- name: "XSuggestion",
10
+ name: "AxSuggestion",
14
11
  inheritAttrs: false,
15
12
  props: {
16
13
  prefixCls: {
@@ -6,7 +6,7 @@ import { useConfig } from "antdv-next/dist/config-provider/context";
6
6
  import { LoadingOutlined, RightOutlined } from "@antdv-next/icons";
7
7
  //#region components/think/Think.tsx
8
8
  var XThink = /* @__PURE__ */ defineComponent({
9
- name: "XThink",
9
+ name: "AxThink",
10
10
  inheritAttrs: false,
11
11
  props: {
12
12
  prefixCls: {
@@ -1,14 +1,11 @@
1
+ import { hasRenderableNode } from "../_utils/vue.js";
1
2
  import { STATUS_ICON_MAP } from "./Status.js";
2
3
  import style_default from "./style/index.js";
3
4
  import { computed, createVNode, defineComponent, ref } from "vue";
4
5
  import { useConfig } from "antdv-next/dist/config-provider/context";
5
6
  //#region components/thought-chain/Item.tsx
6
- function hasRenderableNode(node) {
7
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
8
- return node !== null && node !== void 0 && node !== false;
9
- }
10
7
  var XThoughtChainItem = /* @__PURE__ */ defineComponent({
11
- name: "XThoughtChainItem",
8
+ name: "AxThoughtChainItem",
12
9
  props: {
13
10
  prefixCls: {
14
11
  type: String,
@@ -86,9 +83,9 @@ var XThoughtChainItem = /* @__PURE__ */ defineComponent({
86
83
  return () => {
87
84
  const cls = itemPrefixCls.value;
88
85
  const statusCls = `${props.prefixCls}-status`;
89
- const iconRenderSlot = slots.iconRender ?? slots["icon-render"];
86
+ const iconSlot = slots.icon;
90
87
  const originIconNode = props.status ? STATUS_ICON_MAP[props.status] : props.icon;
91
- const iconNode = iconRenderSlot ? iconRenderSlot({
88
+ const iconNode = iconSlot ? iconSlot({
92
89
  originNode: originIconNode,
93
90
  status: props.status
94
91
  }) : originIconNode;
@@ -1,12 +1,9 @@
1
+ import { hasRenderableNode } from "../_utils/vue.js";
1
2
  import { STATUS_ICON_MAP } from "./Status.js";
2
3
  import { Transition, computed, createVNode, defineComponent } from "vue";
3
4
  import { useConfig } from "antdv-next/dist/config-provider/context";
4
5
  import { LeftOutlined, RightOutlined } from "@antdv-next/icons";
5
6
  //#region components/thought-chain/Node.tsx
6
- function hasRenderableNode(node) {
7
- if (Array.isArray(node)) return node.some((item) => item !== null && item !== void 0 && item !== false);
8
- return node !== null && node !== void 0 && node !== false;
9
- }
10
7
  var Node_default = /* @__PURE__ */ defineComponent({
11
8
  name: "ThoughtChainNode",
12
9
  props: {
@@ -5,7 +5,7 @@ import { computed, createVNode, defineComponent, mergeProps, ref, useAttrs, watc
5
5
  import { useConfig } from "antdv-next/dist/config-provider/context";
6
6
  //#region components/thought-chain/ThoughtChain.tsx
7
7
  var XThoughtChain = /* @__PURE__ */ defineComponent({
8
- name: "XThoughtChain",
8
+ name: "AxThoughtChain",
9
9
  inheritAttrs: false,
10
10
  props: {
11
11
  prefixCls: {
@@ -14,7 +14,7 @@ function hasContent(value) {
14
14
  return Array.isArray(value) ? value.length > 0 : value !== null && value !== void 0;
15
15
  }
16
16
  var XWelcome = /* @__PURE__ */ defineComponent({
17
- name: "XWelcome",
17
+ name: "AxWelcome",
18
18
  inheritAttrs: false,
19
19
  props: {
20
20
  prefixCls: {
@@ -4,7 +4,7 @@ import { computed, createVNode, defineComponent, mergeProps, provide, useAttrs }
4
4
  import { ConfigProvider } from "antdv-next";
5
5
  //#region components/x-provider/index.tsx
6
6
  var XProvider = /* @__PURE__ */ defineComponent({
7
- name: "XProvider",
7
+ name: "AxProvider",
8
8
  inheritAttrs: false,
9
9
  props: {
10
10
  attachments: {
package/global.d.ts CHANGED
@@ -1,24 +1,67 @@
1
+ type ActionsComponent = (typeof import("./dist/actions"))["default"];
2
+ type ActionsAudioComponent = (typeof import("./dist/actions"))["ActionsAudio"];
3
+ type ActionsCopyComponent = (typeof import("./dist/actions"))["ActionsCopy"];
4
+ type ActionsFeedbackComponent =
5
+ (typeof import("./dist/actions"))["ActionsFeedback"];
6
+ type ActionsItemComponent = (typeof import("./dist/actions"))["ActionsItem"];
7
+ type AttachmentsComponent = (typeof import("./dist/attachments"))["default"];
8
+ type BubbleComponent = (typeof import("./dist/bubble"))["default"];
9
+ type BubbleListComponent = (typeof import("./dist/bubble"))["BubbleList"];
10
+ type BubbleSystemComponent = (typeof import("./dist/bubble"))["BubbleSystem"];
11
+ type BubbleDividerComponent = (typeof import("./dist/bubble"))["BubbleDivider"];
12
+ type CodeHighlighterComponent =
13
+ (typeof import("./dist/code-highlighter"))["default"];
14
+ type ConversationsComponent =
15
+ (typeof import("./dist/conversations"))["default"];
16
+ type ConversationsCreationComponent =
17
+ (typeof import("./dist/conversations"))["ConversationsCreation"];
18
+ type FileCardComponent = (typeof import("./dist/file-card"))["default"];
19
+ type FileCardListComponent =
20
+ (typeof import("./dist/file-card"))["FileCardList"];
21
+ type MermaidComponent = (typeof import("./dist/mermaid"))["default"];
22
+ type PromptsComponent = (typeof import("./dist/prompts"))["default"];
23
+ type SenderComponent = (typeof import("./dist/sender"))["default"];
24
+ type SenderHeaderComponent = (typeof import("./dist/sender"))["SenderHeader"];
25
+ type SenderSwitchComponent = (typeof import("./dist/sender"))["SenderSwitch"];
26
+ type SourcesComponent = (typeof import("./dist/sources"))["default"];
27
+ type SuggestionComponent = (typeof import("./dist/suggestion"))["default"];
28
+ type ThinkComponent = (typeof import("./dist/think"))["default"];
29
+ type ThoughtChainComponent = (typeof import("./dist/thought-chain"))["default"];
30
+ type ThoughtChainItemComponent =
31
+ (typeof import("./dist/thought-chain"))["ThoughtChainItem"];
32
+ type WelcomeComponent = (typeof import("./dist/welcome"))["default"];
33
+ type XProviderComponent = (typeof import("./dist/x-provider"))["default"];
34
+
1
35
  export {};
2
36
 
3
37
  declare module "vue" {
4
38
  export interface GlobalComponents {
5
- AActions: (typeof import("./dist/actions"))["default"];
6
- AActionsAudio: (typeof import("./dist/actions"))["ActionsAudio"];
7
- AActionsCopy: (typeof import("./dist/actions"))["ActionsCopy"];
8
- AActionsFeedback: (typeof import("./dist/actions"))["ActionsFeedback"];
9
- AActionsItem: (typeof import("./dist/actions"))["ActionsItem"];
10
- ABubble: (typeof import("./dist/bubble"))["default"];
11
- ABubbleList: (typeof import("./dist/bubble"))["BubbleList"];
12
- ABubbleSystem: (typeof import("./dist/bubble"))["BubbleSystem"];
13
- ABubbleDivider: (typeof import("./dist/bubble"))["BubbleDivider"];
14
- XActions: (typeof import("./dist/actions"))["default"];
15
- XActionsAudio: (typeof import("./dist/actions"))["ActionsAudio"];
16
- XActionsCopy: (typeof import("./dist/actions"))["ActionsCopy"];
17
- XActionsFeedback: (typeof import("./dist/actions"))["ActionsFeedback"];
18
- XActionsItem: (typeof import("./dist/actions"))["ActionsItem"];
19
- XBubble: (typeof import("./dist/bubble"))["default"];
20
- XBubbleList: (typeof import("./dist/bubble"))["BubbleList"];
21
- XBubbleSystem: (typeof import("./dist/bubble"))["BubbleSystem"];
22
- XBubbleDivider: (typeof import("./dist/bubble"))["BubbleDivider"];
39
+ AxActions: ActionsComponent;
40
+ AxActionsAudio: ActionsAudioComponent;
41
+ AxActionsCopy: ActionsCopyComponent;
42
+ AxActionsFeedback: ActionsFeedbackComponent;
43
+ AxActionsItem: ActionsItemComponent;
44
+ AxAttachments: AttachmentsComponent;
45
+ AxBubble: BubbleComponent;
46
+ AxBubbleDivider: BubbleDividerComponent;
47
+ AxBubbleList: BubbleListComponent;
48
+ AxBubbleSystem: BubbleSystemComponent;
49
+ AxCodeHighlighter: CodeHighlighterComponent;
50
+ AxConversations: ConversationsComponent;
51
+ AxConversationsCreation: ConversationsCreationComponent;
52
+ AxFileCard: FileCardComponent;
53
+ AxFileCardList: FileCardListComponent;
54
+ AxMermaid: MermaidComponent;
55
+ AxPrompts: PromptsComponent;
56
+ AxProvider: XProviderComponent;
57
+ AxSender: SenderComponent;
58
+ AxSenderHeader: SenderHeaderComponent;
59
+ AxSenderSwitch: SenderSwitchComponent;
60
+ AxSources: SourcesComponent;
61
+ AxSuggestion: SuggestionComponent;
62
+ AxThink: ThinkComponent;
63
+ AxThoughtChain: ThoughtChainComponent;
64
+ AxThoughtChainItem: ThoughtChainItemComponent;
65
+ AxWelcome: WelcomeComponent;
23
66
  }
24
67
  }
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@antdv-next/x",
3
- "version": "0.0.4",
3
+ "version": "0.2.0",
4
+ "license": "MIT",
4
5
  "files": [
5
6
  "dist",
6
7
  "global.d.ts"
@@ -40,7 +41,7 @@
40
41
  "@antdv-next/icons": "^1.0.4",
41
42
  "@v-c/util": "^1.0.19",
42
43
  "@vueuse/core": "^14.2.1",
43
- "antdv-next": "^1.1.2",
44
+ "antdv-next": "^1.1.9-beta.1",
44
45
  "dayjs": "^1.11.19",
45
46
  "mermaid": "^11.12.1",
46
47
  "shiki": "^3.13.0",