@ant-design/agentic-ui 2.0.13 → 2.0.15

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 (105) hide show
  1. package/README.md +12 -12
  2. package/dist/BackTo/BackBottom.d.ts +56 -0
  3. package/dist/BackTo/BackTop.d.ts +39 -2
  4. package/dist/BackTo/index.d.ts +20 -0
  5. package/dist/Bubble/AIBubble.js +4 -2
  6. package/dist/Bubble/List/index.js +1 -1
  7. package/dist/Bubble/UserBubble.js +1 -1
  8. package/dist/Bubble/index.d.ts +6 -0
  9. package/dist/Bubble/style.js +1 -1
  10. package/dist/{ChatBoot → ChatBootPage}/ButtonTab.js +1 -1
  11. package/dist/{ChatBoot → ChatBootPage}/ButtonTabGroup.js +1 -1
  12. package/dist/{ChatBoot → ChatBootPage}/ButtonTabGroupStyle.js +1 -1
  13. package/dist/{ChatBoot → ChatBootPage}/ButtonTabStyle.js +1 -1
  14. package/dist/{ChatBoot → ChatBootPage}/CaseReply.js +2 -2
  15. package/dist/{ChatBoot → ChatBootPage}/CaseReplyStyle.js +1 -1
  16. package/dist/{ChatBoot → ChatBootPage}/Title.js +2 -2
  17. package/dist/{ChatBoot → ChatBootPage}/index.d.ts +6 -0
  18. package/dist/{ChatBoot → ChatBootPage}/index.js +1 -1
  19. package/dist/{ChatBoot → ChatBootPage}/style.js +1 -1
  20. package/dist/Components/ActionIconBox/index.js +1 -1
  21. package/dist/Components/ActionItemBox/ActionItemBox.js +1 -1
  22. package/dist/Components/ActionItemBox/index.d.ts +6 -0
  23. package/dist/Components/Button/index.d.ts +6 -0
  24. package/dist/History/components/HistoryItem.js +2 -2
  25. package/dist/History/components/NewChatComponent.js +1 -1
  26. package/dist/History/components/SearchComponent.d.ts +2 -0
  27. package/dist/History/components/SearchComponent.js +17 -3
  28. package/dist/History/index.d.ts +4 -0
  29. package/dist/History/index.js +10 -9
  30. package/dist/History/menu.d.ts +2 -0
  31. package/dist/History/menu.js +18 -5
  32. package/dist/History/style.js +1 -1
  33. package/dist/History/types/index.d.ts +6 -0
  34. package/dist/MarkdownEditor/BaseMarkdownEditor.js +1 -1
  35. package/dist/MarkdownEditor/editor/components/CommentList/index.js +1 -1
  36. package/dist/MarkdownEditor/editor/components/ContributorAvatar/index.js +1 -1
  37. package/dist/MarkdownEditor/editor/components/fntTag/index.js +1 -1
  38. package/dist/MarkdownEditor/editor/elements/Comment/index.js +1 -1
  39. package/dist/MarkdownEditor/editor/elements/FootnoteDefinition.js +1 -1
  40. package/dist/MarkdownEditor/editor/elements/FootnoteReference.js +1 -1
  41. package/dist/MarkdownEditor/editor/elements/Head.js +1 -1
  42. package/dist/MarkdownEditor/editor/elements/Image/index.js +1 -1
  43. package/dist/MarkdownEditor/editor/elements/LinkCard/index.js +2 -2
  44. package/dist/MarkdownEditor/editor/elements/List/List.js +1 -1
  45. package/dist/MarkdownEditor/editor/elements/List/ListItem.js +1 -1
  46. package/dist/MarkdownEditor/editor/elements/List/style.js +2 -2
  47. package/dist/MarkdownEditor/editor/elements/Media.js +1 -1
  48. package/dist/MarkdownEditor/editor/elements/Paragraph.js +1 -1
  49. package/dist/MarkdownEditor/editor/elements/Table/ReadonlyTableComponent.js +1 -1
  50. package/dist/MarkdownEditor/editor/elements/Table/SimpleTable.js +1 -1
  51. package/dist/MarkdownEditor/editor/elements/Table/Table.js +5 -3
  52. package/dist/MarkdownEditor/editor/elements/Table/TableCellIndex/index.js +3 -1
  53. package/dist/MarkdownEditor/editor/elements/Table/TableCellIndexSpacer/index.js +1 -1
  54. package/dist/MarkdownEditor/editor/elements/Table/TableRowIndex/index.js +1 -1
  55. package/dist/MarkdownEditor/editor/elements/Table/Td/index.js +1 -1
  56. package/dist/MarkdownEditor/editor/elements/TagPopup/index.d.ts +0 -22
  57. package/dist/MarkdownEditor/editor/elements/TagPopup/index.js +171 -122
  58. package/dist/MarkdownEditor/editor/elements/index.js +1 -1
  59. package/dist/MarkdownEditor/editor/style.js +6 -6
  60. package/dist/MarkdownEditor/editor/tools/DragHandle.js +2 -2
  61. package/dist/MarkdownEditor/editor/tools/ToolBar/ToolBar.js +1 -1
  62. package/dist/MarkdownEditor/editor/utils/dom.d.ts +1 -1
  63. package/dist/MarkdownEditor/editor/utils/index.d.ts +1 -1
  64. package/dist/MarkdownInputField/AttachmentButton/AttachmentFileList/index.js +1 -1
  65. package/dist/MarkdownInputField/AttachmentButton/index.js +1 -1
  66. package/dist/MarkdownInputField/AttachmentButton/utils.d.ts +8 -0
  67. package/dist/MarkdownInputField/AttachmentButton/utils.js +10 -3
  68. package/dist/MarkdownInputField/BeforeToolContainer/BeforeToolContainer.js +1 -1
  69. package/dist/MarkdownInputField/Enlargement/index.js +1 -1
  70. package/dist/MarkdownInputField/FileMapView/index.js +5 -2
  71. package/dist/MarkdownInputField/MarkdownInputField.js +1 -1
  72. package/dist/MarkdownInputField/QuickActions/index.js +4 -8
  73. package/dist/MarkdownInputField/RefinePromptButton/index.js +1 -1
  74. package/dist/MarkdownInputField/SendActions/index.js +1 -1
  75. package/dist/MarkdownInputField/SendButton/index.js +1 -1
  76. package/dist/MarkdownInputField/SkillModeBar/index.js +1 -1
  77. package/dist/MarkdownInputField/TopOperatingArea/index.js +1 -1
  78. package/dist/MarkdownInputField/VoiceInput/index.js +1 -1
  79. package/dist/Plugins/chart/index.js +2 -2
  80. package/dist/Plugins/index.d.ts +6 -0
  81. package/dist/Plugins/mermaid/index.js +1 -1
  82. package/dist/Quote/index.js +1 -1
  83. package/dist/Schema/index.d.ts +6 -0
  84. package/dist/ThoughtChainList/DotAni/index.css +1 -1
  85. package/dist/ThoughtChainList/DotAni/index.js +2 -2
  86. package/dist/ToolUseBar/ToolUseBarThink.js +1 -1
  87. package/dist/ToolUseBar/index.js +1 -1
  88. package/dist/WelcomeMessage/index.d.ts +59 -0
  89. package/dist/{Welcome → WelcomeMessage}/index.js +4 -4
  90. package/dist/{Welcome → WelcomeMessage}/style.js +1 -1
  91. package/dist/Workspace/RealtimeFollow/style.js +1 -1
  92. package/dist/Workspace/Task/index.js +1 -1
  93. package/dist/index.d.ts +2 -2
  94. package/dist/index.js +2 -2
  95. package/package.json +1 -1
  96. package/dist/Welcome/index.d.ts +0 -14
  97. /package/dist/{ChatBoot → ChatBootPage}/ButtonTab.d.ts +0 -0
  98. /package/dist/{ChatBoot → ChatBootPage}/ButtonTabGroup.d.ts +0 -0
  99. /package/dist/{ChatBoot → ChatBootPage}/ButtonTabGroupStyle.d.ts +0 -0
  100. /package/dist/{ChatBoot → ChatBootPage}/ButtonTabStyle.d.ts +0 -0
  101. /package/dist/{ChatBoot → ChatBootPage}/CaseReply.d.ts +0 -0
  102. /package/dist/{ChatBoot → ChatBootPage}/CaseReplyStyle.d.ts +0 -0
  103. /package/dist/{ChatBoot → ChatBootPage}/Title.d.ts +0 -0
  104. /package/dist/{ChatBoot → ChatBootPage}/style.d.ts +0 -0
  105. /package/dist/{Welcome → WelcomeMessage}/style.d.ts +0 -0
@@ -38,7 +38,7 @@ var blinkCaret = new Keyframes("blink-caret", {
38
38
  var genStyle = (token) => {
39
39
  return {
40
40
  // 拖拽手柄样式
41
- ".ant-md-editor-drag-handle": {
41
+ ".ant-agentic-md-editor-drag-handle": {
42
42
  position: "absolute",
43
43
  display: "flex",
44
44
  userSelect: "none",
@@ -51,7 +51,7 @@ var genStyle = (token) => {
51
51
  top: "calc(3px + 0.75em - 14px)"
52
52
  },
53
53
  // 拖拽图标样式
54
- ".ant-md-editor-drag-icon": {
54
+ ".ant-agentic-md-editor-drag-icon": {
55
55
  display: "flex",
56
56
  alignItems: "center",
57
57
  borderRadius: "18px",
@@ -64,7 +64,7 @@ var genStyle = (token) => {
64
64
  }
65
65
  },
66
66
  // 拖拽元素悬浮效果
67
- ".ant-md-editor-drag-el:hover > .ant-md-editor-drag-handle": {
67
+ ".ant-agentic-md-editor-drag-el:hover > .ant-agentic-md-editor-drag-handle": {
68
68
  opacity: 1
69
69
  },
70
70
  // 可调整大小组件样式
@@ -114,7 +114,7 @@ var genStyle = (token) => {
114
114
  transitionDuration: "200ms"
115
115
  },
116
116
  // 隐藏样式
117
- ".ant-md-editor-hidden": {
117
+ ".ant-agentic-md-editor-hidden": {
118
118
  display: "none"
119
119
  },
120
120
  // KaTeX容器样式
@@ -228,7 +228,7 @@ var genStyle = (token) => {
228
228
  "h1,h2,h3,h4,h5,h6": {
229
229
  position: "relative",
230
230
  textWrap: "balance",
231
- ".ant-md-editor-drag-handle": {
231
+ ".ant-agentic-md-editor-drag-handle": {
232
232
  top: "calc(3px + 0.05em) !important"
233
233
  }
234
234
  },
@@ -453,7 +453,7 @@ var genStyle = (token) => {
453
453
  margin: "var(--margin-8x) 0"
454
454
  },
455
455
  // 打字机效果样式
456
- ".ant-md-editor-content .typewriter:last-of-type > *:last-of-type span[data-slate-leaf]:last-of-type span[data-slate-string]": {
456
+ ".ant-agentic-md-editor-content .typewriter:last-of-type > *:last-of-type span[data-slate-leaf]:last-of-type span[data-slate-string]": {
457
457
  borderRight: "0.15em solid var(--color-primary-control-fill-primary)",
458
458
  animationName: `${typing.getName()}, ${blinkCaret.getName()}`,
459
459
  animationDuration: "3.5s, 0.5s",
@@ -33,7 +33,7 @@ var DragHandle = (props) => {
33
33
  return /* @__PURE__ */ React.createElement(Tooltip, { title: "拖拽移动" }, /* @__PURE__ */ React.createElement(
34
34
  "span",
35
35
  {
36
- className: "ant-md-editor-drag-handle",
36
+ className: "ant-agentic-md-editor-drag-handle",
37
37
  "data-testid": "drag-handle",
38
38
  style: __spreadValues({}, props.style),
39
39
  contentEditable: false,
@@ -53,7 +53,7 @@ var DragHandle = (props) => {
53
53
  store.draggedElement = parent;
54
54
  }
55
55
  },
56
- /* @__PURE__ */ React.createElement("div", { className: "ant-md-editor-drag-icon" }, /* @__PURE__ */ React.createElement(HolderOutlined, null))
56
+ /* @__PURE__ */ React.createElement("div", { className: "ant-agentic-md-editor-drag-icon" }, /* @__PURE__ */ React.createElement(HolderOutlined, null))
57
57
  ));
58
58
  };
59
59
  export {
@@ -23,7 +23,7 @@ import { BaseToolBar } from "./BaseBar";
23
23
  import { useStyle } from "./toolBarStyle";
24
24
  var ToolBar = (props) => {
25
25
  const context = useContext(ConfigProvider.ConfigContext);
26
- const baseClassName = context == null ? void 0 : context.getPrefixCls(`md-editor-toolbar`);
26
+ const baseClassName = context == null ? void 0 : context.getPrefixCls(`agentic-md-editor-toolbar`);
27
27
  const { wrapSSR, hashId } = useStyle(baseClassName);
28
28
  return wrapSSR(
29
29
  /* @__PURE__ */ React.createElement(
@@ -25,7 +25,7 @@ export declare const slugify: (str: string) => string;
25
25
  * @param name - The name of the file.
26
26
  * @returns The media type of the file.
27
27
  */
28
- export declare const getMediaType: (name?: string, alt?: string) => "document" | "image" | "other" | "audio" | "video" | "markdown" | "attachment";
28
+ export declare const getMediaType: (name?: string, alt?: string) => "document" | "image" | "audio" | "video" | "markdown" | "other" | "attachment";
29
29
  /**
30
30
  * Retrieves the bounding rectangle of the current selection.
31
31
  * @returns The bounding rectangle of the selection, or null if no selection exists.
@@ -13,7 +13,7 @@ type ModalEvent<K extends keyof HookAPI> = {
13
13
  type: K;
14
14
  params: Parameters<HookAPI[K]>[0];
15
15
  };
16
- export declare const modal$: Subject<ModalEvent<"warning" | "info" | "error" | "success" | "confirm">>;
16
+ export declare const modal$: Subject<ModalEvent<"info" | "error" | "warning" | "confirm" | "success">>;
17
17
  export declare const encodeHtml: (str: string) => string;
18
18
  export { isMarkdown } from './isMarkdown';
19
19
  export declare function debounce(func: {
@@ -62,7 +62,7 @@ var AttachmentFileList = ({
62
62
  onClearFileMap
63
63
  }) => {
64
64
  const context = useContext(ConfigProvider.ConfigContext);
65
- const prefix = context == null ? void 0 : context.getPrefixCls("md-editor-attachment-list");
65
+ const prefix = context == null ? void 0 : context.getPrefixCls("agentic-md-editor-attachment-list");
66
66
  const { wrapSSR, hashId } = useStyle(prefix);
67
67
  const [imgSrc, setImgSrc] = React.useState(void 0);
68
68
  const fileList = Array.from((fileMap == null ? void 0 : fileMap.values()) || []);
@@ -205,7 +205,7 @@ var ButtonContent = ({ title }) => {
205
205
  };
206
206
  var AttachmentButton = ({ disabled, uploadImage, title, supportedFormat, render }) => {
207
207
  const context = useContext(ConfigProvider.ConfigContext);
208
- const prefix = context == null ? void 0 : context.getPrefixCls("md-editor-attachment-button");
208
+ const prefix = context == null ? void 0 : context.getPrefixCls("agentic-md-editor-attachment-button");
209
209
  const { wrapSSR, hashId } = useStyle(prefix);
210
210
  const format = supportedFormat || SupportedFileFormats.image;
211
211
  const content = /* @__PURE__ */ React.createElement(ButtonContent, { title });
@@ -1,12 +1,20 @@
1
1
  /**
2
2
  * 将KB转换为可读的文件大小格式
3
+ * 支持从字节(B)到TB的所有单位,最小单位为B
3
4
  *
4
5
  * @param {number} kb - 文件大小(KB)
5
6
  * @returns {string} 格式化后的文件大小字符串
6
7
  *
7
8
  * @example
9
+ * kbToSize(1073741824) // "1 TB"
10
+ * kbToSize(1048576) // "1 GB"
8
11
  * kbToSize(1024) // "1 MB"
9
12
  * kbToSize(512) // "512 KB"
13
+ * kbToSize(1) // "1 KB"
14
+ * kbToSize(0.5) // "512 B"
15
+ * kbToSize(0.1) // "102.4 B"
16
+ * kbToSize(0.0001) // "0.1 B"
17
+ * kbToSize(0) // "0 B"
10
18
  */
11
19
  export declare const kbToSize: (kb: number) => string;
12
20
  /**
@@ -1,8 +1,15 @@
1
1
  // src/MarkdownInputField/AttachmentButton/utils.ts
2
2
  var kbToSize = (kb) => {
3
- const sizes = ["KB", "MB", "GB", "TB"];
4
- const i = Math.floor(Math.log(kb) / Math.log(1024));
5
- return parseFloat((kb / Math.pow(1024, i)).toFixed(2)) + " " + sizes[i];
3
+ const sizes = ["B", "KB", "MB", "GB", "TB"];
4
+ const bytes = kb * 1024;
5
+ if (bytes <= 0) {
6
+ return "0 B";
7
+ }
8
+ if (bytes < 1024) {
9
+ return parseFloat(bytes.toFixed(2)) + " " + sizes[0];
10
+ }
11
+ const i = Math.floor(Math.log(bytes) / Math.log(1024));
12
+ return parseFloat((bytes / Math.pow(1024, i)).toFixed(2)) + " " + sizes[i];
6
13
  };
7
14
  var isImageFile = (file) => {
8
15
  return file.type.startsWith("image/");
@@ -100,7 +100,7 @@ var DraggablePopupItem = React.memo((props) => {
100
100
  DraggablePopupItem.displayName = "DraggablePopupItem";
101
101
  var ActionItemContainer = (props) => {
102
102
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
103
- const basePrefixCls = getPrefixCls("agent-chat-action-item-box");
103
+ const basePrefixCls = getPrefixCls("agentic-chat-action-item-box");
104
104
  const { wrapSSR, hashId } = useStyle(basePrefixCls);
105
105
  const containerRef = useRef(null);
106
106
  const scrollRef = useRef(null);
@@ -9,7 +9,7 @@ var Enlargement = ({
9
9
  onEnlargeClick
10
10
  }) => {
11
11
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
12
- const baseCls = getPrefixCls("md-enlargement");
12
+ const baseCls = getPrefixCls("agentic-md-enlargement");
13
13
  const { wrapSSR, hashId } = useStyle(baseCls);
14
14
  return wrapSSR(
15
15
  /* @__PURE__ */ React.createElement("div", { className: classNames(baseCls, hashId) }, /* @__PURE__ */ React.createElement(
@@ -11,7 +11,7 @@ var FileMapView = (props) => {
11
11
  var _a, _b;
12
12
  const { placement = "left" } = props;
13
13
  const context = useContext(ConfigProvider.ConfigContext);
14
- const prefix = context == null ? void 0 : context.getPrefixCls("md-editor-file-view-list");
14
+ const prefix = context == null ? void 0 : context.getPrefixCls("agentic-md-editor-file-view-list");
15
15
  const { wrapSSR, hashId } = useStyle(prefix);
16
16
  const maxCount = (_a = props.maxDisplayCount) != null ? _a : 3;
17
17
  const fileList = useMemo(() => {
@@ -41,7 +41,10 @@ var FileMapView = (props) => {
41
41
  display: "flex",
42
42
  flexDirection: "column",
43
43
  gap: 4,
44
- alignItems: placement === "left" ? "flex-start" : "flex-end"
44
+ maxWidth: "100%",
45
+ minWidth: 0,
46
+ alignItems: placement === "left" ? "flex-start" : "flex-end",
47
+ width: "max-content"
45
48
  }
46
49
  },
47
50
  /* @__PURE__ */ React.createElement(
@@ -100,7 +100,7 @@ var MarkdownInputField = (_a) => {
100
100
  ]);
101
101
  var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j;
102
102
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
103
- const baseCls = getPrefixCls("md-input-field");
103
+ const baseCls = getPrefixCls("agentic-md-input-field");
104
104
  const { wrapSSR, hashId } = useStyle(baseCls);
105
105
  const [isHover, setHover] = React.useState(false);
106
106
  const [isLoading, setIsLoading] = React.useState(false);
@@ -39,7 +39,7 @@ var QuickActions = React.forwardRef(
39
39
  editorRef,
40
40
  onValueChange,
41
41
  quickActionRender,
42
- prefixCls = "ant-md-input-field",
42
+ prefixCls = "ant-agentic-md-input-field",
43
43
  hashId = "",
44
44
  onResize,
45
45
  isEnlarged = false,
@@ -99,13 +99,9 @@ var QuickActions = React.forwardRef(
99
99
  e.stopPropagation();
100
100
  e.preventDefault();
101
101
  },
102
- className: classNames(
103
- `${prefixCls}-quick-actions`,
104
- hashId,
105
- {
106
- [`${prefixCls}-quick-actions-vertical`]: enlargeable
107
- }
108
- )
102
+ className: classNames(`${prefixCls}-quick-actions`, hashId, {
103
+ [`${prefixCls}-quick-actions-vertical`]: enlargeable
104
+ })
109
105
  },
110
106
  [
111
107
  // Enlargement组件 - 显示在最上方
@@ -38,7 +38,7 @@ function LoadingIcon() {
38
38
  var RefinePromptButton = (props) => {
39
39
  const { isHover, disabled, status, onRefine, style } = props;
40
40
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
41
- const baseCls = getPrefixCls("md-input-field-refine-button");
41
+ const baseCls = getPrefixCls("agentic-md-input-field-refine-button");
42
42
  const { wrapSSR, hashId } = useStyle(baseCls);
43
43
  const handleClick = () => {
44
44
  if (disabled)
@@ -46,7 +46,7 @@ var SendActions = ({
46
46
  onSend,
47
47
  onStop,
48
48
  actionsRender,
49
- prefixCls = "ant-md-input-field",
49
+ prefixCls = "ant-agentic-md-input-field",
50
50
  hashId = "",
51
51
  hasTools = false,
52
52
  onResize
@@ -92,7 +92,7 @@ var SendButton = (props) => {
92
92
  (_a = props.onInit) == null ? void 0 : _a.call(props);
93
93
  }, []);
94
94
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
95
- const baseCls = getPrefixCls("md-input-field-send-button");
95
+ const baseCls = getPrefixCls("agentic-md-input-field-send-button");
96
96
  const { wrapSSR, hashId } = useStyle(baseCls);
97
97
  if (typeof window === "undefined" || typeof document === "undefined" || !window.document) {
98
98
  return null;
@@ -11,7 +11,7 @@ var SkillModeBarInner = ({
11
11
  onSkillModeOpenChange
12
12
  }) => {
13
13
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
14
- const prefixCls = getPrefixCls("skill-mode");
14
+ const prefixCls = getPrefixCls("agentic-skill-mode");
15
15
  const { wrapSSR, hashId } = useStyle(prefixCls);
16
16
  const handleInternalSkillModeChange = useSkillModeState(
17
17
  skillMode,
@@ -7,7 +7,7 @@ import { useStyle } from "./style";
7
7
  var TopOperatingArea = (props) => {
8
8
  const { isShowBackTo = true, targetRef, operationBtnRender } = props;
9
9
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
10
- const prefixCls = getPrefixCls("top-operating-area");
10
+ const prefixCls = getPrefixCls("agentic-top-operating-area");
11
11
  const { wrapSSR, hashId } = useStyle(prefixCls);
12
12
  const renderOperationButtons = () => {
13
13
  if (!operationBtnRender)
@@ -31,7 +31,7 @@ import { useStyle } from "./style";
31
31
  var VoiceInputButton = (props) => {
32
32
  const { recording, disabled, onStart, onStop, style } = props;
33
33
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
34
- const baseCls = getPrefixCls("md-input-field-voice-button");
34
+ const baseCls = getPrefixCls("agentic-md-input-field-voice-button");
35
35
  const { wrapSSR, hashId } = useStyle(baseCls);
36
36
  const dom = props.title ? /* @__PURE__ */ React.createElement(
37
37
  "div",
@@ -140,7 +140,7 @@ var ChartElement = (props) => {
140
140
  () => /* @__PURE__ */ React.createElement(
141
141
  "div",
142
142
  __spreadProps(__spreadValues({
143
- className: "ant-md-editor-drag-el"
143
+ className: "ant-agentic-md-editor-drag-el"
144
144
  }, attributes), {
145
145
  "data-be": "chart",
146
146
  style: {
@@ -156,7 +156,7 @@ var ChartElement = (props) => {
156
156
  /* @__PURE__ */ React.createElement(
157
157
  "div",
158
158
  {
159
- className: "ant-md-editor-chart-box",
159
+ className: "ant-agentic-md-editor-chart-box",
160
160
  style: {
161
161
  display: "flex",
162
162
  flexDirection: "column",
@@ -1,3 +1,9 @@
1
+ /**
2
+ * @file Plugins 插件模块导出
3
+ *
4
+ * 该文件导出 Markdown 编辑器的各种插件功能。
5
+ * 所有插件的详细文档请参考各自的插件定义文件。
6
+ */
1
7
  export * from './chart';
2
8
  export * from './code';
3
9
  export * from './defaultPlugins';
@@ -155,7 +155,7 @@ function MermaidElement(props) {
155
155
  )
156
156
  )
157
157
  ),
158
- /* @__PURE__ */ React.createElement("div", { className: "ant-md-editor-hidden" }, props.children)
158
+ /* @__PURE__ */ React.createElement("div", { className: "ant-agentic-md-editor-hidden" }, props.children)
159
159
  ),
160
160
  /* @__PURE__ */ React.createElement(Mermaid, { el: props.element })
161
161
  );
@@ -17,7 +17,7 @@ var Quote = ({
17
17
  onFileClick
18
18
  }) => {
19
19
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
20
- const prefixCls = getPrefixCls("quote");
20
+ const prefixCls = getPrefixCls("agentic-quote");
21
21
  const { wrapSSR, hashId } = useStyle(prefixCls);
22
22
  const handleFileClick = () => {
23
23
  if (onFileClick && fileName) {
@@ -1,3 +1,9 @@
1
+ /**
2
+ * @file Schema 组件模块导出
3
+ *
4
+ * 该文件导出基于 Schema 的低代码组件。
5
+ * 所有组件的详细文档请参考各自的组件定义文件。
6
+ */
1
7
  import { SchemaEditor } from './SchemaEditor';
2
8
  import { SchemaForm } from './SchemaForm';
3
9
  import { SchemaRenderer, TemplateEngine } from './SchemaRenderer';
@@ -1,5 +1,5 @@
1
1
  /* HTML: <div class="loader"></div> */
2
- .md-editor-loader {
2
+ .agentic-md-editor-loader {
3
3
  width: 20px;
4
4
  display: inline-flex;
5
5
  aspect-ratio: 2;
@@ -3,13 +3,13 @@ import classNames from "classnames";
3
3
  import React from "react";
4
4
  import { useDotAniStyle } from "./style";
5
5
  var DotLoading = () => {
6
- const { wrapSSR, hashId } = useDotAniStyle("md-editor-loader");
6
+ const { wrapSSR, hashId } = useDotAniStyle("agentic-md-editor-loader");
7
7
  return wrapSSR(
8
8
  /* @__PURE__ */ React.createElement(
9
9
  "div",
10
10
  {
11
11
  "data-testid": "dot-loading",
12
- className: classNames("md-editor-loader", hashId),
12
+ className: classNames("agentic-md-editor-loader", hashId),
13
13
  role: "progressbar",
14
14
  "aria-label": "Loading"
15
15
  }
@@ -245,7 +245,7 @@ var ToolUseBarThinkComponent = ({
245
245
  light = false
246
246
  }) => {
247
247
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
248
- const prefixCls = getPrefixCls("tool-use-bar-think");
248
+ const prefixCls = getPrefixCls("agentic-tool-use-bar-think");
249
249
  const { wrapSSR, hashId } = useStyle(prefixCls);
250
250
  const [expandedState, setExpandedState] = useMergedState(defaultExpanded, {
251
251
  value: expanded,
@@ -36,7 +36,7 @@ var ToolUseBarComponent = (_a) => {
36
36
  "light"
37
37
  ]);
38
38
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
39
- const prefixCls = getPrefixCls("tool-use-bar");
39
+ const prefixCls = getPrefixCls("agentic-tool-use-bar");
40
40
  const { wrapSSR, hashId } = useStyle(prefixCls);
41
41
  const [activeKeys, setActiveKeys] = useMergedState(
42
42
  props.defaultActiveKeys || [],
@@ -0,0 +1,59 @@
1
+ import React from 'react';
2
+ /**
3
+ * WelcomeMessage 组件的属性接口
4
+ * @interface WelcomeMessageProps
5
+ */
6
+ export interface WelcomeMessageProps {
7
+ /** 标题 */
8
+ title?: React.ReactNode;
9
+ /** 描述 */
10
+ description?: React.ReactNode;
11
+ /** 自定义样式类名,用于各个提示项的不同部分 */
12
+ classNames?: {
13
+ title?: string;
14
+ description?: string;
15
+ };
16
+ /** 自定义样式 */
17
+ style?: React.CSSProperties;
18
+ /** 自定义根节点样式类名 */
19
+ rootClassName?: string;
20
+ }
21
+ /**
22
+ * WelcomeMessage 组件 - 欢迎消息组件
23
+ *
24
+ * 该组件用于显示聊天开始时的欢迎消息,包含标题和描述信息。
25
+ * 适用于聊天机器人、客服系统等场景的初始欢迎界面。
26
+ *
27
+ * @component
28
+ * @description 欢迎消息组件,用于显示聊天开始时的欢迎信息
29
+ * @param {WelcomeMessageProps} props - 组件属性
30
+ * @param {React.ReactNode} [props.title] - 欢迎标题
31
+ * @param {React.ReactNode} [props.description] - 欢迎描述
32
+ * @param {Object} [props.classNames] - 自定义样式类名
33
+ * @param {string} [props.classNames.title] - 标题样式类名
34
+ * @param {string} [props.classNames.description] - 描述样式类名
35
+ * @param {React.CSSProperties} [props.style] - 自定义样式
36
+ * @param {string} [props.rootClassName] - 根节点样式类名
37
+ *
38
+ * @example
39
+ * ```tsx
40
+ * <WelcomeMessage
41
+ * title="欢迎使用 AI 助手"
42
+ * description="我可以帮助您解答问题、提供建议和完成任务"
43
+ * classNames={{
44
+ * title: 'custom-title',
45
+ * description: 'custom-description'
46
+ * }}
47
+ * />
48
+ * ```
49
+ *
50
+ * @returns {React.ReactElement} 渲染的欢迎消息组件
51
+ *
52
+ * @remarks
53
+ * - 支持自定义标题和描述
54
+ * - 提供灵活的样式配置
55
+ * - 支持 React.ReactNode 类型内容
56
+ * - 集成 Ant Design 主题系统
57
+ * - 响应式布局适配
58
+ */
59
+ export declare const WelcomeMessage: React.FC<WelcomeMessageProps>;
@@ -1,9 +1,9 @@
1
- // src/Welcome/index.tsx
1
+ // src/WelcomeMessage/index.tsx
2
2
  import { ConfigProvider } from "antd";
3
3
  import classnames from "classnames";
4
4
  import React, { useContext } from "react";
5
5
  import { useStyle } from "./style";
6
- var Welcome = ({
6
+ var WelcomeMessage = ({
7
7
  title,
8
8
  description,
9
9
  classNames,
@@ -11,7 +11,7 @@ var Welcome = ({
11
11
  rootClassName
12
12
  }) => {
13
13
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
14
- const prefixCls = getPrefixCls("welcome");
14
+ const prefixCls = getPrefixCls("agentic-welcome");
15
15
  const { wrapSSR, hashId } = useStyle(prefixCls);
16
16
  return wrapSSR(
17
17
  /* @__PURE__ */ React.createElement("div", { className: classnames(prefixCls, hashId, rootClassName), style }, title && /* @__PURE__ */ React.createElement("div", { className: classnames(`${prefixCls}-title`, classNames == null ? void 0 : classNames.title) }, title), description && /* @__PURE__ */ React.createElement(
@@ -27,5 +27,5 @@ var Welcome = ({
27
27
  );
28
28
  };
29
29
  export {
30
- Welcome
30
+ WelcomeMessage
31
31
  };
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
 
21
- // src/Welcome/style.ts
21
+ // src/WelcomeMessage/style.ts
22
22
  import {
23
23
  useEditorStyleRegister
24
24
  } from "../Hooks/useStyle";
@@ -224,7 +224,7 @@ var genStyle = (token) => {
224
224
  }
225
225
  },
226
226
  [`&--markdown`]: {
227
- '.ant-md-editor-content div[data-be="paragraph"]:last-child': {
227
+ '.ant-agentic-md-editor-content div[data-be="paragraph"]:last-child': {
228
228
  paddingBottom: "16px",
229
229
  color: "var(--color-gray-text-light)",
230
230
  font: "var(--font-text-code-base)",
@@ -20,7 +20,7 @@ var StatusIcon = ({ status }) => {
20
20
  };
21
21
  var TaskList = ({ data }) => {
22
22
  const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
23
- const prefixCls = getPrefixCls("workspace-task");
23
+ const prefixCls = getPrefixCls("agentic-workspace-task");
24
24
  const { wrapSSR, hashId } = useTaskStyle(prefixCls);
25
25
  return wrapSSR(
26
26
  /* @__PURE__ */ React.createElement("div", { className: classNames(prefixCls, hashId), "data-testid": "task-list" }, data.items.map((item) => /* @__PURE__ */ React.createElement(
package/dist/index.d.ts CHANGED
@@ -4,7 +4,7 @@ export * from './AgentRunBar';
4
4
  export * from './Bubble';
5
5
  export * from './Bubble/List';
6
6
  export * from './Bubble/type';
7
- export * from './ChatBoot';
7
+ export * from './ChatBootPage';
8
8
  export * from './ChatLayout';
9
9
  export * from './Components/ActionIconBox';
10
10
  export * from './Components/Button';
@@ -47,7 +47,7 @@ export * from './Schema';
47
47
  export * from './TaskList';
48
48
  export * from './ThoughtChainList';
49
49
  export * from './ToolUseBar';
50
- export * from './Welcome';
50
+ export * from './WelcomeMessage';
51
51
  export * from './Workspace';
52
52
  export * from './Components/Robot';
53
53
  export { default as Robot } from './Components/Robot';
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@ export * from "./AgentRunBar";
4
4
  export * from "./Bubble";
5
5
  export * from "./Bubble/List";
6
6
  export * from "./Bubble/type";
7
- export * from "./ChatBoot";
7
+ export * from "./ChatBootPage";
8
8
  export * from "./ChatLayout";
9
9
  export * from "./Components/ActionIconBox";
10
10
  export * from "./Components/Button";
@@ -47,7 +47,7 @@ export * from "./Schema";
47
47
  export * from "./TaskList";
48
48
  export * from "./ThoughtChainList";
49
49
  export * from "./ToolUseBar";
50
- export * from "./Welcome";
50
+ export * from "./WelcomeMessage";
51
51
  export * from "./Workspace";
52
52
  export * from "./Components/Robot";
53
53
  import { default as default3 } from "./Components/Robot";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ant-design/agentic-ui",
3
- "version": "2.0.13",
3
+ "version": "2.0.15",
4
4
  "description": "面向智能体的 UI 组件库,提供多步推理可视化、工具调用展示、任务执行协同等 Agentic UI 能力",
5
5
  "repository": "git@github.com:ant-design/agentic-ui.git",
6
6
  "license": "MIT",
@@ -1,14 +0,0 @@
1
- import React from 'react';
2
- export interface WelcomeProps {
3
- /** 标题 */
4
- title: React.ReactNode;
5
- /** 描述 */
6
- description?: React.ReactNode;
7
- /** 自定义样式类名,用于各个提示项的不同部分 */
8
- classNames?: Record<'title' | 'description', string>;
9
- /** 自定义样式 */
10
- style?: React.CSSProperties;
11
- /** 自定义根节点样式类名 */
12
- rootClassName?: string;
13
- }
14
- export declare const Welcome: React.FC<WelcomeProps>;
File without changes
File without changes
File without changes
File without changes
File without changes