@agentscope-ai/design 1.0.19-beta.1765957449539 → 1.0.20-beta.1766645674012

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/llms/all.llms.txt CHANGED
@@ -1,5 +1,18 @@
1
1
 
2
2
 
3
+ <DemoTitle title="Video" desc="视频展示">
4
+ #### API
5
+
6
+ | 属性名 | 描述 | 类型 | 默认值 |
7
+ |--------|--------|--------|--------|
8
+ | mouseEnterAutoPlay | 鼠标进入时是否自动播放 | boolean | false |
9
+ | children | video内部设置了按钮在暗色背景下的样式,如果有一些操作按钮想继承这个样式可以在这里传入 | React.ReactNode | |
10
+
11
+
12
+
13
+
14
+
15
+
3
16
  <DemoTitle title="Upload" desc="文件选择上传和拖拽上传控件。">
4
17
  #### API
5
18
 
@@ -143,6 +156,41 @@
143
156
 
144
157
 
145
158
 
159
+ <DemoTitle title="Tag" desc="进行标记和分类的小标签">
160
+ #### API
161
+
162
+ | 属性名 | 描述 | 类型 | 默认值 |
163
+ |--------|--------|--------|--------|
164
+ | size | 尺寸 | 'small' \| 'middle' | 'middle' |
165
+ | color | 标签色 | SparkTagColors \| string | 'purple' |
166
+
167
+ <AntdApiRef url="https://ant.design/components/tag-cn/#api"></AntdApiRef>
168
+
169
+
170
+ ## antd API
171
+
172
+ 通用属性参考:[通用属性](/docs/react/common-props)
173
+
174
+ ### Tag
175
+
176
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
177
+ |--------|--------|--------|--------|--------|
178
+ | closeIcon | 自定义关闭按钮。5.7.0:设置为 | ReactNode | false | 4.4.0 |
179
+ | icon | 设置图标 | ReactNode | - | |
180
+ | bordered | 是否有边框 | boolean | true | 5.4.0 |
181
+ | onClose | 关闭时的回调(可通过 | (e: React.MouseEvent) => void | - | |
182
+
183
+
184
+ ### Tag.CheckableTag
185
+
186
+ | 参数 | 说明 | 类型 | 默认值 |
187
+ |--------|--------|--------|--------|
188
+ | checked | 设置标签的选中状态 | boolean | false |
189
+ | onChange | 点击标签时触发的回调 | (checked) => void | - |
190
+
191
+
192
+
193
+
146
194
  <DemoTitle title="TimePicker" desc="输入或选择时间的控件。">
147
195
  #### API
148
196
 
@@ -256,54 +304,6 @@ type RangeDisabledTime = (
256
304
 
257
305
 
258
306
 
259
- <DemoTitle title="Tag" desc="进行标记和分类的小标签">
260
- #### API
261
-
262
- | 属性名 | 描述 | 类型 | 默认值 |
263
- |--------|--------|--------|--------|
264
- | size | 尺寸 | 'small' \| 'middle' | 'middle' |
265
- | color | 标签色 | SparkTagColors \| string | 'purple' |
266
-
267
- <AntdApiRef url="https://ant.design/components/tag-cn/#api"></AntdApiRef>
268
-
269
-
270
- ## antd API
271
-
272
- 通用属性参考:[通用属性](/docs/react/common-props)
273
-
274
- ### Tag
275
-
276
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
277
- |--------|--------|--------|--------|--------|
278
- | closeIcon | 自定义关闭按钮。5.7.0:设置为 | ReactNode | false | 4.4.0 |
279
- | icon | 设置图标 | ReactNode | - | |
280
- | bordered | 是否有边框 | boolean | true | 5.4.0 |
281
- | onClose | 关闭时的回调(可通过 | (e: React.MouseEvent) => void | - | |
282
-
283
-
284
- ### Tag.CheckableTag
285
-
286
- | 参数 | 说明 | 类型 | 默认值 |
287
- |--------|--------|--------|--------|
288
- | checked | 设置标签的选中状态 | boolean | false |
289
- | onChange | 点击标签时触发的回调 | (checked) => void | - |
290
-
291
-
292
-
293
-
294
- <DemoTitle title="Video" desc="视频展示">
295
- #### API
296
-
297
- | 属性名 | 描述 | 类型 | 默认值 |
298
- |--------|--------|--------|--------|
299
- | mouseEnterAutoPlay | 鼠标进入时是否自动播放 | boolean | false |
300
- | children | video内部设置了按钮在暗色背景下的样式,如果有一些操作按钮想继承这个样式可以在这里传入 | React.ReactNode | |
301
-
302
-
303
-
304
-
305
-
306
-
307
307
  <DemoTitle title="Tabs" desc="用户可以通过点击不同的标签在同一页面中查看不同的内容区域。">
308
308
  #### API
309
309
 
@@ -374,6 +374,47 @@ type RangeDisabledTime = (
374
374
 
375
375
 
376
376
 
377
+ <DemoTitle title="Switch" desc="使用开关切换两种状态之间。">
378
+ #### API
379
+
380
+ | 属性名 | 描述 | 类型 | 默认值 |
381
+ |--------|--------|--------|--------|
382
+ | label | Switch后的内容 | ReactNode | |
383
+
384
+ <AntdApiRef url="https://ant.design/components/switch-cn/#api"></AntdApiRef>
385
+
386
+
387
+ ## antd API
388
+
389
+ 通用属性参考:[通用属性](/docs/react/common-props)
390
+
391
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
392
+ |--------|--------|--------|--------|--------|
393
+ | autoFocus | 组件自动获取焦点 | boolean | false | |
394
+ | checked | 指定当前是否选中 | boolean | false | |
395
+ | checkedChildren | 选中时的内容 | ReactNode | - | |
396
+ | className | Switch 器类名 | string | - | |
397
+ | defaultChecked | 初始是否选中 | boolean | false | |
398
+ | defaultValue | defaultChecked | boolean | - | 5.12.0 |
399
+ | disabled | 是否禁用 | boolean | false | |
400
+ | loading | 加载中的开关 | boolean | false | |
401
+ | size | 开关大小,可选值: | string | default | |
402
+ | unCheckedChildren | 非选中时的内容 | ReactNode | - | |
403
+ | value | checked | boolean | - | 5.12.0 |
404
+ | onChange | 变化时的回调函数 | function(checked: boolean, event: Event) | - | |
405
+ | onClick | 点击时的回调函数 | function(checked: boolean, event: Event) | - | |
406
+
407
+
408
+ ## 方法
409
+
410
+ | 名称 | 描述 |
411
+ |--------|--------|
412
+ | blur() | 移除焦点 |
413
+ | focus() | 获取焦点 |
414
+
415
+
416
+
417
+
377
418
  <DemoTitle title="Table" desc="展示行列数据。">
378
419
  #### API
379
420
 
@@ -629,47 +670,6 @@ TypeScript 里使用 Table 的 [CodeSandbox 实例](https://codesandbox.io/s/ser
629
670
 
630
671
 
631
672
 
632
- <DemoTitle title="Switch" desc="使用开关切换两种状态之间。">
633
- #### API
634
-
635
- | 属性名 | 描述 | 类型 | 默认值 |
636
- |--------|--------|--------|--------|
637
- | label | Switch后的内容 | ReactNode | |
638
-
639
- <AntdApiRef url="https://ant.design/components/switch-cn/#api"></AntdApiRef>
640
-
641
-
642
- ## antd API
643
-
644
- 通用属性参考:[通用属性](/docs/react/common-props)
645
-
646
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
647
- |--------|--------|--------|--------|--------|
648
- | autoFocus | 组件自动获取焦点 | boolean | false | |
649
- | checked | 指定当前是否选中 | boolean | false | |
650
- | checkedChildren | 选中时的内容 | ReactNode | - | |
651
- | className | Switch 器类名 | string | - | |
652
- | defaultChecked | 初始是否选中 | boolean | false | |
653
- | defaultValue | defaultChecked | boolean | - | 5.12.0 |
654
- | disabled | 是否禁用 | boolean | false | |
655
- | loading | 加载中的开关 | boolean | false | |
656
- | size | 开关大小,可选值: | string | default | |
657
- | unCheckedChildren | 非选中时的内容 | ReactNode | - | |
658
- | value | checked | boolean | - | 5.12.0 |
659
- | onChange | 变化时的回调函数 | function(checked: boolean, event: Event) | - | |
660
- | onClick | 点击时的回调函数 | function(checked: boolean, event: Event) | - | |
661
-
662
-
663
- ## 方法
664
-
665
- | 名称 | 描述 |
666
- |--------|--------|
667
- | blur() | 移除焦点 |
668
- | focus() | 获取焦点 |
669
-
670
-
671
-
672
-
673
673
  <DemoTitle title="Steps" desc="引导用户按照流程完成任务的导航条。">
674
674
  #### API
675
675
 
@@ -1253,15 +1253,10 @@ TypeScript 里使用 Table 的 [CodeSandbox 实例](https://codesandbox.io/s/ser
1253
1253
 
1254
1254
 
1255
1255
 
1256
- <DemoTitle title="Popconfirm" desc="点击元素,弹出气泡式的确认框。">
1256
+ <DemoTitle title="Popover" desc="点击/鼠标移入元素,弹出气泡式的卡片浮层">
1257
1257
  #### API
1258
1258
 
1259
- | 属性名 | 描述 | 类型 | 默认值 |
1260
- |--------|--------|--------|--------|
1261
- | type | 类型 | 'info' \| 'warning' \| 'error' \| 'success' \| 'confirm' | 'confirm' |
1262
-
1263
-
1264
- <AntdApiRef url="https://ant.design/components/popconfirm-cn/#api"></AntdApiRef>
1259
+ <AntdApiRef url="https://ant.design/components/popover-cn/#api"></AntdApiRef>
1265
1260
 
1266
1261
 
1267
1262
  ## antd API
@@ -1270,19 +1265,8 @@ TypeScript 里使用 Table 的 [CodeSandbox 实例](https://codesandbox.io/s/ser
1270
1265
 
1271
1266
  | 参数 | 说明 | 类型 | 默认值 | 版本 |
1272
1267
  |--------|--------|--------|--------|--------|
1273
- | cancelButtonProps | cancel 按钮 props | | - | |
1274
- | cancelText | 取消按钮文字 | string | 取消 | |
1275
- | disabled | 阻止点击 Popconfirm 子元素时弹出确认框 | boolean | false | |
1276
- | icon | 自定义弹出气泡 Icon 图标 | ReactNode | | |
1277
- | okButtonProps | ok 按钮 props | | - | |
1278
- | okText | 确认按钮文字 | string | 确定 | |
1279
- | okType | 确认按钮类型 | string | primary | |
1280
- | showCancel | 是否显示取消按钮 | boolean | true | 4.18.0 |
1281
- | title | 确认框标题 | ReactNode \| () => ReactNode | - | |
1282
- | description | 确认内容的详细描述 | ReactNode \| () => ReactNode | - | 5.1.0 |
1283
- | onCancel | 点击取消的回调 | function(e) | - | |
1284
- | onConfirm | 点击确认的回调 | function(e) | - | |
1285
- | onPopupClick | 弹出气泡点击事件 | function(e) | - | 5.5.0 |
1268
+ | content | 卡片内容 | ReactNode \| () => ReactNode | - | |
1269
+ | title | 卡片标题 | ReactNode \| () => ReactNode | - | |
1286
1270
 
1287
1271
 
1288
1272
  <!-- 共同的 API -->
@@ -1307,13 +1291,21 @@ TypeScript 里使用 Table 的 [CodeSandbox 实例](https://codesandbox.io/s/ser
1307
1291
  | zIndex | 设置 Tooltip 的 | number | - | |
1308
1292
  | onOpenChange | 显示隐藏的回调 | (open: boolean) => void | - | 4.23.0 |
1309
1293
 
1294
+ ## 注意
1295
+
1296
+ 请确保 `Popover` 的子元素能接受 `onMouseEnter`、`onMouseLeave`、`onFocus`、`onClick` 事件。
1310
1297
 
1311
1298
 
1312
1299
 
1313
- <DemoTitle title="Popover" desc="点击/鼠标移入元素,弹出气泡式的卡片浮层">
1300
+ <DemoTitle title="Popconfirm" desc="点击元素,弹出气泡式的确认框。">
1314
1301
  #### API
1315
1302
 
1316
- <AntdApiRef url="https://ant.design/components/popover-cn/#api"></AntdApiRef>
1303
+ | 属性名 | 描述 | 类型 | 默认值 |
1304
+ |--------|--------|--------|--------|
1305
+ | type | 类型 | 'info' \| 'warning' \| 'error' \| 'success' \| 'confirm' | 'confirm' |
1306
+
1307
+
1308
+ <AntdApiRef url="https://ant.design/components/popconfirm-cn/#api"></AntdApiRef>
1317
1309
 
1318
1310
 
1319
1311
  ## antd API
@@ -1322,8 +1314,19 @@ TypeScript 里使用 Table 的 [CodeSandbox 实例](https://codesandbox.io/s/ser
1322
1314
 
1323
1315
  | 参数 | 说明 | 类型 | 默认值 | 版本 |
1324
1316
  |--------|--------|--------|--------|--------|
1325
- | content | 卡片内容 | ReactNode \| () => ReactNode | - | |
1326
- | title | 卡片标题 | ReactNode \| () => ReactNode | - | |
1317
+ | cancelButtonProps | cancel 按钮 props | | - | |
1318
+ | cancelText | 取消按钮文字 | string | 取消 | |
1319
+ | disabled | 阻止点击 Popconfirm 子元素时弹出确认框 | boolean | false | |
1320
+ | icon | 自定义弹出气泡 Icon 图标 | ReactNode | | |
1321
+ | okButtonProps | ok 按钮 props | | - | |
1322
+ | okText | 确认按钮文字 | string | 确定 | |
1323
+ | okType | 确认按钮类型 | string | primary | |
1324
+ | showCancel | 是否显示取消按钮 | boolean | true | 4.18.0 |
1325
+ | title | 确认框标题 | ReactNode \| () => ReactNode | - | |
1326
+ | description | 确认内容的详细描述 | ReactNode \| () => ReactNode | - | 5.1.0 |
1327
+ | onCancel | 点击取消的回调 | function(e) | - | |
1328
+ | onConfirm | 点击确认的回调 | function(e) | - | |
1329
+ | onPopupClick | 弹出气泡点击事件 | function(e) | - | 5.5.0 |
1327
1330
 
1328
1331
 
1329
1332
  <!-- 共同的 API -->
@@ -1348,9 +1351,6 @@ TypeScript 里使用 Table 的 [CodeSandbox 实例](https://codesandbox.io/s/ser
1348
1351
  | zIndex | 设置 Tooltip 的 | number | - | |
1349
1352
  | onOpenChange | 显示隐藏的回调 | (open: boolean) => void | - | 4.23.0 |
1350
1353
 
1351
- ## 注意
1352
-
1353
- 请确保 `Popover` 的子元素能接受 `onMouseEnter`、`onMouseLeave`、`onFocus`、`onClick` 事件。
1354
1354
 
1355
1355
 
1356
1356
 
@@ -2168,36 +2168,89 @@ type PresetColors = 'blue' | 'purple' | 'cyan' | 'green' | 'magenta' | 'pink' |
2168
2168
 
2169
2169
 
2170
2170
 
2171
- <DemoTitle title="Form" desc="高性能表单控件,自带数据域管理。包含数据录入、校验以及对应样式。">
2171
+ <DemoTitle title="FloatButton" desc="用于网站上的全局功能;无论浏览到何处都可以看见的按钮。">
2172
2172
  #### API
2173
2173
 
2174
- <AntdApiRef url="https://ant.design/components/form-cn/#api"></AntdApiRef>
2174
+ <AntdApiRef url="https://ant.design/components/float-button-cn/#api"></AntdApiRef>
2175
2175
 
2176
2176
 
2177
2177
  ## antd API
2178
2178
 
2179
2179
  通用属性参考:[通用属性](/docs/react/common-props)
2180
2180
 
2181
- ### Form
2181
+ `antd@5.0.0` 版本开始提供该组件。
2182
+
2183
+ ### 共同的 API
2182
2184
 
2183
2185
  | 参数 | 说明 | 类型 | 默认值 | 版本 |
2184
2186
  |--------|--------|--------|--------|--------|
2185
- | colon | 配置 Form.Item 的 | boolean | true | |
2186
- | disabled | 设置表单组件禁用,仅对 antd 组件有效 | boolean | false | 4.21.0 |
2187
- | component | 设置 Form 渲染元素,为 | ComponentType \| false | form | |
2188
- | fields | 通过状态管理(如 redux)控制表单字段,如非强需求不推荐使用。查看 | | - | |
2189
- | form | | | - | |
2190
- | feedbackIcons | | | - | 5.9.0 |
2191
- | initialValues | 表单默认值,只有初始化以及重置时生效 | object | - | |
2192
- | labelAlign | label 标签的文本对齐方式 | left | right | |
2193
- | labelWrap | label 标签的文本换行方式 | boolean | false | 4.18.0 |
2194
- | labelCol | label 标签布局,同 | | - | |
2195
- | layout | 表单布局 | horizontal | horizontal | |
2196
- | name | 表单名称,会作为表单字段 | string | - | |
2197
- | preserve | 当字段被删除时保留字段值。你可以通过 | boolean | true | 4.4.0 |
2198
- | requiredMark | 必选样式,可以切换为必选或者可选展示样式。此为 Form 配置,Form.Item 无法单独配置 | boolean \| | true | renderProps |
2199
- | scrollToFirstError | 提交失败自动滚动到第一个错误字段 | boolean \| | false | focus: 5.24.0 |
2200
- | size | 设置字段组件的尺寸(仅限 antd 组件) | small | - | |
2187
+ | icon | 自定义图标 | ReactNode | - | |
2188
+ | description | 文字及其它内容 | ReactNode | - | |
2189
+ | tooltip | 气泡卡片的内容 | ReactNode \| | - | TooltipProps: 5.25.0 |
2190
+ | type | 设置按钮类型 | default | default | |
2191
+ | shape | 设置按钮形状 | circle | circle | |
2192
+ | onClick | 点击按钮时的回调 | (event) => void | - | |
2193
+ | href | 点击跳转的地址,指定此属性 button 的行为和 a 链接一致 | string | - | |
2194
+ | target | 相当于 a 标签的 target 属性,href 存在时生效 | string | - | |
2195
+ | htmlType | 设置 | submit | button | 5.21.0 |
2196
+ | badge | 带徽标数字的悬浮按钮(不支持 | | - | 5.4.0 |
2197
+
2198
+
2199
+ ### FloatButton.Group
2200
+
2201
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
2202
+ |--------|--------|--------|--------|--------|
2203
+ | shape | 设置包含的 FloatButton 按钮形状 | circle | circle | |
2204
+ | trigger | 触发方式(有触发方式为菜单模式) | click | - | |
2205
+ | open | 受控展开,需配合 trigger 一起使用 | boolean | - | |
2206
+ | closeIcon | 自定义关闭按钮 | React.ReactNode | | |
2207
+ | placement | 自定义菜单弹出位置 | top | top | 5.21.0 |
2208
+ | onOpenChange | 展开收起时的回调,需配合 trigger 一起使用 | (open: boolean) => void | - | |
2209
+ | onClick | 点击按钮时的回调(仅在菜单模式中有效) | (event) => void | - | 5.3.0 |
2210
+
2211
+
2212
+ ### FloatButton.BackTop
2213
+
2214
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
2215
+ |--------|--------|--------|--------|--------|
2216
+ | duration | 回到顶部所需时间(ms) | number | 450 | |
2217
+ | target | 设置需要监听其滚动事件的元素 | () => HTMLElement | () => window | |
2218
+ | visibilityHeight | 滚动高度达到此参数值才出现 BackTop | number | 400 | |
2219
+ | onClick | 点击按钮的回调函数 | () => void | - | |
2220
+
2221
+
2222
+
2223
+
2224
+ <DemoTitle title="Form" desc="高性能表单控件,自带数据域管理。包含数据录入、校验以及对应样式。">
2225
+ #### API
2226
+
2227
+ <AntdApiRef url="https://ant.design/components/form-cn/#api"></AntdApiRef>
2228
+
2229
+
2230
+ ## antd API
2231
+
2232
+ 通用属性参考:[通用属性](/docs/react/common-props)
2233
+
2234
+ ### Form
2235
+
2236
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
2237
+ |--------|--------|--------|--------|--------|
2238
+ | colon | 配置 Form.Item 的 | boolean | true | |
2239
+ | disabled | 设置表单组件禁用,仅对 antd 组件有效 | boolean | false | 4.21.0 |
2240
+ | component | 设置 Form 渲染元素,为 | ComponentType \| false | form | |
2241
+ | fields | 通过状态管理(如 redux)控制表单字段,如非强需求不推荐使用。查看 | | - | |
2242
+ | form | 经 | | - | |
2243
+ | feedbackIcons | 当 | | - | 5.9.0 |
2244
+ | initialValues | 表单默认值,只有初始化以及重置时生效 | object | - | |
2245
+ | labelAlign | label 标签的文本对齐方式 | left | right | |
2246
+ | labelWrap | label 标签的文本换行方式 | boolean | false | 4.18.0 |
2247
+ | labelCol | label 标签布局,同 | | - | |
2248
+ | layout | 表单布局 | horizontal | horizontal | |
2249
+ | name | 表单名称,会作为表单字段 | string | - | |
2250
+ | preserve | 当字段被删除时保留字段值。你可以通过 | boolean | true | 4.4.0 |
2251
+ | requiredMark | 必选样式,可以切换为必选或者可选展示样式。此为 Form 配置,Form.Item 无法单独配置 | boolean \| | true | renderProps |
2252
+ | scrollToFirstError | 提交失败自动滚动到第一个错误字段 | boolean \| | false | focus: 5.24.0 |
2253
+ | size | 设置字段组件的尺寸(仅限 antd 组件) | small | - | |
2201
2254
  | validateMessages | 验证提示模板,说明 | | - | |
2202
2255
  | validateTrigger | 统一设置字段触发验证的时机 | string \| string[] | onChange | 4.3.0 |
2203
2256
  | variant | 表单内控件变体 | outlined | outlined | 5.13.0 \| |
@@ -2728,102 +2781,6 @@ type Rule = RuleConfig | ((form: FormInstance) => RuleConfig);
2728
2781
 
2729
2782
 
2730
2783
 
2731
- <DemoTitle title="FloatButton" desc="用于网站上的全局功能;无论浏览到何处都可以看见的按钮。">
2732
- #### API
2733
-
2734
- <AntdApiRef url="https://ant.design/components/float-button-cn/#api"></AntdApiRef>
2735
-
2736
-
2737
- ## antd API
2738
-
2739
- 通用属性参考:[通用属性](/docs/react/common-props)
2740
-
2741
- 自 `antd@5.0.0` 版本开始提供该组件。
2742
-
2743
- ### 共同的 API
2744
-
2745
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
2746
- |--------|--------|--------|--------|--------|
2747
- | icon | 自定义图标 | ReactNode | - | |
2748
- | description | 文字及其它内容 | ReactNode | - | |
2749
- | tooltip | 气泡卡片的内容 | ReactNode \| | - | TooltipProps: 5.25.0 |
2750
- | type | 设置按钮类型 | default | default | |
2751
- | shape | 设置按钮形状 | circle | circle | |
2752
- | onClick | 点击按钮时的回调 | (event) => void | - | |
2753
- | href | 点击跳转的地址,指定此属性 button 的行为和 a 链接一致 | string | - | |
2754
- | target | 相当于 a 标签的 target 属性,href 存在时生效 | string | - | |
2755
- | htmlType | 设置 | submit | button | 5.21.0 |
2756
- | badge | 带徽标数字的悬浮按钮(不支持 | | - | 5.4.0 |
2757
-
2758
-
2759
- ### FloatButton.Group
2760
-
2761
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
2762
- |--------|--------|--------|--------|--------|
2763
- | shape | 设置包含的 FloatButton 按钮形状 | circle | circle | |
2764
- | trigger | 触发方式(有触发方式为菜单模式) | click | - | |
2765
- | open | 受控展开,需配合 trigger 一起使用 | boolean | - | |
2766
- | closeIcon | 自定义关闭按钮 | React.ReactNode | | |
2767
- | placement | 自定义菜单弹出位置 | top | top | 5.21.0 |
2768
- | onOpenChange | 展开收起时的回调,需配合 trigger 一起使用 | (open: boolean) => void | - | |
2769
- | onClick | 点击按钮时的回调(仅在菜单模式中有效) | (event) => void | - | 5.3.0 |
2770
-
2771
-
2772
- ### FloatButton.BackTop
2773
-
2774
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
2775
- |--------|--------|--------|--------|--------|
2776
- | duration | 回到顶部所需时间(ms) | number | 450 | |
2777
- | target | 设置需要监听其滚动事件的元素 | () => HTMLElement | () => window | |
2778
- | visibilityHeight | 滚动高度达到此参数值才出现 BackTop | number | 400 | |
2779
- | onClick | 点击按钮的回调函数 | () => void | - | |
2780
-
2781
-
2782
-
2783
-
2784
- <DemoTitle title="Empty" desc="用于空状态的占位图形展示。">
2785
- ## API
2786
-
2787
- | 属性名 | 描述 | 类型 | 默认值 |
2788
- |--------|--------|--------|--------|
2789
- | type | 空状态类型 | \| 'noData'
2790
- \| 'networkError'
2791
- \| '404'
2792
- \| 'arrears'
2793
- \| 'desktopOnly'
2794
- \| 'noAudio'
2795
- \| 'noImage'
2796
- \| 'noVideo'
2797
- \| 'noAccess'
2798
- \| 'error'
2799
- \| 'noModel'
2800
- \| 'noApp'
2801
- \| 'success'
2802
- \| 'failed'
2803
- \| 'inProgress'
2804
- \| 'stayTuned' | 'noData' |
2805
- | texture | 是否显示纹理 | boolean | true |
2806
- | image | 图片地址 | string | 默认是no data的图片 |
2807
- | imageStyle | 图片样式 | React.CSSProperties | |
2808
- | title | 标题内容 | React.ReactNode | |
2809
- | description | 自定义描述内容 | React.ReactNode | |
2810
- | onOk | ok按钮的点击事件 | (e: React.MouseEvent) => void | |
2811
- | okText | ok按钮的文本 | React.ReactNode | |
2812
- | okType | ok按钮的类型 | SparkButtonProps['type'] | 'primary' |
2813
- | okButtonProps | ok按钮的props | SparkButtonProps | |
2814
- | children | 自定义空状态的内容 | React.ReactNode | |
2815
- | className | 自定义空状态的类名 | string | |
2816
- | style | 自定义空状态的样式 | React.CSSProperties | |
2817
- | size | 自定义空状态的大小 | React.CSSProperties['width'] | |
2818
- | autoFit | 是否自适应容器宽度,当容器宽度小于 size 时自动缩放 | boolean | false |
2819
-
2820
-
2821
- <AntdApiRef url="https://ant.design/components/empty-cn/#api"></AntdApiRef>
2822
-
2823
-
2824
-
2825
-
2826
-
2827
2784
  <DemoTitle title="Dropdown" desc="向下弹出的列表。">
2828
2785
  #### API
2829
2786
 
@@ -2975,6 +2932,49 @@ const dividerItem = {
2975
2932
 
2976
2933
 
2977
2934
 
2935
+ <DemoTitle title="Empty" desc="用于空状态的占位图形展示。">
2936
+ ## API
2937
+
2938
+ | 属性名 | 描述 | 类型 | 默认值 |
2939
+ |--------|--------|--------|--------|
2940
+ | type | 空状态类型 | \| 'noData'
2941
+ \| 'networkError'
2942
+ \| '404'
2943
+ \| 'arrears'
2944
+ \| 'desktopOnly'
2945
+ \| 'noAudio'
2946
+ \| 'noImage'
2947
+ \| 'noVideo'
2948
+ \| 'noAccess'
2949
+ \| 'error'
2950
+ \| 'noModel'
2951
+ \| 'noApp'
2952
+ \| 'success'
2953
+ \| 'failed'
2954
+ \| 'inProgress'
2955
+ \| 'stayTuned' | 'noData' |
2956
+ | texture | 是否显示纹理 | boolean | true |
2957
+ | image | 图片地址 | string | 默认是no data的图片 |
2958
+ | imageStyle | 图片样式 | React.CSSProperties | |
2959
+ | title | 标题内容 | React.ReactNode | |
2960
+ | description | 自定义描述内容 | React.ReactNode | |
2961
+ | onOk | ok按钮的点击事件 | (e: React.MouseEvent) => void | |
2962
+ | okText | ok按钮的文本 | React.ReactNode | |
2963
+ | okType | ok按钮的类型 | SparkButtonProps['type'] | 'primary' |
2964
+ | okButtonProps | ok按钮的props | SparkButtonProps | |
2965
+ | children | 自定义空状态的内容 | React.ReactNode | |
2966
+ | className | 自定义空状态的类名 | string | |
2967
+ | style | 自定义空状态的样式 | React.CSSProperties | |
2968
+ | size | 自定义空状态的大小 | React.CSSProperties['width'] | |
2969
+ | autoFit | 是否自适应容器宽度,当容器宽度小于 size 时自动缩放 | boolean | false |
2970
+
2971
+
2972
+ <AntdApiRef url="https://ant.design/components/empty-cn/#api"></AntdApiRef>
2973
+
2974
+
2975
+
2976
+
2977
+
2978
2978
  <DemoTitle title="Drawer" desc="从页面一侧滑入的操作面板,用于承载临时界面内容。">
2979
2979
  #### API
2980
2980
 
@@ -3077,98 +3077,27 @@ span 是 Description.Item 的数量。 span={2} 会占用两个 DescriptionItem
3077
3077
 
3078
3078
 
3079
3079
 
3080
- <DemoTitle title="CollapsePanel" desc="折叠面板">
3080
+ <DemoTitle title="DatePicker" desc="输入或选择时间的控件。">
3081
3081
  #### API
3082
3082
 
3083
- | 属性名 | 描述 | 类型 | 默认值 |
3084
- |--------|--------|--------|--------|
3085
- | collapsedHeight | 收起状态下显示的内容高度 | number | 0 |
3086
- | expandedHeight | 展开状态下的内容高度,设置后内容超出时可滚动,不设置则自适应内容高度 | number | 300 |
3087
- | title | 面板标题 | string \| React.ReactNode | "" |
3088
- | expandOnPanelClick | 是否允许点击整个面板进行展开 | boolean | false |
3089
- | extra | 面板右侧内容 | React.ReactNode | |
3090
- | children | 面板内容 | React.ReactNode | |
3091
- | defaultExpanded | 是否默认展开 | boolean | false |
3092
- | classNames | 语义化的classNames | Partial> | |
3093
- | styles | 语义化的styles | Partial<
3094
- Record
3095
- > | |
3096
-
3083
+ <AntdApiRef url="https://ant.design/components/date-picker-cn/#api"></AntdApiRef>
3097
3084
 
3098
3085
 
3099
3086
  ## antd API
3100
3087
 
3101
3088
  通用属性参考:[通用属性](/docs/react/common-props)
3102
3089
 
3103
- ### Collapse
3090
+ 日期类组件包括以下五种形式。
3104
3091
 
3105
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3106
- |--------|--------|--------|--------|--------|
3107
- | accordion | 手风琴模式 | boolean | false | |
3108
- | activeKey | 当前激活 tab 面板的 key | string[] \| string | | |
3109
- | bordered | 带边框风格的折叠面板 | boolean | true | |
3110
- | collapsible | 所有子面板是否可折叠或指定可折叠触发区域 | header | - | 4.9.0 |
3111
- | defaultActiveKey | 初始化选中面板的 key | string[] \| string | - | |
3112
- | destroyOnHidden | 销毁折叠隐藏的面板 | boolean | false | 5.25.0 |
3113
- | expandIcon | 自定义切换图标 | (panelProps) => ReactNode | - | |
3114
- | expandIconPosition | 设置图标位置 | start | - | 4.21.0 |
3115
- | ghost | 使折叠面板透明且无边框 | boolean | false | 4.4.0 |
3116
- | size | 设置折叠面板大小 | large | middle | 5.2.0 |
3117
- | onChange | 切换面板的回调 | function | - | |
3118
- | items | 折叠项目内容 | | - | 5.6.0 |
3119
3092
 
3093
+ - DatePicker
3094
+ - DatePicker[picker="month"]
3095
+ - DatePicker[picker="week"]
3096
+ - DatePicker[picker="year"]
3097
+ - DatePicker[picker="quarter"] (4.1.0 新增)
3098
+ - RangePicker
3120
3099
 
3121
- ### ItemType
3122
-
3123
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3124
- |--------|--------|--------|--------|--------|
3125
- | classNames | 语义化结构 className | | - | 5.21.0 |
3126
- | collapsible | 是否可折叠或指定可折叠触发区域 | header | - | |
3127
- | forceRender | 被隐藏时是否渲染 body 区域 DOM 结构 | boolean | false | |
3128
- | key | 对应 activeKey | string \| number | - | |
3129
- | label | 面板标题 | ReactNode | - | - |
3130
- | showArrow | 是否展示当前面板上的箭头(为 false 时,collapsible 不能设为 icon) | boolean | true | |
3131
- | styles | 语义化结构 style | | - | 5.21.0 |
3132
-
3133
-
3134
- ### Collapse.Panel
3135
-
3136
- <!-- prettier-ignore -->
3137
- <Container type="warning" title="已废弃">
3138
- 版本 >= 5.6.0 时请使用 items 方式配置面板。
3139
- </Container>
3140
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3141
- |--------|--------|--------|--------|--------|
3142
- | collapsible | 是否可折叠或指定可折叠触发区域 | header | - | 4.9.0 (icon: 4.24.0) |
3143
- | forceRender | 被隐藏时是否渲染 body 区域 DOM 结构 | boolean | false | |
3144
- | header | 面板标题 | ReactNode | - | |
3145
- | key | 对应 activeKey | string \| number | - | |
3146
- | showArrow | 是否展示当前面板上的箭头(为 false 时,collapsible 不能设为 icon) | boolean | true | |
3147
-
3148
-
3149
-
3150
-
3151
- <DemoTitle title="DatePicker" desc="输入或选择时间的控件。">
3152
- #### API
3153
-
3154
- <AntdApiRef url="https://ant.design/components/date-picker-cn/#api"></AntdApiRef>
3155
-
3156
-
3157
- ## antd API
3158
-
3159
- 通用属性参考:[通用属性](/docs/react/common-props)
3160
-
3161
- 日期类组件包括以下五种形式。
3162
-
3163
-
3164
- - DatePicker
3165
- - DatePicker[picker="month"]
3166
- - DatePicker[picker="week"]
3167
- - DatePicker[picker="year"]
3168
- - DatePicker[picker="quarter"] (4.1.0 新增)
3169
- - RangePicker
3170
-
3171
- ### 国际化配置
3100
+ ### 国际化配置
3172
3101
 
3173
3102
  默认配置为 en-US,如果你需要设置其他语言,推荐在入口处使用我们提供的国际化组件,详见:[ConfigProvider 国际化](https://ant.design/components/config-provider-cn/)。
3174
3103
 
@@ -3370,6 +3299,77 @@ export type FormatType =
3370
3299
 
3371
3300
 
3372
3301
 
3302
+ <DemoTitle title="CollapsePanel" desc="折叠面板">
3303
+ #### API
3304
+
3305
+ | 属性名 | 描述 | 类型 | 默认值 |
3306
+ |--------|--------|--------|--------|
3307
+ | collapsedHeight | 收起状态下显示的内容高度 | number | 0 |
3308
+ | expandedHeight | 展开状态下的内容高度,设置后内容超出时可滚动,不设置则自适应内容高度 | number | 300 |
3309
+ | title | 面板标题 | string \| React.ReactNode | "" |
3310
+ | expandOnPanelClick | 是否允许点击整个面板进行展开 | boolean | false |
3311
+ | extra | 面板右侧内容 | React.ReactNode | |
3312
+ | children | 面板内容 | React.ReactNode | |
3313
+ | defaultExpanded | 是否默认展开 | boolean | false |
3314
+ | classNames | 语义化的classNames | Partial> | |
3315
+ | styles | 语义化的styles | Partial<
3316
+ Record
3317
+ > | |
3318
+
3319
+
3320
+
3321
+ ## antd API
3322
+
3323
+ 通用属性参考:[通用属性](/docs/react/common-props)
3324
+
3325
+ ### Collapse
3326
+
3327
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3328
+ |--------|--------|--------|--------|--------|
3329
+ | accordion | 手风琴模式 | boolean | false | |
3330
+ | activeKey | 当前激活 tab 面板的 key | string[] \| string | | |
3331
+ | bordered | 带边框风格的折叠面板 | boolean | true | |
3332
+ | collapsible | 所有子面板是否可折叠或指定可折叠触发区域 | header | - | 4.9.0 |
3333
+ | defaultActiveKey | 初始化选中面板的 key | string[] \| string | - | |
3334
+ | destroyOnHidden | 销毁折叠隐藏的面板 | boolean | false | 5.25.0 |
3335
+ | expandIcon | 自定义切换图标 | (panelProps) => ReactNode | - | |
3336
+ | expandIconPosition | 设置图标位置 | start | - | 4.21.0 |
3337
+ | ghost | 使折叠面板透明且无边框 | boolean | false | 4.4.0 |
3338
+ | size | 设置折叠面板大小 | large | middle | 5.2.0 |
3339
+ | onChange | 切换面板的回调 | function | - | |
3340
+ | items | 折叠项目内容 | | - | 5.6.0 |
3341
+
3342
+
3343
+ ### ItemType
3344
+
3345
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3346
+ |--------|--------|--------|--------|--------|
3347
+ | classNames | 语义化结构 className | | - | 5.21.0 |
3348
+ | collapsible | 是否可折叠或指定可折叠触发区域 | header | - | |
3349
+ | forceRender | 被隐藏时是否渲染 body 区域 DOM 结构 | boolean | false | |
3350
+ | key | 对应 activeKey | string \| number | - | |
3351
+ | label | 面板标题 | ReactNode | - | - |
3352
+ | showArrow | 是否展示当前面板上的箭头(为 false 时,collapsible 不能设为 icon) | boolean | true | |
3353
+ | styles | 语义化结构 style | | - | 5.21.0 |
3354
+
3355
+
3356
+ ### Collapse.Panel
3357
+
3358
+ <!-- prettier-ignore -->
3359
+ <Container type="warning" title="已废弃">
3360
+ 版本 >= 5.6.0 时请使用 items 方式配置面板。
3361
+ </Container>
3362
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3363
+ |--------|--------|--------|--------|--------|
3364
+ | collapsible | 是否可折叠或指定可折叠触发区域 | header | - | 4.9.0 (icon: 4.24.0) |
3365
+ | forceRender | 被隐藏时是否渲染 body 区域 DOM 结构 | boolean | false | |
3366
+ | header | 面板标题 | ReactNode | - | |
3367
+ | key | 对应 activeKey | string \| number | - | |
3368
+ | showArrow | 是否展示当前面板上的箭头(为 false 时,collapsible 不能设为 icon) | boolean | true | |
3369
+
3370
+
3371
+
3372
+
3373
3373
  <DemoTitle title="Collapse" desc="可以折叠/展开的内容区域">
3374
3374
  #### API
3375
3375
 
@@ -3428,6 +3428,77 @@ export type FormatType =
3428
3428
 
3429
3429
 
3430
3430
 
3431
+ <DemoTitle title="Checkbox" desc="收集用户的多项选择。">
3432
+ #### API
3433
+
3434
+ | 属性名 | 描述 | 类型 | 默认值 |
3435
+ |--------|--------|--------|--------|
3436
+ | description | 描述文本 | string | |
3437
+ | descriptionClassName | 描述文本的样式类名 | string | |
3438
+ | descriptionStyle | 描述文本的内联样式 | React.CSSProperties | |
3439
+
3440
+
3441
+ <AntdApiRef url="https://ant.design/components/checkbox-cn/#api"></AntdApiRef>
3442
+
3443
+
3444
+ ## antd API
3445
+
3446
+ 通用属性参考:[通用属性](/docs/react/common-props)
3447
+
3448
+ #### Checkbox
3449
+
3450
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3451
+ |--------|--------|--------|--------|--------|
3452
+ | autoFocus | 自动获取焦点 | boolean | false | |
3453
+ | checked | 指定当前是否选中 | boolean | false | |
3454
+ | defaultChecked | 初始是否选中 | boolean | false | |
3455
+ | disabled | 失效状态 | boolean | false | |
3456
+ | indeterminate | 设置 indeterminate 状态,只负责样式控制 | boolean | false | |
3457
+ | onChange | 变化时的回调函数 | (e: CheckboxChangeEvent) => void | - | |
3458
+ | onBlur | 失去焦点时的回调 | function() | - | |
3459
+ | onFocus | 获得焦点时的回调 | function() | - | |
3460
+
3461
+
3462
+ #### Checkbox.Group
3463
+
3464
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3465
+ |--------|--------|--------|--------|--------|
3466
+ | defaultValue | 默认选中的选项 | (string \| number)[] | [] | |
3467
+ | disabled | 整组失效 | boolean | false | |
3468
+ | name | CheckboxGroup 下所有 | string | - | |
3469
+ | options | 指定可选项 | string[] \| number[] \| Option[] | [] | |
3470
+ | value | 指定选中的选项 | (string \| number \| boolean)[] | [] | |
3471
+ | title | 选项的 title | string | - | |
3472
+ | className | 选项的类名 | string | - | 5.25.0 |
3473
+ | style | 选项的样式 | React.CSSProperties | - | |
3474
+ | onChange | 变化时的回调函数 | (checkedValue: T[]) => void | - | |
3475
+
3476
+
3477
+ ##### Option
3478
+
3479
+
3480
+ ```typescript
3481
+ interface Option {
3482
+ label: string;
3483
+ value: string;
3484
+ disabled?: boolean;
3485
+ }
3486
+ ```
3487
+
3488
+
3489
+ ### 方法
3490
+
3491
+ #### Checkbox
3492
+
3493
+ | 名称 | 描述 | 版本 |
3494
+ |--------|--------|--------|
3495
+ | blur() | 移除焦点 | |
3496
+ | focus() | 获取焦点 | |
3497
+ | nativeElement | 返回 Checkbox 的 DOM 节点 | 5.17.3 |
3498
+
3499
+
3500
+
3501
+
3431
3502
  <DemoTitle title="CodeBlock" desc="代码块">
3432
3503
  #### API
3433
3504
 
@@ -3561,116 +3632,6 @@ type PresetColors = 'blue' | 'purple' | 'cyan' | 'green' | 'magenta' | 'pink' |
3561
3632
 
3562
3633
 
3563
3634
 
3564
- <DemoTitle title="Checkbox" desc="收集用户的多项选择。">
3565
- #### API
3566
-
3567
- | 属性名 | 描述 | 类型 | 默认值 |
3568
- |--------|--------|--------|--------|
3569
- | description | 描述文本 | string | |
3570
- | descriptionClassName | 描述文本的样式类名 | string | |
3571
- | descriptionStyle | 描述文本的内联样式 | React.CSSProperties | |
3572
-
3573
-
3574
- <AntdApiRef url="https://ant.design/components/checkbox-cn/#api"></AntdApiRef>
3575
-
3576
-
3577
- ## antd API
3578
-
3579
- 通用属性参考:[通用属性](/docs/react/common-props)
3580
-
3581
- #### Checkbox
3582
-
3583
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3584
- |--------|--------|--------|--------|--------|
3585
- | autoFocus | 自动获取焦点 | boolean | false | |
3586
- | checked | 指定当前是否选中 | boolean | false | |
3587
- | defaultChecked | 初始是否选中 | boolean | false | |
3588
- | disabled | 失效状态 | boolean | false | |
3589
- | indeterminate | 设置 indeterminate 状态,只负责样式控制 | boolean | false | |
3590
- | onChange | 变化时的回调函数 | (e: CheckboxChangeEvent) => void | - | |
3591
- | onBlur | 失去焦点时的回调 | function() | - | |
3592
- | onFocus | 获得焦点时的回调 | function() | - | |
3593
-
3594
-
3595
- #### Checkbox.Group
3596
-
3597
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3598
- |--------|--------|--------|--------|--------|
3599
- | defaultValue | 默认选中的选项 | (string \| number)[] | [] | |
3600
- | disabled | 整组失效 | boolean | false | |
3601
- | name | CheckboxGroup 下所有 | string | - | |
3602
- | options | 指定可选项 | string[] \| number[] \| Option[] | [] | |
3603
- | value | 指定选中的选项 | (string \| number \| boolean)[] | [] | |
3604
- | title | 选项的 title | string | - | |
3605
- | className | 选项的类名 | string | - | 5.25.0 |
3606
- | style | 选项的样式 | React.CSSProperties | - | |
3607
- | onChange | 变化时的回调函数 | (checkedValue: T[]) => void | - | |
3608
-
3609
-
3610
- ##### Option
3611
-
3612
-
3613
- ```typescript
3614
- interface Option {
3615
- label: string;
3616
- value: string;
3617
- disabled?: boolean;
3618
- }
3619
- ```
3620
-
3621
-
3622
- ### 方法
3623
-
3624
- #### Checkbox
3625
-
3626
- | 名称 | 描述 | 版本 |
3627
- |--------|--------|--------|
3628
- | blur() | 移除焦点 | |
3629
- | focus() | 获取焦点 | |
3630
- | nativeElement | 返回 Checkbox 的 DOM 节点 | 5.17.3 |
3631
-
3632
-
3633
-
3634
-
3635
- <DemoTitle title="Avatar" desc="用来代表用户或事物,支持图片、图标或字符展示。">
3636
- #### API
3637
-
3638
- <AntdApiRef url="https://ant.design/components/avatar-cn/#api"></AntdApiRef>
3639
-
3640
-
3641
- ## antd API
3642
-
3643
- 通用属性参考:[通用属性](/docs/react/common-props)
3644
-
3645
- ### Avatar
3646
-
3647
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3648
- |--------|--------|--------|--------|--------|
3649
- | alt | 图像无法显示时的替代文本 | string | - | |
3650
- | gap | 字符类型距离左右两侧边界单位像素 | number | 4 | 4.3.0 |
3651
- | icon | 设置头像的自定义图标 | ReactNode | - | |
3652
- | shape | 指定头像的形状 | circle | circle | |
3653
- | size | 设置头像的大小 | number \| | default | 4.7.0 |
3654
- | src | 图片类头像的资源地址或者图片元素 | string \| ReactNode | - | ReactNode: 4.8.0 |
3655
- | srcSet | 设置图片类头像响应式资源地址 | string | - | |
3656
- | draggable | 图片是否允许拖动 | boolean \| | true | |
3657
- | crossOrigin | CORS 属性设置 | 'anonymous' | - | 4.17.0 |
3658
- | onError | 图片加载失败的事件,返回 false 会关闭组件默认的 fallback 行为 | () => boolean | - | |
3659
-
3660
-
3661
- Tip:你可以设置 `icon` 或 `children` 作为图片加载失败的默认 fallback 行为,优先级为 `icon` > `children`
3662
-
3663
- ### Avatar.Group <Badge>4.5.0+</Badge>
3664
-
3665
- | 参数 | 说明 | 类型 | 默认值 | 版本 |
3666
- |--------|--------|--------|--------|--------|
3667
- | max | 设置最多显示相关配置, | { count?: number; style?: CSSProperties; popover?: PopoverProps } | - | 5.18.0 |
3668
- | size | 设置头像的大小 | number \| | default | 4.8.0 |
3669
- | shape | 设置头像的形状 | circle | circle | 5.8.0 |
3670
-
3671
-
3672
-
3673
-
3674
3635
  <DemoTitle title="Breadcrumb" desc="显示当前页面在系统层级结构中的位置,并能向上返回。">
3675
3636
  #### API
3676
3637
 
@@ -3790,6 +3751,45 @@ return <Breadcrumb itemRender={itemRender} items={items} />;
3790
3751
 
3791
3752
 
3792
3753
 
3754
+ <DemoTitle title="Avatar" desc="用来代表用户或事物,支持图片、图标或字符展示。">
3755
+ #### API
3756
+
3757
+ <AntdApiRef url="https://ant.design/components/avatar-cn/#api"></AntdApiRef>
3758
+
3759
+
3760
+ ## antd API
3761
+
3762
+ 通用属性参考:[通用属性](/docs/react/common-props)
3763
+
3764
+ ### Avatar
3765
+
3766
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3767
+ |--------|--------|--------|--------|--------|
3768
+ | alt | 图像无法显示时的替代文本 | string | - | |
3769
+ | gap | 字符类型距离左右两侧边界单位像素 | number | 4 | 4.3.0 |
3770
+ | icon | 设置头像的自定义图标 | ReactNode | - | |
3771
+ | shape | 指定头像的形状 | circle | circle | |
3772
+ | size | 设置头像的大小 | number \| | default | 4.7.0 |
3773
+ | src | 图片类头像的资源地址或者图片元素 | string \| ReactNode | - | ReactNode: 4.8.0 |
3774
+ | srcSet | 设置图片类头像响应式资源地址 | string | - | |
3775
+ | draggable | 图片是否允许拖动 | boolean \| | true | |
3776
+ | crossOrigin | CORS 属性设置 | 'anonymous' | - | 4.17.0 |
3777
+ | onError | 图片加载失败的事件,返回 false 会关闭组件默认的 fallback 行为 | () => boolean | - | |
3778
+
3779
+
3780
+ Tip:你可以设置 `icon` 或 `children` 作为图片加载失败的默认 fallback 行为,优先级为 `icon` > `children`
3781
+
3782
+ ### Avatar.Group <Badge>4.5.0+</Badge>
3783
+
3784
+ | 参数 | 说明 | 类型 | 默认值 | 版本 |
3785
+ |--------|--------|--------|--------|--------|
3786
+ | max | 设置最多显示相关配置, | { count?: number; style?: CSSProperties; popover?: PopoverProps } | - | 5.18.0 |
3787
+ | size | 设置头像的大小 | number \| | default | 4.8.0 |
3788
+ | shape | 设置头像的形状 | circle | circle | 5.8.0 |
3789
+
3790
+
3791
+
3792
+
3793
3793
  <DemoTitle title="Audio" desc="音频展示">
3794
3794
  #### API
3795
3795
 
@@ -4059,120 +4059,6 @@ const confirmed = await modal.confirm({ ... });
4059
4059
 
4060
4060
 
4061
4061
 
4062
- ## 内置主题
4063
-
4064
- Alibaba Cloud Spark Design 提供四种内置主题:
4065
-
4066
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #615CED;"></span> purpleTheme</div>
4067
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #5551CC;"></span> purpleDarkTheme(暗色模式)</div>
4068
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: rgba(26, 26, 29, 1);"></span> carbonTheme</div>
4069
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #676767;"></span> carbonDarkTheme(暗色模式)</div>
4070
-
4071
- ### 示例用法
4072
-
4073
-
4074
- ```tsx
4075
- import { ConfigProvider, purpleTheme } from '@agentscope-ai/design';
4076
-
4077
- const App = () => {
4078
- return <ConfigProvider {...purpleTheme}>Hello Spark Design!</ConfigProvider>;
4079
- };
4080
-
4081
- export default App;
4082
- ```
4083
-
4084
-
4085
- ## 从 Antd token 生成您自己的主题
4086
-
4087
- 如果您已经有了 Antd 主题,仍然可以使用 generateThemeByToken 生成 spark 风格的主题
4088
-
4089
-
4090
- ```tsx
4091
- import { ConfigProvider, generateThemeByToken } from '@agentscope-ai/design';
4092
- const yourToken = {
4093
- borderRadiusXS: 2,
4094
- borderRadiusSM: 4,
4095
- borderRadius: 6,
4096
- borderRadiusLG: 8,
4097
- borderRadiusXL: 12,
4098
- borderRadiusFull: 999,
4099
- wireframe: false,
4100
- colorPrimaryBg: '#F2F0FF',
4101
- colorPrimaryBgHover: '#F2F0FF',
4102
- colorPrimaryBorder: '#E2DEFF',
4103
- colorPrimaryBorderHover: '#BCB5FF',
4104
- // ... 您可以在下一个文档中找到完整版本的 tokens:Tokens 和 CSS 变量
4105
- };
4106
- const darkMode = false;
4107
- const yourThemeWithSparkStyle = generateThemeByToken(yourToken, darkMode);
4108
- const App = () => {
4109
- return (
4110
- <ConfigProvider {...yourThemeWithSparkStyle}>
4111
- Hello Spark Design!
4112
- </ConfigProvider>
4113
- );
4114
- };
4115
-
4116
- export default App;
4117
- ```
4118
-
4119
-
4120
- 您仍然可以修改生成的主题:`yourThemeWithSparkStyle`,但不建议这样做。我们建议您保持原始主题以获得 Spark Design 的最佳体验。
4121
-
4122
-
4123
-
4124
- <div align="center"><a name="readme-top"></a>
4125
- <img height="120" src="https://img.alicdn.com/imgextra/i1/O1CN01ipemFb1EzmZI9LiTe_!!6000000000423-55-tps-28-28.svg" style="border: none">
4126
- <h1>Alibaba Cloud Spark Design</h1>
4127
- </div>
4128
-
4129
- # 概述
4130
-
4131
- Alibaba Cloud Spark Design 是一个基于 Ant Design 的 React UI 组件库,包含丰富的基础组件和场景组件,专为构建优秀的 LLM 产品而设计。
4132
- <br />
4133
- <br />
4134
-
4135
- ## ✨ 特性
4136
-
4137
-
4138
- - <img height="15" src="https://gw.alipayobjects.com/zos/rmsportal/KDpgvguMpGfqaHPjicRK.svg"> 基于 Ant Design,兼容 Ant Design 生态系统。您可以无需修改代码即可切换到 Spark Design。
4139
- - 🛡 使用 TypeScript 编写,具有可预测的静态类型。
4140
- - 🧠 为 LLM 产品设计的各种场景组件。
4141
- - 💡 与@agentscope-ai/chat 和 @agentscope-ai/flow 配合使用,构建企业级 LLM 应用。
4142
- - 🎨 多种预设主题。
4143
- - ☀️ 轻松切换明暗模式。
4144
-
4145
- ## 📦 安装
4146
-
4147
-
4148
- ```bash
4149
- npm install antd @agentscope-ai/icons @agentscope-ai/design --save
4150
- ```
4151
-
4152
-
4153
- ## Tree Shaking 支持
4154
-
4155
- @agentscope-ai/design 默认基于 ES 模块支持 tree shaking
4156
-
4157
- ## TypeScript
4158
-
4159
- @agentscope-ai/chat 使用 TypeScript 编写并提供完整的定义文件。
4160
-
4161
- ## 内置主题
4162
-
4163
- 我们提供四种内置主题:
4164
-
4165
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #615CED;"></span> purpleTheme</div>
4166
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #5551CC;"></span> purpleDarkTheme(暗色模式)</div>
4167
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: rgba(26, 26, 29, 1);"></span> carbonTheme</div>
4168
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #676767;"></span> carbonDarkTheme(暗色模式)</div>
4169
-
4170
- ## 🏗️ 开源
4171
-
4172
- [@agentscope-ai/design](https://www.npmjs.com/package/@agentscope-ai/design) 和 [@agentscope-ai/chat](https://www.npmjs.com/package/@agentscope-ai/chat) 正在积极推进开源,预计将在 2025 年底完成。目前,您可以通过 npm 访问我们的项目。
4173
-
4174
-
4175
-
4176
4062
  # 使用
4177
4063
 
4178
4064
 
@@ -4199,778 +4085,19 @@ export default () => {
4199
4085
 
4200
4086
 
4201
4087
 
4202
- # 从 Antd 迁移
4203
-
4204
- ## 📦 安装
4205
-
4206
-
4207
- ```bash
4208
- $ npm install @agentscope-ai/icons @agentscope-ai/design --save
4209
- ```
4210
-
4211
-
4212
- ## 🔨 使用
4213
-
4214
- 从 @agentscope-ai/design 导出的所有同名组件在 API 方面都与 antd 的对应组件兼容,这意味着您无需学习如何使用它们。如果您想充分利用 Alibaba Cloud Spark Design 的新功能,可以尝试使用这些组件而不是 antd 的组件。
4215
-
4216
-
4217
- ```tsx
4218
- import {
4219
- Button,
4220
- Image,
4221
- ConfigProvider,
4222
- purpleDarkTheme,
4223
- purpleTheme,
4224
- } from '@agentscope-ai/design';
4225
- import { SparkSunLine, SparkMoonLine } from '@agentscope-ai/icons';
4226
- import { Flex } from 'antd';
4227
- import zhCN from 'antd/locale/zh_CN';
4228
- import { useState } from 'react';
4229
-
4230
- const App = () => {
4231
- const [colorMode, setColorMode] = useState('light');
4232
- const theme = colorMode === 'light' ? purpleTheme : purpleDarkTheme;
4233
-
4234
- const prefix = 'sps';
4235
- return (
4236
- <ConfigProvider
4237
- {...theme} // 您可以从 purpleTheme、purpleDarkTheme、carbonTheme 和 carbonDarkTheme 中选择
4238
- prefix={prefix} // Ant Design 和 @agentscope-ai/design 的前缀
4239
- prefixCls={prefix}
4240
- iconfont="//at.alicdn.com/t/a/font_4807885_ugexdeaoq7.js" // 可选参数,您可以从 https://www.iconfont.cn/ 获取
4241
- locale={zhCN} // 来自 Ant Design 的语言包
4242
- style={{
4243
- width: '100%',
4244
- height: '100%',
4245
- }}
4246
- >
4247
- <div
4248
- style={{
4249
- width: '100%',
4250
- height: '100%',
4251
- backgroundColor: `var(--${prefix}-color-bg-base)`,
4252
- }}
4253
- >
4254
- <Flex vertical gap={16} align="center" style={{ padding: '12px 0' }}>
4255
- <Image
4256
- width={120}
4257
- src="https://img.alicdn.com/imgextra/i1/O1CN01Py27NU1re2pgohzqU_!!6000000005655-0-tps-480-480.jpg"
4258
- />
4259
- <div
4260
- style={{
4261
- color: `var(--${prefix}-ant-color-text-base)`,
4262
- fontSize: '24px',
4263
- textAlign: 'center',
4264
- }}
4265
- >
4266
- Hello Spark Design!
4267
- </div>
4268
- <Button
4269
- type="primary"
4270
- onClick={() => {
4271
- setColorMode(colorMode === 'light' ? 'dark' : 'light');
4272
- }}
4273
- icon={colorMode === 'light' ? <SparkMoonLine /> : <SparkSunLine />}
4274
- >
4275
- {colorMode === 'light' ? '暗色' : '亮色'} 模式
4276
- </Button>
4277
- </Flex>
4278
- </div>
4279
- </ConfigProvider>
4280
- );
4281
- };
4282
-
4283
- export default App;
4284
- ```
4285
-
4286
-
4287
- 如果您想继续使用 antd 的组件,那也没问题。您只需要将 antd 的 ConfigProvider 替换为 @agentscope-ai/design 的即可。
4288
-
4289
-
4290
- ```tsx
4291
- import {
4292
- ConfigProvider,
4293
- purpleDarkTheme,
4294
- purpleTheme,
4295
- } from '@agentscope-ai/design';
4296
- import { Button, Image, Flex } from 'antd';
4297
- import { SparkSunLine, SparkMoonLine } from '@agentscope-ai/icons';
4298
- import zhCN from 'antd/locale/zh_CN';
4299
- import { useState } from 'react';
4300
-
4301
- const App = () => {
4302
- const [colorMode, setColorMode] = useState('light');
4303
- const theme = colorMode === 'light' ? purpleTheme : purpleDarkTheme;
4304
-
4305
- const prefix = 'sps';
4306
- return (
4307
- <ConfigProvider
4308
- {...theme} // 您可以从 purpleTheme、purpleDarkTheme、carbonTheme 和 carbonDarkTheme 中选择
4309
- prefix={prefix} // Ant Design 和 @agentscope-ai/design 的前缀
4310
- prefixCls={prefix}
4311
- iconfont="//at.alicdn.com/t/a/font_4807885_ugexdeaoq7.js" // 可选参数,您可以从 https://www.iconfont.cn/ 获取
4312
- locale={zhCN} // 来自 Ant Design 的语言包
4313
- style={{
4314
- width: '100%',
4315
- height: '100%',
4316
- }}
4317
- >
4318
- <div
4319
- style={{
4320
- width: '100%',
4321
- height: '100%',
4322
- backgroundColor: `var(--${prefix}-color-bg-base)`,
4323
- }}
4324
- >
4325
- <Flex vertical gap={16} align="center" style={{ padding: '12px 0' }}>
4326
- <Image
4327
- width={120}
4328
- src="https://img.alicdn.com/imgextra/i1/O1CN01Py27NU1re2pgohzqU_!!6000000005655-0-tps-480-480.jpg"
4329
- />
4330
- <div
4331
- style={{
4332
- color: `var(--${prefix}-ant-color-text-base)`,
4333
- fontSize: '24px',
4334
- textAlign: 'center',
4335
- }}
4336
- >
4337
- Hello Spark Design!
4338
- </div>
4339
- <Button
4340
- type="primary"
4341
- onClick={() => {
4342
- setColorMode(colorMode === 'light' ? 'dark' : 'light');
4343
- }}
4344
- icon={colorMode === 'light' ? <SparkMoonLine /> : <SparkSunLine />}
4345
- >
4346
- {colorMode === 'light' ? '暗色' : '亮色'} 模式
4347
- </Button>
4348
- </Flex>
4349
- </div>
4350
- </ConfigProvider>
4351
- );
4352
- };
4353
-
4354
- export default App;
4355
- ```
4356
-
4357
-
4358
-
4359
-
4360
- # 使用
4361
-
4362
- 如果您有自己的 iconfont 项目,可以将您的图标集成到 Spark Design 中,并通过简单的符号名称访问您的图标。
4363
-
4364
-
4365
- ```tsx
4366
- import {
4367
- ConfigProvider,
4368
- purpleTheme,
4369
- Button,
4370
- IconFont,
4371
- IconButton,
4372
- } from '@agentscope-ai/design';
4373
- import { Flex } from 'antd';
4374
- import zhCN from 'antd/locale/zh_CN';
4375
- import { useState } from 'react';
4376
-
4377
- const App = () => {
4378
- const prefix = 'sps';
4379
- const iconSymbol = 'spark-effciency-line';
4380
- const iconfont = '//at.alicdn.com/t/a/font_4807885_ugexdeaoq7.js'; // 您可以从 https://www.iconfont.cn/ 获取
4381
- return (
4382
- <ConfigProvider
4383
- {...purpleTheme}
4384
- prefix={prefix}
4385
- prefixCls={prefix}
4386
- iconfont={iconfont}
4387
- locale={zhCN}
4388
- style={{
4389
- width: '100%',
4390
- height: '100%',
4391
- }}
4392
- >
4393
- <Flex
4394
- style={{
4395
- width: '100%',
4396
- height: '100%',
4397
- backgroundColor: `var(--${prefix}-color-bg-base)`,
4398
- }}
4399
- justify="center"
4400
- align="center"
4401
- >
4402
- <Flex vertical gap={16} style={{ width: '300px', padding: '12px 0' }}>
4403
- <Flex gap={8}>
4404
- <div style={{ width: '100px', lineHeight: '32px' }}>IconFont:</div>
4405
- <IconFont type={iconSymbol} />
4406
- </Flex>
4407
- <Flex gap={8}>
4408
- <div style={{ width: '100px', lineHeight: '32px' }}>Button:</div>
4409
- <Button type="primary" iconType={iconSymbol}>
4410
- 添加用户
4411
- </Button>
4412
- </Flex>
4413
- <Flex gap={8}>
4414
- <div style={{ width: '100px', lineHeight: '32px' }}>
4415
- IconButton:
4416
- </div>
4417
- <IconButton iconType={iconSymbol}></IconButton>
4418
- </Flex>
4419
- </Flex>
4420
- </Flex>
4421
- </ConfigProvider>
4422
- );
4423
- };
4424
-
4425
- export default App;
4426
- ```
4427
-
4428
-
4429
-
4430
-
4431
- # Vibe 编程
4432
-
4433
- ## LLMs.txt
4434
-
4435
- 为了让 Cursor 和 Claude Code 等工具理解 Spark Design,我们支持 LLMs.txt 文件,使 Spark Design 的文档可供大型语言模型使用。
4436
-
4437
-
4438
- - [index.llms.txt](https://g.alicdn.com/code/npm/@ali/agentscope-ai-design/4.7.2/docs-dist/llms/index.llms.txt):主要的 LLMs.txt 索引文件
4439
- - [all.llms.txt](https://g.alicdn.com/code/npm/@ali/agentscope-ai-design/4.7.2/docs-dist/llms/all.llms.txt):Spark Design 的完整文档
4440
-
4441
- 在 Cursor 中使用 @Docs 功能将 LLMs.txt 文件包含在您的项目中。[了解更多](https://docs.cursor.com/en/context/@-symbols/@-docs)
4442
-
4443
- ## D2C
4444
-
4445
- 在前端使用 Alibaba Cloud Spark Design、设计稿使用 Spark Design 套件的前提下,通过 masterGo 视觉稿生成代码可以做到以下几点:
4446
-
4447
-
4448
- - 准确识别 icon
4449
- - 使用标准 css token
4450
- - 无需测量间距、圆角等数据,AI 直接还原布局(90%以上概率准确生成)
4451
- - 使用标准组件还原页面,大部分标准组件可一次性正确生成,无需二次调整
4452
-
4453
- <div>
4454
- <video style="width: 100%" controls src="https://cloud.video.taobao.com/vod/PrrYzvYJkoDlbJwoL8Ei1Bo_60LrKAROCojWxB_EAYs.mp4" />
4455
- </div>
4456
-
4457
- 我们会在不久的将来开放 masterGo 的设计套件和 rules,帮助您高效率还原视觉稿
4458
-
4459
-
4460
-
4461
- # 从零开始使用
4462
-
4463
- ## 📦 安装
4464
-
4465
-
4466
- ```bash
4467
- $ npm install antd @agentscope-ai/icons @agentscope-ai/design --save
4468
- ```
4469
-
4470
-
4471
- ## 🔨 使用
4472
-
4473
-
4474
- ```tsx
4475
- import {
4476
- Button,
4477
- Image,
4478
- ConfigProvider,
4479
- purpleDarkTheme,
4480
- purpleTheme,
4481
- } from '@agentscope-ai/design';
4482
- import { SparkSunLine, SparkMoonLine } from '@agentscope-ai/icons';
4483
- import { Flex } from 'antd';
4484
- import zhCN from 'antd/locale/zh_CN';
4485
- import { useState } from 'react';
4486
-
4487
- const App = () => {
4488
- const [colorMode, setColorMode] = useState('light');
4489
- const theme = colorMode === 'light' ? purpleTheme : purpleDarkTheme;
4490
-
4491
- const prefix = 'sps';
4492
- return (
4493
- <ConfigProvider
4494
- {...theme} // 您可以从 purpleTheme、purpleDarkTheme、carbonTheme 和 carbonDarkTheme 中选择
4495
- prefix={prefix} // Ant Design 和 @agentscope-ai/design 的前缀
4496
- prefixCls={prefix}
4497
- iconfont="//at.alicdn.com/t/a/font_4807885_ugexdeaoq7.js" // 可选参数,您可以从 https://www.iconfont.cn/ 获取
4498
- locale={zhCN} // 来自 Ant Design 的语言包
4499
- style={{
4500
- width: '100%',
4501
- height: '100%',
4502
- }}
4503
- >
4504
- <div
4505
- style={{
4506
- width: '100%',
4507
- height: '100%',
4508
- backgroundColor: `var(--${prefix}-color-bg-base)`,
4509
- }}
4510
- >
4511
- <Flex vertical gap={16} align="center" style={{ padding: '12px 0' }}>
4512
- <Image
4513
- width={120}
4514
- src="https://img.alicdn.com/imgextra/i1/O1CN01Py27NU1re2pgohzqU_!!6000000005655-0-tps-480-480.jpg"
4515
- />
4516
- <div
4517
- style={{
4518
- color: `var(--${prefix}-ant-color-text-base)`,
4519
- fontSize: '24px',
4520
- textAlign: 'center',
4521
- }}
4522
- >
4523
- Hello Spark Design!
4524
- </div>
4525
- <Button
4526
- type="primary"
4527
- onClick={() => {
4528
- setColorMode(colorMode === 'light' ? 'dark' : 'light');
4529
- }}
4530
- icon={colorMode === 'light' ? <SparkMoonLine /> : <SparkSunLine />}
4531
- >
4532
- {colorMode === 'light' ? '暗色' : '亮色'} 模式
4533
- </Button>
4534
- </Flex>
4535
- </div>
4536
- </ConfigProvider>
4537
- );
4538
- };
4539
-
4540
- export default App;
4541
- ```
4542
-
4543
-
4544
-
4545
-
4546
- # Tokens
4547
-
4548
- 除了来自 [antd](https://ant.design/theme-editor) 的固有 tokens 之外,Spark Design 在原有基础上扩展了更多变量。完整的 token 示例如下所示:
4549
-
4550
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #615CED;"></span> purpleTheme</div>
4551
-
4552
- ```json
4553
- {
4554
- "borderRadiusXS": 2,
4555
- "borderRadiusSM": 4,
4556
- "borderRadius": 6,
4557
- "borderRadiusLG": 8,
4558
- "borderRadiusXL": 12,
4559
- "borderRadiusFull": 999,
4560
- "wireframe": false,
4561
- "colorPrimaryBg": "rgba(97, 92, 237, 0.08)",
4562
- "colorPrimaryBgHover": "#F2F0FF",
4563
- "colorPrimaryBorder": "#E2DEFF",
4564
- "colorPrimaryBorderHover": "#BCB5FF",
4565
- "colorPrimaryHover": "#9189FA",
4566
- "colorPrimary": "#615CED",
4567
- "colorPrimaryActive": "#4444C7",
4568
- "colorPrimaryTextHover": "#9189FA",
4569
- "colorPrimaryText": "#615CED",
4570
- "colorPrimaryTextActive": "#4444C7",
4571
- "colorTextBase": "#26244c",
4572
- "colorBgBase": "#FFFFFF",
4573
- "colorText": "rgba(38, 36, 76, 0.88)",
4574
- "colorTextSecondary": "rgba(38, 36, 76, 0.65)",
4575
- "colorTextTertiary": "rgba(38, 36, 76, 0.45)",
4576
- "colorTextQuaternary": "rgba(38, 36, 76, 0.25)",
4577
- "colorBorder": "#cdd0dc",
4578
- "colorBorderSecondary": "#e6e8ee",
4579
- "colorFill": "#cdd0dc5c",
4580
- "colorFillSecondary": "#cdd0dc33",
4581
- "colorFillTertiary": "#cdd0dc26",
4582
- "colorFillQuaternary": "#cdd0dc1a",
4583
- "colorBgContainer": "#FFFFFF",
4584
- "colorBgElevated": "#FFFFFF",
4585
- "colorBgLayout": "#f9fafd",
4586
- "colorBgSpotlight": "rgba(38, 36, 76, 0.85)",
4587
- "colorBgMask": "rgba(20, 19, 39, 0.45)",
4588
- "colorInfo": "#0B83F1",
4589
- "colorInfoHover": "#5EBCFF",
4590
- "colorInfoBorder": "#87D1FF",
4591
- "colorInfoText": "#0B83F1",
4592
- "colorInfoBg": "#E6F7FF",
4593
- "colorInfoBgHover": "#B0E3FF",
4594
- "colorInfoBorderHover": "#5EBCFF",
4595
- "colorSuccess": "#5BB98B",
4596
- "colorSuccessHover": "#ABD4BE",
4597
- "colorSuccessBg": "#EBFAF0",
4598
- "colorSuccessBgHover": "#DFEDE4",
4599
- "colorSuccessBorder": "#D3E0D9",
4600
- "colorSuccessBorderHover": "#ABD4BE",
4601
- "colorWarning": "#FAAD14",
4602
- "colorWarningHover": "#FFD666",
4603
- "colorWarningBg": "#FFFBE6",
4604
- "colorWarningBgHover": "#FFF1B8",
4605
- "colorWarningBorder": "#FFE58F",
4606
- "colorWarningBorderHover": "#FFD666",
4607
- "colorError": "#FF4D4F",
4608
- "colorErrorHover": "#FF7875",
4609
- "colorErrorBg": "#FFF2F0",
4610
- "colorErrorBgHover": "#FFF1F0",
4611
- "colorErrorBorder": "#FFCCC7",
4612
- "colorErrorBorderHover": "#FFA39E",
4613
- "colorLink": "#615CED",
4614
- "boxShadow": "0px 4px 6px 0px rgba(0, 0, 0, 0.08)",
4615
- "boxShadowSecondary": "0px 12px 24px -16px rgba(0, 0, 0, 0.06),0px 8px 40px 0px rgba(0, 0, 0, 0.12),0px 0px 1px 0px rgba(0, 0, 0, 0.04)",
4616
-
4617
- "colorTextWhite": "#ffffff",
4618
- "colorTextOnPrimary": "#ffffff",
4619
- "colorFillDisable": "#DBDAE7",
4620
- "colorPurple": "#615CED",
4621
- "colorPurpleHover": "#8080FF",
4622
- "colorPurpleBg": "rgba(226, 222, 255, 0.8)",
4623
- "colorPink": "#EC4899",
4624
- "colorPinkHover": "#E593BC",
4625
- "colorPinkBg": "rgba(251, 220, 239, 0.8)",
4626
- "colorYellow": "#EAB308",
4627
- "colorYellowHover": "#F1D372",
4628
- "colorYellowBg": "rgba(255, 250, 184, 0.8)",
4629
- "colorOrange": "#FA8125",
4630
- "colorOrangeHover": "#E88C45",
4631
- "colorOrangeBg": "rgba(255, 232, 201, 0.8)",
4632
- "colorTeal": "#14B8A6",
4633
- "colorTealHover": "#5FB3A9",
4634
- "colorTealBg": "rgba(200, 244, 233, 0.8)",
4635
- "colorBlue": "#0090FF",
4636
- "colorBlueHover": "#72BCF5",
4637
- "colorBlueBg": "rgba(194, 229, 255, 0.8)",
4638
- "colorMauve": "#8E8C99",
4639
- "colorMauveHover": "#C0BFC8",
4640
- "colorMauveBg": "rgba(239, 240, 243, 0.8)",
4641
- "colorSlate": "#1E293B",
4642
- "colorSlateHover": "#475569",
4643
- "colorSlateBg": "#E2E8F0",
4644
- "colorLavender": "#A77BFF",
4645
- "colorLavenderHover": "#BB99FF",
4646
- "colorLavenderBg": "rgba(226, 212, 255, 0.8)",
4647
-
4648
- "boxShadowTertiary": "0px 12px 32px -16px rgba(0, 0, 0, 0.24),0px 12px 60px 0px rgba(0, 0, 0, 0.12),0px 0px 1px 0px rgba(0, 0, 0, 0.04)",
4649
- "boxShadowTertiaryLeft": "-12px 0px 32px -16px rgba(0, 0, 0, 0.24),-12px 0px 60px 0px rgba(0, 0, 0, 0.12),0px 0px 1px 0px rgba(0, 0, 0, 0.04)",
4650
- "boxShadowInput": "0px 12px 24px -16px rgba(54, 54, 73, 0.04),0px 12px 40px 0px rgba(51, 51, 71, 0.08),0px 0px 1px 0px rgba(44, 44, 54, 0.02)"
4651
- }
4652
- ```
4653
-
4654
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: #5551CC;"></span> purpleDarkTheme(暗色模式)</div>
4655
-
4656
- ```json
4657
- {
4658
- "borderRadiusXS": 2,
4659
- "borderRadiusSM": 4,
4660
- "borderRadius": 6,
4661
- "borderRadiusLG": 8,
4662
- "borderRadiusXL": 12,
4663
- "borderRadiusFull": 999,
4664
- "wireframe": false,
4665
- "colorPrimaryBg": "#202041",
4666
- "colorPrimaryBgHover": "#202041",
4667
- "colorPrimaryBorder": "#2B2A55",
4668
- "colorPrimaryBorderHover": "#373476",
4669
- "colorPrimaryHover": "#857DE3",
4670
- "colorPrimary": "#5551CC",
4671
- "colorPrimaryActive": "#4643A1",
4672
- "colorPrimaryTextHover": "#857DE3",
4673
- "colorPrimaryText": "#5551CC",
4674
- "colorPrimaryTextActive": "#4643A1",
4675
- "colorTextBase": "#E7E7ED",
4676
- "colorBgBase": "#000000",
4677
- "colorText": "rgba(231, 231, 237, 0.88)",
4678
- "colorTextSecondary": "rgba(231, 231, 237, 0.65)",
4679
- "colorTextTertiary": "rgba(231, 231, 237, 0.45)",
4680
- "colorTextQuaternary": "rgba(231, 231, 237, 0.25)",
4681
- "colorBorder": "rgba(71, 71, 97, 0.8)",
4682
- "colorBorderSecondary": "rgba(56, 56, 76, 0.8)",
4683
- "colorFill": "rgba(231, 231, 237, 0.18)",
4684
- "colorFillSecondary": "rgba(231, 231, 237, 0.12)",
4685
- "colorFillTertiary": "rgba(231, 231, 237, 0.08)",
4686
- "colorFillQuaternary": "rgba(231, 231, 237, 0.04)",
4687
- "colorBgContainer": "#0F0F14",
4688
- "colorBgElevated": "#0F0F14",
4689
- "colorBgLayout": "#0F0F14",
4690
- "colorBgSpotlight": "rgba(71, 71, 97, 0.85)",
4691
- "colorBgMask": "rgba(5, 5, 8, 0.8)",
4692
- "colorInfo": "#0B83F1",
4693
- "colorInfoHover": "rgba(42, 114, 165, 1)",
4694
- "colorInfoBorder": "rgba(135, 209, 255, 0.2)",
4695
- "colorInfoText": "#0B83F1",
4696
- "colorInfoBg": "rgba(27, 73, 115, 0.25)",
4697
- "colorInfoBgHover": "rgba(27, 73, 115, 0.32)",
4698
- "colorInfoBorderHover": "rgba(94, 188, 255, 0.2)",
4699
- "colorSuccess": "#5BB98B",
4700
- "colorSuccessHover": "rgba(87, 141, 112, 1)",
4701
- "colorSuccessBg": "rgba(0, 50, 26, 0.25)",
4702
- "colorSuccessBgHover": "rgba(0, 50, 26, 0.32)",
4703
- "colorSuccessBorder": "rgba(211, 224, 217, 0.2)",
4704
- "colorSuccessBorderHover": "rgba(171, 212, 190, 0.2)",
4705
- "colorWarning": "#FAAD14",
4706
- "colorWarningHover": "rgba(170, 136, 43, 1)",
4707
- "colorWarningBg": "rgba(129, 116, 49, 0.25)",
4708
- "colorWarningBgHover": "rgba(129, 116, 49, 0.32)",
4709
- "colorWarningBorder": "rgba(255, 229, 143, 0.2)",
4710
- "colorWarningBorderHover": "rgba(255, 214, 102, 0.2)",
4711
- "colorError": "#FF4D4F",
4712
- "colorErrorHover": "rgba(165, 50, 48, 1)",
4713
- "colorErrorBg": "rgba(129, 46, 46, 0.25)",
4714
- "colorErrorBgHover": "rgba(129, 46, 46, 0.32)",
4715
- "colorErrorBorder": "rgba(255, 204, 199, 0.2)",
4716
- "colorErrorBorderHover": "rgba(255, 163, 158, 0.2)",
4717
- "colorLink": "#5551CC",
4718
- "boxShadow": "0px 4px 6px 0px rgba(255, 255, 255, 0.08)",
4719
- "boxShadowSecondary": "0px 12px 24px -16px rgba(255, 255, 255, 0.04),0px 8px 40px 0px rgba(255, 255, 255, 0.06),0px 0px 1px 0px rgba(255, 255, 255, 0.02)",
4720
-
4721
- "colorTextWhite": "#fff",
4722
- "colorTextOnPrimary": "#fff",
4723
- "colorFillDisable": "#8D8C98",
4724
- "colorPurple": "#5551CC",
4725
- "colorPurpleHover": "#8383F0",
4726
- "colorPurpleBg": "rgba(226, 222, 255, 0.2)",
4727
- "colorPink": "#EC4899",
4728
- "colorPinkHover": "#E494BC",
4729
- "colorPinkBg": "rgba(251, 220, 239, 0.2)",
4730
- "colorYellow": "#EAB308",
4731
- "colorYellowHover": "#DBBE62",
4732
- "colorYellowBg": "rgba(255, 250, 184, 0.2)",
4733
- "colorOrange": "#FA8125",
4734
- "colorOrangeHover": "#F7A25F",
4735
- "colorOrangeBg": "rgba(255, 232, 201, 0.2)",
4736
- "colorTeal": "#14B8A6",
4737
- "colorTealHover": "#7BC7BE",
4738
- "colorTealBg": "rgba(200, 244, 233, 0.2)",
4739
- "colorBlue": "#0090FF",
4740
- "colorBlueHover": "#83BFED",
4741
- "colorBlueBg": "rgba(194, 229, 255, 0.2)",
4742
- "colorMauve": "#8E8C99",
4743
- "colorMauveHover": "#BBB8CA",
4744
- "colorMauveBg": "rgba(239, 240, 243, 0.2)",
4745
- "colorSlate": "#2C3A50",
4746
- "colorSlateHover": "#354252",
4747
- "colorSlateBg": "#232B36",
4748
- "colorLavender": "#A77BFF",
4749
- "colorLavenderHover": "#BFA5F3",
4750
- "colorLavenderBg": "rgba(150, 143, 167, 0.48)",
4751
-
4752
- "boxShadowTertiary": "0px 12px 32px -16px rgba(255, 255, 255, 0.16),0px 12px 60px 0px rgba(255, 255, 255, 0.08),0px 0px 1px 0px rgba(255, 255, 255, 0.02)",
4753
- "boxShadowTertiaryLeft": "-12px 0px 32px -16px rgba(255, 255, 255, 0.16),-12px 0px 60px 0px rgba(255, 255, 255, 0.08),0px 0px 1px 0px rgba(255, 255, 255, 0.02);",
4754
- "boxShadowInput": "0px 12px 24px -16px rgba(255, 255, 255, 0.08),0px 12px 40px 0px rgba(255, 255, 255, 0.16),0px 0px 1px 0px rgba(255, 255, 255, 0.04)"
4755
- }
4756
-
4757
- ```
4758
-
4759
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: rgba(26, 26, 29, 1);"></span> carbonTheme</div>
4088
+ ### 1.0.21
4089
+ `2025-12-25`
4760
4090
 
4761
- ```json
4762
- {
4763
- "borderRadiusXS": 2,
4764
- "borderRadiusSM": 4,
4765
- "borderRadius": 6,
4766
- "borderRadiusLG": 8,
4767
- "borderRadiusXL": 12,
4768
- "borderRadiusFull": 999,
4769
- "wireframe": false,
4770
- "colorPrimaryBg": "rgba(244, 244, 247, 1)",
4771
- "colorPrimaryBgHover": "rgba(239, 239, 244, 1)",
4772
- "colorPrimaryBorder": "rgba(62, 63, 66, 1)",
4773
- "colorPrimaryBorderHover": "rgba(130, 132, 137, 1)",
4774
- "colorPrimaryHover": "rgba(38, 38, 41, 1)",
4775
- "colorPrimary": "rgba(26, 26, 29, 1)",
4776
- "colorPrimaryActive": "rgba(0, 0, 0, 1)",
4777
- "colorPrimaryTextHover": "rgba(38, 38, 41, 1)",
4778
- "colorPrimaryText": "rgba(26, 26, 29, 1)",
4779
- "colorPrimaryTextActive": "rgba(0, 0, 0, 1)",
4780
- "colorTextBase": "rgba(26, 26, 29, 1)",
4781
- "colorBgBase": "rgba(255, 255, 255, 1)",
4782
- "colorText": "rgba(26, 26, 29, 0.88)",
4783
- "colorTextSecondary": "rgba(26, 26, 29, 0.65)",
4784
- "colorTextTertiary": "rgba(26, 26, 29, 0.45)",
4785
- "colorTextQuaternary": "rgba(26, 26, 29, 0.25)",
4786
- "colorBorder": "rgba(187, 187, 193, 1)",
4787
- "colorBorderSecondary": "rgba(234, 234, 234, 1)",
4788
- "colorFill": "rgba(0, 0, 43, 0.06)",
4789
- "colorFillSecondary": "rgba(0, 0, 85, 0.03)",
4790
- "colorFillTertiary": "rgba(205, 208, 220, 0.15)",
4791
- "colorFillQuaternary": "rgba(205, 208, 220, 0.1)",
4792
- "colorBgContainer": "rgba(255, 255, 255, 1)",
4793
- "colorBgElevated": "rgba(255, 255, 255, 1)",
4794
- "colorBgLayout": "rgba(250, 250, 251, 1)",
4795
- "colorBgSpotlight": "rgba(26, 26, 29, 0.85)",
4796
- "colorBgMask": "rgba(0, 0, 0, 0.45)",
4797
- "colorInfo": "rgba(11, 131, 241, 1)",
4798
- "colorInfoHover": "rgba(94, 188, 255, 1)",
4799
- "colorInfoBorder": "rgba(135, 209, 255, 1)",
4800
- "colorInfoText": "rgba(11, 131, 241, 1)",
4801
- "colorInfoBg": "rgba(230, 247, 255, 1)",
4802
- "colorInfoBgHover": "rgba(176, 227, 255, 1)",
4803
- "colorInfoBorderHover": "rgba(94, 188, 255, 1)",
4804
- "colorSuccess": "rgba(91, 185, 139, 1)",
4805
- "colorSuccessHover": "rgba(171, 212, 190, 1)",
4806
- "colorSuccessBg": "rgba(235, 250, 240, 1)",
4807
- "colorSuccessBgHover": "rgba(223, 237, 228, 1)",
4808
- "colorSuccessBorder": "rgba(211, 224, 217, 1)",
4809
- "colorSuccessBorderHover": "rgba(171, 212, 190, 1)",
4810
- "colorWarning": "rgba(250, 173, 20, 1)",
4811
- "colorWarningHover": "rgba(255, 214, 102, 1)",
4812
- "colorWarningBg": "rgba(255, 251, 230, 1)",
4813
- "colorWarningBgHover": "rgba(255, 241, 184, 1)",
4814
- "colorWarningBorder": "rgba(255, 229, 143, 1)",
4815
- "colorWarningBorderHover": "rgba(255, 214, 102, 1)",
4816
- "colorError": "rgba(255, 77, 79, 1)",
4817
- "colorErrorHover": "rgba(255, 120, 117, 1)",
4818
- "colorErrorBg": "rgba(255, 242, 240, 1)",
4819
- "colorErrorBgHover": "rgba(255, 241, 240, 1)",
4820
- "colorErrorBorder": "rgba(255, 204, 199, 1)",
4821
- "colorErrorBorderHover": "rgba(255, 163, 158, 1)",
4822
- "colorLink": "rgba(0, 77, 255, 1)",
4823
- "boxShadow": "0px 4px 6px 0px rgba(0, 0, 0, 0.08)",
4824
- "boxShadowSecondary": "0px 12px 24px -16px rgba(0, 0, 0, 0.06),0px 8px 40px 0px rgba(0, 0, 0, 0.12),0px 0px 1px 0px rgba(0, 0, 0, 0.04)",
4825
-
4826
- "colorTextWhite": "#ffffff",
4827
- "colorTextOnPrimary": "#ffffff",
4828
- "colorFillDisable": "rgba(232, 232, 235, 1)",
4829
- "colorPurple": "rgba(97, 92, 237, 1)",
4830
- "colorPurpleHover": "#8080FF",
4831
- "colorPurpleBg": "rgba(226, 222, 255, 0.8)",
4832
- "colorPink": "rgba(236, 72, 153, 1)",
4833
- "colorPinkHover": "#E593BC",
4834
- "colorPinkBg": "rgba(251, 220, 239, 0.8)",
4835
- "colorYellow": "rgba(234, 179, 8, 1)",
4836
- "colorYellowHover": "#F1D372",
4837
- "colorYellowBg": "rgba(255, 250, 184, 0.8)",
4838
- "colorOrange": "rgba(250, 129, 37, 1)",
4839
- "colorOrangeHover": "#E88C45",
4840
- "colorOrangeBg": "rgba(255, 232, 201, 0.8)",
4841
- "colorTeal": "rgba(20, 184, 166, 1)",
4842
- "colorTealHover": "#5FB3A9",
4843
- "colorTealBg": "rgba(200, 244, 233, 0.8)",
4844
- "colorBlue": "rgba(0, 144, 255, 1)",
4845
- "colorBlueHover": "#72BCF5",
4846
- "colorBlueBg": "rgba(194, 229, 255, 0.8)",
4847
- "colorMauve": "rgba(142, 140, 153, 1)",
4848
- "colorMauveHover": "#C0BFC8",
4849
- "colorMauveBg": "rgba(239, 240, 243, 0.8)",
4850
- "colorSlate": "#2C3A50",
4851
- "colorSlateHover": "#354252",
4852
- "colorSlateBg": "#232B36",
4853
- "boxShadowTertiary": "0px 12px 32px -16px rgba(0, 0, 0, 0.24),0px 12px 60px 0px rgba(0, 0, 0, 0.12),0px 0px 1px 0px rgba(0, 0, 0, 0.04)",
4854
- "boxShadowTertiaryLeft": "-12px 0px 32px -16px rgba(0, 0, 0, 0.24),-12px 0px 60px 0px rgba(0, 0, 0, 0.12),0px 0px 1px 0px rgba(0, 0, 0, 0.04)",
4855
- "boxShadowInput": "0px 12px 24px -16px rgba(54, 54, 73, 0.04),0px 12px 40px 0px rgba(51, 51, 71, 0.08),0px 0px 1px 0px rgba(44, 44, 54, 0.02)"
4856
- }
4091
+ ##### Changed
4857
4092
 
4858
- ```
4093
+ - AlertDialog 组件:定位距离顶部的默认高度调整为当前窗口高度的 36%
4094
+ - Table 组件:表格行 hover 背景色修改为 `color-bg-layout` 颜色变量;表格行选中背景色修改为 `color-primary-bg-hover` 颜色变量
4095
+ - Select 组件:多选模式的选中项背景色调整
4096
+ - 主题色变量更新:,
4097
+ - bailianDarkTheme:添加 `"colorLinkHover": "#857DE3"`
4098
+ - bailianTheme:添加 `"colorLinkHover": "#8080FF"`
4099
+ - carbonDarkTheme:修改 `"colorTextOnPrimary": "#ffffff"`
4859
4100
 
4860
- <div><span style="display: inline-block; width: 12px; height: 12px; background-color: rgba(26, 26, 29, 1);"></span> carbonDarkTheme</div>
4101
+ ##### Fixed
4861
4102
 
4862
- ```json
4863
- {
4864
- "borderRadiusXS": 2,
4865
- "borderRadiusSM": 4,
4866
- "borderRadius": 6,
4867
- "borderRadiusLG": 8,
4868
- "borderRadiusXL": 12,
4869
- "borderRadiusFull": 999,
4870
- "wireframe": false,
4871
- "colorPrimaryBg": "#181818",
4872
- "colorPrimaryBgHover": "#2E2E2E",
4873
- "colorPrimaryBorder": "#323232",
4874
- "colorPrimaryBorderHover": "#2C2C2C",
4875
- "colorPrimaryHover": "#DFDFDF",
4876
- "colorPrimary": "#E4E4E4",
4877
- "colorPrimaryActive": "#7E7E7E",
4878
- "colorPrimaryTextHover": "#909090",
4879
- "colorPrimaryText": "#676767",
4880
- "colorPrimaryTextActive": "#959595",
4881
- "colorTextBase": "#E7E7ED",
4882
- "colorBgBase": "#0A0A0B",
4883
- "colorText": "#E7E7EDC7",
4884
- "colorTextSecondary": "#E7E7EDA6",
4885
- "colorTextTertiary": "#E7E7ED73",
4886
- "colorTextQuaternary": "#E7E7ED40",
4887
- "colorBorder": "#5B5B5BCC",
4888
- "colorBorderSecondary": "#323232CC",
4889
- "colorFill": "#E7E7ED2E",
4890
- "colorFillSecondary": "#E7E7ED1F",
4891
- "colorFillTertiary": "#E7E7ED14",
4892
- "colorFillQuaternary": "#E7E7ED0A",
4893
- "colorBgContainer": "#121212",
4894
- "colorBgElevated": "#212121",
4895
- "colorBgLayout": "#141414",
4896
- "colorBgSpotlight": "#525252D9",
4897
- "colorBgMask": "#050508CC",
4898
- "colorInfo": "#0B83F1",
4899
- "colorInfoHover": "#5EBCFF",
4900
- "colorInfoBorder": "#3990C9",
4901
- "colorInfoText": "#0B83F1",
4902
- "colorInfoBg": "#112233",
4903
- "colorInfoBgHover": "#264866",
4904
- "colorInfoBorderHover": "#5EBCFF",
4905
- "colorSuccess": "#5BB98B",
4906
- "colorSuccessHover": "#74A47C",
4907
- "colorSuccessBg": "#293631",
4908
- "colorSuccessBgHover": "#3F5147",
4909
- "colorSuccessBorder": "#73A377",
4910
- "colorSuccessBorderHover": "#ABD4BE",
4911
- "colorWarning": "#FAAD14",
4912
- "colorWarningHover": "#FF8C28",
4913
- "colorWarningBg": "#2D231A",
4914
- "colorWarningBgHover": "#4D3B23",
4915
- "colorWarningBorder": "#FFA628",
4916
- "colorWarningBorderHover": "#FFD666",
4917
- "colorError": "#FF4D4F",
4918
- "colorErrorHover": "#EE654E",
4919
- "colorErrorBg": "#2B0B08",
4920
- "colorErrorBgHover": "#4A2A28",
4921
- "colorErrorBorder": "#EE5B4E",
4922
- "colorErrorBorderHover": "#FFA39E",
4923
- "colorLink": "#4D7DFF",
4924
- "boxShadow": "0px 4px 6px 0px rgba(255, 255, 255, 0.08)",
4925
- "boxShadowSecondary": "0px 12px 24px -16px rgba(255, 255, 255, 0.06),0px 8px 40px 0px rgba(255, 255, 255, 0.12),0px 0px 1px 0px rgba(255, 255, 255, 0.04)",
4926
-
4927
- "colorTextWhite": "#ffffff",
4928
- "colorTextOnPrimary": "#000000",
4929
- "colorFillDisable": "#898989",
4930
- "colorPurple": "#615CED",
4931
- "colorPurpleHover": "#8383F0",
4932
- "colorPurpleBg": "#6964877A",
4933
- "colorPink": "#EC4899",
4934
- "colorPinkHover": "#E494BC",
4935
- "colorPinkBg": "#53424D7A",
4936
- "colorYellow": "#EAB308",
4937
- "colorYellowHover": "#DBBE62",
4938
- "colorYellowBg": "#9585527A",
4939
- "colorOrange": "#FA8125",
4940
- "colorOrangeHover": "#F7A25F",
4941
- "colorOrangeBg": "#6F58417A",
4942
- "colorTeal": "#14B8A6",
4943
- "colorTealHover": "#7BC7BE",
4944
- "colorTealBg": "#4658547A",
4945
- "colorBlue": "#0090FF",
4946
- "colorBlueHover": "#83BFED",
4947
- "colorBlueBg": "#5E76897A",
4948
- "colorMauve": "#8E8C99",
4949
- "colorMauveHover": "#BBB8CA",
4950
- "colorMauveBg": "#5859647A",
4951
- "colorSlate": "#2C3A50",
4952
- "colorSlateHover": "#354252",
4953
- "colorSlateBg": "#232B36",
4954
- "colorLavender": "#A77BFF",
4955
- "colorLavenderHover": "#BFA5F3",
4956
- "colorLavenderBg": "rgba(150, 143, 167, 0.48)",
4957
-
4958
- "boxShadowTertiary": "0px 12px 32px -16px rgba(255, 255, 255, 0.24),0px 12px 60px 0px rgba(255, 255, 255, 0.12),0px 0px 1px 0px rgba(255, 255, 255, 0.04)",
4959
- "boxShadowTertiaryLeft": "-12px 0px 32px -16px rgba(255, 255, 255, 0.24),-12px 0px 60px 0px rgba(255, 255, 255, 0.12),0px 0px 1px 0px rgba(255, 255, 255, 0.04)",
4960
- "boxShadowInput": "0px 12px 24px -16px rgba(255, 255, 255, 0.08),0px 12px 40px 0px rgba(255, 255, 255, 0.16),0px 0px 1px 0px rgba(255, 255, 255, 0.04)",
4961
- "colorTextBlack": "#000000"
4962
- }
4963
- ```
4964
-
4965
- # CSS 变量
4966
-
4967
- Spark Design 默认启用 cssVar 模式,因此您可以利用 从 token 派生出的 CSS 变量来构建自己的样式。
4968
-
4969
-
4970
- ```less
4971
- .example {
4972
- background: var(--sps-color-bg-base);
4973
- color: var(--sps-color-pink);
4974
- }
4975
- // 提示:您可以将 'sps' 替换为您自己的前缀
4976
- ```
4103
+ - Slider 组件:水平滑动条组件取消默认左右两边的外边距 margin,操作按钮 handle 在最左侧与最右侧不超出滑动轨道宽度