@ant-design/agentic-ui 2.30.31 → 2.30.33

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 (51) hide show
  1. package/dist/AILabel/index.d.ts +2 -0
  2. package/dist/AILabel/index.js +4 -2
  3. package/dist/AgentRunBar/Robot.js +0 -1
  4. package/dist/AgentRunBar/index.js +1 -0
  5. package/dist/AgenticLayout/index.js +1 -0
  6. package/dist/AnswerAlert/index.js +1 -0
  7. package/dist/BackTo/ScrollVisibleButton.d.ts +2 -0
  8. package/dist/BackTo/ScrollVisibleButton.js +4 -2
  9. package/dist/Bubble/List/PureBubbleList.js +2 -0
  10. package/dist/Bubble/style.js +0 -1
  11. package/dist/ChatBootPage/ButtonTab.js +1 -0
  12. package/dist/ChatBootPage/ButtonTabGroup.js +1 -0
  13. package/dist/ChatBootPage/CaseReply.js +1 -0
  14. package/dist/ChatBootPage/Title.js +1 -0
  15. package/dist/ChatLayout/index.js +1 -0
  16. package/dist/Components/ActionItemBox/ActionItemBox.js +1 -0
  17. package/dist/Components/Button/IconButton/index.js +1 -0
  18. package/dist/Components/Button/SwitchButton/index.js +1 -0
  19. package/dist/Components/Button/ToggleButton/index.js +1 -0
  20. package/dist/Components/GradientText/index.js +1 -0
  21. package/dist/Components/LayoutHeader/index.js +2 -1
  22. package/dist/Components/Loading/Loading.js +2 -0
  23. package/dist/Components/Robot/index.js +1 -0
  24. package/dist/Components/SuggestionList/index.js +1 -0
  25. package/dist/Components/TextAnimate/index.js +1 -0
  26. package/dist/Components/TypingAnimation/index.js +2 -1
  27. package/dist/Components/VisualList/index.js +3 -0
  28. package/dist/Components/lotties/ThreeThinkingLottie/index.d.ts +68 -0
  29. package/dist/Components/lotties/ThreeThinkingLottie/index.js +151 -0
  30. package/dist/Components/lotties/ThreeThinkingLottie/three-thinking.json +130 -0
  31. package/dist/Components/lotties/index.d.ts +1 -0
  32. package/dist/Components/lotties/index.js +1 -0
  33. package/dist/History/index.js +1 -0
  34. package/dist/MarkdownEditor/BaseMarkdownEditor.js +2 -0
  35. package/dist/MarkdownRenderer/MarkdownRenderer.js +1 -0
  36. package/dist/Plugins/chart/components/ChartContainer/ChartContainer.d.ts +13 -3
  37. package/dist/Plugins/chart/components/ChartContainer/ChartContainer.js +19 -4
  38. package/dist/Plugins/chart/hooks/index.d.ts +2 -0
  39. package/dist/Plugins/chart/hooks/index.js +1 -0
  40. package/dist/Plugins/chart/hooks/useDetectTheme.d.ts +46 -0
  41. package/dist/Plugins/chart/hooks/useDetectTheme.js +222 -0
  42. package/dist/Schema/SchemaEditor/index.js +1 -0
  43. package/dist/Schema/SchemaForm/index.js +1 -0
  44. package/dist/TaskList/TaskList.js +21 -4
  45. package/dist/TaskList/components/TaskListItem.js +2 -1
  46. package/dist/TaskList/style.js +1 -1
  47. package/dist/ThoughtChainList/index.js +1 -0
  48. package/dist/ToolUseBar/index.js +7 -6
  49. package/dist/ToolUseBarThink/style.js +0 -7
  50. package/dist/WelcomeMessage/index.js +1 -0
  51. package/package.json +2 -2
@@ -35,7 +35,8 @@ export var TaskListItem = /*#__PURE__*/ memo(function(param) {
35
35
  className: classNames("".concat(prefixCls, "-dash-line"), hashId),
36
36
  "data-testid": "task-list-dash-line"
37
37
  }))), /*#__PURE__*/ React.createElement("div", {
38
- className: classNames("".concat(prefixCls, "-right"), hashId)
38
+ className: classNames("".concat(prefixCls, "-right"), hashId),
39
+ "data-testid": "task-list-right"
39
40
  }, /*#__PURE__*/ React.createElement("div", {
40
41
  className: classNames("".concat(prefixCls, "-top"), hashId),
41
42
  onClick: handleToggle
@@ -153,7 +153,7 @@ var genStyle = function genStyle(token) {
153
153
  display: 'flex',
154
154
  alignItems: 'center',
155
155
  height: 36,
156
- padding: '0 12px',
156
+ padding: '0 4px',
157
157
  gap: 8,
158
158
  cursor: 'pointer',
159
159
  userSelect: 'none',
@@ -486,6 +486,7 @@ var ThoughtChainContent = /*#__PURE__*/ React.memo(function(_0) {
486
486
  locale: locale
487
487
  }), /*#__PURE__*/ React.createElement("div", {
488
488
  className: classNames("".concat(prefixCls), hashId),
489
+ "data-testid": prefixCls,
489
490
  style: restStyle
490
491
  }, /*#__PURE__*/ React.createElement(motion.div, {
491
492
  className: classNames("".concat(prefixCls, "-container"), hashId, _define_property({}, "".concat(prefixCls, "-container-loading"), !(bubble === null || bubble === void 0 ? void 0 : bubble.isFinished)))
@@ -155,13 +155,14 @@ export * from "./BarItem";
155
155
  * - 提供加载状态显示
156
156
  * - 支持错误状态处理
157
157
  */ var ToolUseBarComponent = function ToolUseBarComponent(_0) {
158
- var tools = _0.tools, onActiveKeysChange = _0.onActiveKeysChange, onExpandedKeysChange = _0.onExpandedKeysChange, _0_light = _0.light, light = _0_light === void 0 ? false : _0_light, _0_disableAnimation = _0.disableAnimation, disableAnimation = _0_disableAnimation === void 0 ? false : _0_disableAnimation, style = _0.style, props = _object_without_properties(_0, [
158
+ var tools = _0.tools, onActiveKeysChange = _0.onActiveKeysChange, onExpandedKeysChange = _0.onExpandedKeysChange, _0_light = _0.light, light = _0_light === void 0 ? false : _0_light, _0_disableAnimation = _0.disableAnimation, disableAnimation = _0_disableAnimation === void 0 ? false : _0_disableAnimation, style = _0.style, testId = _0.testId, props = _object_without_properties(_0, [
159
159
  "tools",
160
160
  "onActiveKeysChange",
161
161
  "onExpandedKeysChange",
162
162
  "light",
163
163
  "disableAnimation",
164
- "style"
164
+ "style",
165
+ "testId"
165
166
  ]);
166
167
  var getPrefixCls = useContext(ConfigProvider.ConfigContext).getPrefixCls;
167
168
  var prefixCls = getPrefixCls('agentic-tool-use-bar');
@@ -246,13 +247,13 @@ export * from "./BarItem";
246
247
  ]);
247
248
  if (!(tools === null || tools === void 0 ? void 0 : tools.length)) return /*#__PURE__*/ React.createElement("div", {
248
249
  className: containerClassName,
249
- style: style,
250
- "data-testid": "ToolUse"
250
+ "data-testid": testId !== null && testId !== void 0 ? testId : 'ToolUse',
251
+ style: style
251
252
  });
252
253
  return wrapSSR(/*#__PURE__*/ React.createElement("div", {
253
254
  className: containerClassName,
254
- style: style,
255
- "data-testid": "ToolUse"
255
+ "data-testid": testId !== null && testId !== void 0 ? testId : 'ToolUse',
256
+ style: style
256
257
  }, toolItems));
257
258
  };
258
259
  // 使用 memo 优化组件,避免不必要的重新渲染
@@ -51,7 +51,6 @@ function _object_spread_props(target, source) {
51
51
  return target;
52
52
  }
53
53
  import { useEditorStyleRegister } from "../Hooks/useStyle";
54
- var LIGHT_MODE_BACKGROUND = 'rgba(255, 255, 255, 0.65)';
55
54
  var LIGHT_MODE_BACKDROP_FILTER = 'blur(12px)';
56
55
  var genStyle = function genStyle(token) {
57
56
  return _define_property({}, token.componentCls, {
@@ -111,18 +110,15 @@ var genStyle = function genStyle(token) {
111
110
  }
112
111
  },
113
112
  '&-loading': {
114
- background: 'var(--color-gray-bg-card-white)',
115
113
  boxSizing: 'border-box',
116
114
  boxShadow: '0px 0px 1px 0px rgba(0, 19, 41, 0.05),0px 2px 7px 0px rgba(0, 19, 41, 0.05),0px 2px 5px -2px rgba(0, 19, 41, 0.06)',
117
115
  '&:hover': {
118
- background: 'var(--color-gray-bg-card-white)',
119
116
  boxSizing: 'border-box',
120
117
  boxShadow: '0px 0px 1px 0px rgba(0, 19, 41, 0.05),0px 2px 7px 0px rgba(0, 19, 41, 0.05),0px 2px 5px -2px rgba(0, 19, 41, 0.06)'
121
118
  }
122
119
  },
123
120
  '&-success': {
124
121
  borderRadius: 'var(--radius-card-base)',
125
- background: 'var(--color-gray-bg-card-light)',
126
122
  boxShadow: 'inset 0px 0px 1px 0px rgba(0, 19, 41, 0.15)'
127
123
  },
128
124
  // Placed after &-success so light mode wins when both classes apply (success + light).
@@ -131,11 +127,9 @@ var genStyle = function genStyle(token) {
131
127
  border: 'none',
132
128
  borderRadius: '14px',
133
129
  padding: 4,
134
- background: LIGHT_MODE_BACKGROUND,
135
130
  backdropFilter: LIGHT_MODE_BACKDROP_FILTER,
136
131
  WebkitBackdropFilter: LIGHT_MODE_BACKDROP_FILTER,
137
132
  '&:hover': _define_property({
138
- background: 'none',
139
133
  boxShadow: 'none'
140
134
  }, "".concat(token.componentCls, "-header-left-icon-light"), {
141
135
  color: 'var(--color-gray-text-secondary)'
@@ -267,7 +261,6 @@ var genStyle = function genStyle(token) {
267
261
  paddingLeft: 12,
268
262
  marginLeft: 16,
269
263
  marginTop: -10,
270
- background: LIGHT_MODE_BACKGROUND,
271
264
  backdropFilter: LIGHT_MODE_BACKDROP_FILTER,
272
265
  WebkitBackdropFilter: LIGHT_MODE_BACKDROP_FILTER
273
266
  }
@@ -121,6 +121,7 @@ import { useStyle } from "./style";
121
121
  var _ref = customStyle || {}, ref = _object_destructuring_empty(_ref), restStyle = _extends({}, _ref);
122
122
  return wrapSSR(/*#__PURE__*/ React.createElement("div", {
123
123
  className: clsx(prefixCls, hashId, rootClassName),
124
+ "data-testid": prefixCls,
124
125
  style: restStyle
125
126
  }, title && /*#__PURE__*/ React.createElement(TypingAnimation, _object_spread_props(_object_spread({
126
127
  as: "div"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ant-design/agentic-ui",
3
- "version": "2.30.31",
3
+ "version": "2.30.33",
4
4
  "description": "面向智能体的 UI 组件库,提供多步推理可视化、工具调用展示、任务执行协同等 Agentic UI 能力",
5
5
  "repository": "git@github.com:ant-design/agentic-ui.git",
6
6
  "license": "MIT",
@@ -25,7 +25,7 @@
25
25
  "lint:es": "eslint \"{src,test}/**/*.{js,jsx,ts,tsx}\"",
26
26
  "playwright:install": "playwright install --with-deps chromium",
27
27
  "prepare": "husky install && dumi setup",
28
- "prepublishOnly": "npm run build",
28
+ "prepublishOnly": "npm run build && npm run test",
29
29
  "prettier": "prettier --write \"{src,docs,test}/**/*.{js,jsx,ts,tsx,css,less,json,md}\"",
30
30
  "preview": "pnpm dumi preview",
31
31
  "report:demo": "node scripts/generateDemoReport.js",