x-next 1.17.0 → 1.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AI_USAGE/catalog.md +1 -1
- package/AI_USAGE/components/alert-api.md +1 -1
- package/AI_USAGE/components/alert.md +33 -1
- package/AI_USAGE/components/bar-chart-api.md +1 -1
- package/AI_USAGE/components/bar-chart.md +1 -1
- package/AI_USAGE/components/boxicons.md +1 -1
- package/AI_USAGE/components/button-api.md +13 -16
- package/AI_USAGE/components/button.md +242 -31
- package/AI_USAGE/components/charts.md +1 -1
- package/AI_USAGE/components/checkbox-api.md +1 -1
- package/AI_USAGE/components/checkbox.md +1 -1
- package/AI_USAGE/components/color-picker-api.md +1 -1
- package/AI_USAGE/components/color-picker.md +1 -1
- package/AI_USAGE/components/config-provider-api.md +1 -1
- package/AI_USAGE/components/config-provider.md +1 -1
- package/AI_USAGE/components/date-picker-api.md +1 -1
- package/AI_USAGE/components/date-picker.md +1 -1
- package/AI_USAGE/components/dialog-api.md +1 -1
- package/AI_USAGE/components/dialog.md +1 -1
- package/AI_USAGE/components/draggable-api.md +1 -1
- package/AI_USAGE/components/draggable.md +1 -1
- package/AI_USAGE/components/drawer-api.md +3 -3
- package/AI_USAGE/components/drawer.md +1 -1
- package/AI_USAGE/components/dropdown-api.md +3 -3
- package/AI_USAGE/components/dropdown.md +1 -1
- package/AI_USAGE/components/empty-api.md +1 -1
- package/AI_USAGE/components/empty.md +1 -1
- package/AI_USAGE/components/finicon.md +1 -1
- package/AI_USAGE/components/form-api.md +1 -1
- package/AI_USAGE/components/form.md +1 -1
- package/AI_USAGE/components/grid-api.md +1 -1
- package/AI_USAGE/components/grid.md +1 -1
- package/AI_USAGE/components/heatmap-api.md +1 -1
- package/AI_USAGE/components/heatmap.md +1 -1
- package/AI_USAGE/components/icon-api.md +1 -1
- package/AI_USAGE/components/icon.md +1 -1
- package/AI_USAGE/components/image-api.md +1 -1
- package/AI_USAGE/components/image.md +1 -1
- package/AI_USAGE/components/input-api.md +2 -2
- package/AI_USAGE/components/input-number-api.md +1 -1
- package/AI_USAGE/components/input-number.md +1 -1
- package/AI_USAGE/components/input-tag-api.md +1 -1
- package/AI_USAGE/components/input-tag.md +1 -1
- package/AI_USAGE/components/input.md +1 -1
- package/AI_USAGE/components/layout-api.md +1 -1
- package/AI_USAGE/components/layout.md +1 -1
- package/AI_USAGE/components/line-chart-api.md +1 -1
- package/AI_USAGE/components/line-chart.md +1 -1
- package/AI_USAGE/components/link-api.md +1 -1
- package/AI_USAGE/components/link.md +1 -1
- package/AI_USAGE/components/menu-api.md +1 -1
- package/AI_USAGE/components/menu.md +1 -1
- package/AI_USAGE/components/message-api.md +1 -1
- package/AI_USAGE/components/message-box-api.md +1 -1
- package/AI_USAGE/components/message-box.md +1 -1
- package/AI_USAGE/components/message.md +1 -1
- package/AI_USAGE/components/network-api.md +1 -1
- package/AI_USAGE/components/network.md +1 -1
- package/AI_USAGE/components/notification-api.md +1 -1
- package/AI_USAGE/components/notification.md +1 -1
- package/AI_USAGE/components/pagination-api.md +1 -1
- package/AI_USAGE/components/pagination.md +1 -1
- package/AI_USAGE/components/pie-chart-api.md +1 -1
- package/AI_USAGE/components/pie-chart.md +1 -1
- package/AI_USAGE/components/popconfirm-api.md +3 -3
- package/AI_USAGE/components/popconfirm.md +1 -1
- package/AI_USAGE/components/popover-api.md +1 -1
- package/AI_USAGE/components/popover.md +1 -1
- package/AI_USAGE/components/popup-api.md +1 -1
- package/AI_USAGE/components/popup.md +1 -1
- package/AI_USAGE/components/progress-api.md +1 -1
- package/AI_USAGE/components/progress.md +1 -1
- package/AI_USAGE/components/radio-api.md +1 -1
- package/AI_USAGE/components/radio.md +1 -1
- package/AI_USAGE/components/rate-api.md +1 -1
- package/AI_USAGE/components/rate.md +1 -1
- package/AI_USAGE/components/resize-box-api.md +1 -1
- package/AI_USAGE/components/resize-box.md +1 -1
- package/AI_USAGE/components/scrollbar-api.md +1 -1
- package/AI_USAGE/components/scrollbar.md +1 -1
- package/AI_USAGE/components/select-api.md +1 -1
- package/AI_USAGE/components/select.md +1 -1
- package/AI_USAGE/components/skeleton-api.md +1 -1
- package/AI_USAGE/components/skeleton.md +1 -1
- package/AI_USAGE/components/slider-api.md +1 -1
- package/AI_USAGE/components/slider.md +1 -1
- package/AI_USAGE/components/space-api.md +1 -1
- package/AI_USAGE/components/space.md +1 -1
- package/AI_USAGE/components/spin-api.md +1 -1
- package/AI_USAGE/components/spin.md +1 -1
- package/AI_USAGE/components/steps-api.md +1 -1
- package/AI_USAGE/components/steps.md +1 -1
- package/AI_USAGE/components/switch-api.md +1 -1
- package/AI_USAGE/components/switch.md +1 -1
- package/AI_USAGE/components/table-api.md +1 -1
- package/AI_USAGE/components/table.md +1 -1
- package/AI_USAGE/components/tabs-api.md +1 -1
- package/AI_USAGE/components/tabs.md +1 -1
- package/AI_USAGE/components/tag-api.md +1 -1
- package/AI_USAGE/components/tag.md +1 -1
- package/AI_USAGE/components/textarea-api.md +1 -1
- package/AI_USAGE/components/textarea.md +1 -1
- package/AI_USAGE/components/time-picker-api.md +1 -1
- package/AI_USAGE/components/time-picker.md +1 -1
- package/AI_USAGE/components/time-range-selector-api.md +1 -1
- package/AI_USAGE/components/time-range-selector.md +1 -1
- package/AI_USAGE/components/timeline-api.md +3 -3
- package/AI_USAGE/components/timeline.md +1 -1
- package/AI_USAGE/components/tooltip-api.md +1 -1
- package/AI_USAGE/components/tooltip.md +1 -1
- package/AI_USAGE/components/transfer-api.md +1 -1
- package/AI_USAGE/components/transfer.md +1 -1
- package/AI_USAGE/components/tree-select-api.md +1 -1
- package/AI_USAGE/components/tree-select.md +1 -1
- package/AI_USAGE/components/trend-chart-api.md +1 -1
- package/AI_USAGE/components/trend-chart.md +1 -1
- package/AI_USAGE/components/trigger-api.md +1 -1
- package/AI_USAGE/components/trigger.md +1 -1
- package/AI_USAGE/components/upload-api.md +1 -1
- package/AI_USAGE/components/upload.md +1 -1
- package/AI_USAGE/components/watermark-api.md +1 -1
- package/AI_USAGE/components/watermark.md +1 -1
- package/AI_USAGE/core.md +1 -1
- package/AI_USAGE/index.md +1 -1
- package/AI_USAGE/recipes/form-on-demand.md +1 -1
- package/AI_USAGE.md +296 -56
- package/CHANGELOG.md +20 -0
- package/dist/_styles/palette-aliases.d.ts +1 -0
- package/dist/components/button/Button.d.ts +0 -9
- package/dist/components/button/appearance.d.ts +7 -0
- package/dist/components/button/index.d.ts +0 -16
- package/dist/components/button/props.d.ts +2 -6
- package/dist/components/color-picker/panel.d.ts +0 -9
- package/dist/components/date-picker/DatePicker.vue.d.ts +0 -15
- package/dist/components/date-picker/index.d.ts +0 -30
- package/dist/components/drawer/index.d.ts +0 -30
- package/dist/components/drawer/src/Drawer.vue.d.ts +0 -15
- package/dist/components/dropdown/DropdownButton.vue.d.ts +0 -15
- package/dist/components/dropdown/index.d.ts +0 -30
- package/dist/components/popconfirm/src/popup.vue.d.ts +0 -15
- package/dist/components/time-picker/TimePanel.vue.d.ts +0 -15
- package/dist/components/time-picker/TimePicker.vue.d.ts +0 -15
- package/dist/components/time-picker/index.d.ts +0 -30
- package/dist/es/_styles/palette-aliases.js +102 -17
- package/dist/es/_utils/palette.js +54 -54
- package/dist/es/components/button/Button.js +77 -49
- package/dist/es/components/button/appearance.js +7 -0
- package/dist/es/components/button/props.js +0 -4
- package/dist/es/directives/wave.js +14 -8
- package/dist/es/style.css +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.umd.js +3 -3
- package/dist/style/alert.css +1 -1
- package/dist/style/base.css +1 -1
- package/dist/style/button.css +1 -1
- package/dist/style/color-picker.css +1 -1
- package/dist/style/link.css +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!-- Generated by pnpm generate:ai-usage. Edit script/ai-usage/content.md and script/ai-usage/. -->
|
|
2
2
|
# Watermark AI 使用
|
|
3
3
|
|
|
4
|
-
适用版本:x-next@1.
|
|
4
|
+
适用版本:x-next@1.18.0;来源指纹:`a0432ebab3728998205092a9a7e188702b81ff8c0550430bc02ff73b265af282`。
|
|
5
5
|
|
|
6
6
|
先读 [通用接入](../core.md)。公开导出:`Watermark`;主要模型:无。完整 Props、Events、Slots、实例方法与服务签名见 [本地 API](./watermark-api.md),包含本组件族全部子组件和别名。
|
|
7
7
|
|
package/AI_USAGE/core.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!-- Generated by pnpm generate:ai-usage. Edit script/ai-usage/content.md and script/ai-usage/. -->
|
|
2
2
|
# x-next AI 通用接入
|
|
3
3
|
|
|
4
|
-
适用版本:x-next@1.
|
|
4
|
+
适用版本:x-next@1.18.0;来源指纹:`a0432ebab3728998205092a9a7e188702b81ff8c0550430bc02ff73b265af282`。
|
|
5
5
|
|
|
6
6
|
```sh
|
|
7
7
|
npm install x-next
|
package/AI_USAGE/index.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!-- Generated by pnpm generate:ai-usage. Edit script/ai-usage/content.md and script/ai-usage/. -->
|
|
2
2
|
# x-next AI 按需入口
|
|
3
3
|
|
|
4
|
-
适用版本:x-next@1.
|
|
4
|
+
适用版本:x-next@1.18.0;来源指纹:`a0432ebab3728998205092a9a7e188702b81ff8c0550430bc02ff73b265af282`。
|
|
5
5
|
|
|
6
6
|
AI 专用资料,与文档站独立分发。先读 [core.md](./core.md),再只读本任务需要的组件页;各页含场景 SFC,完整 API 位于对应 `*-api.md`。全部公开组件与服务有本地导航,查本包用法优先包内文件,不默认网络搜索。
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<!-- Generated by pnpm generate:ai-usage. Edit script/ai-usage/content.md and script/ai-usage/. -->
|
|
2
2
|
# 按需样式与表单接入
|
|
3
3
|
|
|
4
|
-
适用版本:x-next@1.
|
|
4
|
+
适用版本:x-next@1.18.0;来源指纹:`a0432ebab3728998205092a9a7e188702b81ff8c0550430bc02ff73b265af282`。
|
|
5
5
|
|
|
6
6
|
先读 [通用接入](../core.md),相关组件规则:[config-provider](../components/config-provider.md)、[input](../components/input.md)、[textarea](../components/textarea.md)、[select](../components/select.md)、[checkbox](../components/checkbox.md)。
|
|
7
7
|
|
package/AI_USAGE.md
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
<!-- Generated by pnpm generate:ai-usage. Edit script/ai-usage/content.md and script/ai-usage/. -->
|
|
2
2
|
# x-next AI 使用手册
|
|
3
3
|
|
|
4
|
-
适用版本:**x-next@1.
|
|
4
|
+
适用版本:**x-next@1.18.0**。Vue:`^3.5.0`;Node:`>=20.19.0`。
|
|
5
5
|
|
|
6
|
-
来源指纹(AI 行为说明、docs 导入快照、映射、样式依赖、版本、公开类型和 API 参考):`
|
|
6
|
+
来源指纹(AI 行为说明、docs 导入快照、映射、样式依赖、版本、公开类型和 API 参考):`a0432ebab3728998205092a9a7e188702b81ff8c0550430bc02ff73b265af282`。
|
|
7
7
|
|
|
8
8
|
覆盖 59 个组件族与 106 个公开组件/服务导出。优先通过 [本地按需索引](./AI_USAGE/index.md) 读取组件页和 API,不为查本包用法默认搜索网络。
|
|
9
9
|
|
|
@@ -226,7 +226,7 @@ const pickerAttrs = { id: 'brand-color', 'aria-label': '品牌色' };
|
|
|
226
226
|
|
|
227
227
|
## Button
|
|
228
228
|
|
|
229
|
-
[组件文档与 live demo](https://x-next.yjmf.com/components/button)。`type`
|
|
229
|
+
[组件文档与 live demo](https://x-next.yjmf.com/components/button)。`type` 管形态,默认 `'default'`;实心用 `'solid'`、弱底用 `'subtle'`、透明用 `'outline'/'dashed'/'text'`。`status` 管颜色,默认中性 `'default'`,品牌色显式 `'primary'`。默认与中性 outline 是同一普通操作层级的弱底 / 透明表面差异;品牌描边显式使用 status=primary。兼容 `type='primary'` 解析品牌实心,其他语义 status 优先;`plain` 仅把填充形态转为 subtle,`border=false` 只隐藏边框;语义弱底不额外描边,中性默认保留细边,outline/dashed 需要边框。波纹颜色跟随状态;text、disabled/loading 无外部波纹。深灰实心是独立纯灰的高权重进阶组合,不代表次要或禁用。text 保留按钮点击区域,`type="text" narrow` 去掉水平内边距且保持按钮高度;URL 导航用 Link 的 href 或项目路由方案。Button 不提供 link 类型或布尔 link 属性。`htmlType` 默认 `'button'`,原生提交用 `'submit'`。尺寸优先级为显式 `size` → ButtonGroup → ConfigProvider → `'medium'`;Button 不通过 FormItem 继承尺寸。`disabled` / `loading` 默认关闭。
|
|
230
230
|
|
|
231
231
|
`click` 载荷为 `MouseEvent`,禁用或加载中不会触发。`default`、`prefix`、`suffix`、`icon` 插槽可组合内容;异步业务自行维护 `loading`。
|
|
232
232
|
|
|
@@ -1576,14 +1576,141 @@ import { Button } from 'x-next';
|
|
|
1576
1576
|
<template>
|
|
1577
1577
|
<Button>默认按钮</Button>
|
|
1578
1578
|
<Button type="primary">主要按钮</Button>
|
|
1579
|
-
<Button type="outline"
|
|
1579
|
+
<Button type="outline" status="primary">品牌描边</Button>
|
|
1580
1580
|
<Button type="text">文本按钮</Button>
|
|
1581
1581
|
</template>
|
|
1582
1582
|
```
|
|
1583
1583
|
|
|
1584
|
+
### 形态与颜色
|
|
1585
|
+
|
|
1586
|
+
通过 `type` 设置形态,通过 `status` 设置颜色。品牌色使用 `status="primary"`。
|
|
1587
|
+
|
|
1588
|
+
| 形态 | 表现 |
|
|
1589
|
+
| --- | --- |
|
|
1590
|
+
| default | 浅色背景;中性按钮有细边框,状态色按钮无边框 |
|
|
1591
|
+
| solid | 实心底、白字 |
|
|
1592
|
+
| subtle | 弱填充、无可见边框 |
|
|
1593
|
+
| outline / dashed | 透明底、实线 / 虚线边框 |
|
|
1594
|
+
| text | 透明文字,保留按钮尺寸与内边距 |
|
|
1595
|
+
|
|
1596
|
+
### 文本动作与跳转链接
|
|
1597
|
+
|
|
1598
|
+
`type="text"` 适合表格或工具栏操作,加上 `narrow` 可去掉水平内边距。跳转页面使用 `x-link` 的 `href`。
|
|
1599
|
+
|
|
1600
|
+
### 进阶组合:深灰实心
|
|
1601
|
+
|
|
1602
|
+
深灰实心适合黑白品牌或强调操作;次要操作可使用默认或文本按钮。
|
|
1603
|
+
|
|
1604
|
+
### 组合预览
|
|
1605
|
+
|
|
1606
|
+
```vue
|
|
1607
|
+
<script setup lang="ts">
|
|
1608
|
+
import 'x-next/style.css';
|
|
1609
|
+
import { Button } from 'x-next';
|
|
1610
|
+
|
|
1611
|
+
</script>
|
|
1612
|
+
<template>
|
|
1613
|
+
<Button type="solid" status="primary">品牌实心</Button>
|
|
1614
|
+
<Button type="subtle" status="primary">品牌弱底</Button>
|
|
1615
|
+
<Button type="outline" status="primary">品牌描边</Button>
|
|
1616
|
+
<Button type="text" status="primary">品牌文本</Button>
|
|
1617
|
+
</template>
|
|
1618
|
+
```
|
|
1619
|
+
|
|
1620
|
+
```vue
|
|
1621
|
+
<script setup lang="ts">
|
|
1622
|
+
import 'x-next/style.css';
|
|
1623
|
+
import { ref } from 'vue';
|
|
1624
|
+
import { Button as XButton, Link as XLink } from 'x-next';
|
|
1625
|
+
import 'x-next/style/button';
|
|
1626
|
+
import 'x-next/style/link';
|
|
1627
|
+
const textCount = ref(0);
|
|
1628
|
+
const compactCount = ref(0);
|
|
1629
|
+
</script>
|
|
1630
|
+
<template>
|
|
1631
|
+
<XButton type="text" status="primary" @click="textCount++">文本操作</XButton>
|
|
1632
|
+
<span>行内动作:<XButton type="text" narrow status="primary" @click="compactCount++">紧凑文本操作</XButton></span>
|
|
1633
|
+
<XLink href="/components/link" :hoverable="false">查看 Link 文档</XLink>
|
|
1634
|
+
<span role="status">文本操作 {{ textCount }} 次,紧凑操作 {{ compactCount }} 次</span>
|
|
1635
|
+
</template>
|
|
1636
|
+
```
|
|
1637
|
+
|
|
1638
|
+
```vue
|
|
1639
|
+
<script setup lang="ts">
|
|
1640
|
+
import 'x-next/style.css';
|
|
1641
|
+
import { Button } from 'x-next';
|
|
1642
|
+
|
|
1643
|
+
</script>
|
|
1644
|
+
<template>
|
|
1645
|
+
<Button type="solid">深灰实心</Button>
|
|
1646
|
+
</template>
|
|
1647
|
+
```
|
|
1648
|
+
|
|
1649
|
+
```vue
|
|
1650
|
+
<script setup lang="ts">
|
|
1651
|
+
import 'x-next/style.css';
|
|
1652
|
+
import { ref } from 'vue';
|
|
1653
|
+
import { Button as XButton, ButtonGroup as XButtonGroup, Select as XSelect, Checkbox as XCheckbox } from 'x-next';
|
|
1654
|
+
import type { ButtonTypes, ButtonStatus } from 'x-next';
|
|
1655
|
+
import 'x-next/style/button';
|
|
1656
|
+
import 'x-next/style/form-select';
|
|
1657
|
+
import 'x-next/style/form-checkbox';
|
|
1658
|
+
const types = ['default', 'solid', 'subtle', 'outline', 'dashed', 'text', 'primary'] as const;
|
|
1659
|
+
const statuses = ['default', 'primary', 'success', 'warning', 'strong', 'danger', 'info'] as const;
|
|
1660
|
+
const typeOptions = types.map(value => ({ label: value, value }));
|
|
1661
|
+
const statusOptions = statuses.map(value => ({ label: value, value }));
|
|
1662
|
+
const typeAttrs = { 'aria-label': '按钮形态' };
|
|
1663
|
+
const statusAttrs = { 'aria-label': '按钮颜色' };
|
|
1664
|
+
const type = ref<ButtonTypes>('outline');
|
|
1665
|
+
const status = ref<ButtonStatus>('default');
|
|
1666
|
+
const plain = ref(false), border = ref(true), count = ref(0);
|
|
1667
|
+
</script>
|
|
1668
|
+
<template>
|
|
1669
|
+
<div class="button-controls">
|
|
1670
|
+
<div class="button-field">
|
|
1671
|
+
<span>形态</span>
|
|
1672
|
+
<XSelect v-model="type" :options="typeOptions" v-bind="typeAttrs" class="button-select" />
|
|
1673
|
+
</div>
|
|
1674
|
+
<div class="button-field">
|
|
1675
|
+
<span>颜色</span>
|
|
1676
|
+
<XSelect v-model="status" :options="statusOptions" v-bind="statusAttrs" class="button-select" />
|
|
1677
|
+
</div>
|
|
1678
|
+
<XCheckbox v-model="plain">plain</XCheckbox>
|
|
1679
|
+
<XCheckbox v-model="border">border</XCheckbox>
|
|
1680
|
+
</div>
|
|
1681
|
+
<XButton :type="type" :status="status" :plain="plain" :border="border" @click="count++">组合按钮</XButton>
|
|
1682
|
+
<span role="status">已触发 {{ count }} 次</span>
|
|
1683
|
+
<XButtonGroup type="outline">
|
|
1684
|
+
<XButton :border="false">组内无边框一</XButton>
|
|
1685
|
+
<XButton :border="false">组内无边框二</XButton>
|
|
1686
|
+
</XButtonGroup>
|
|
1687
|
+
</template>
|
|
1688
|
+
<style scoped>
|
|
1689
|
+
.button-controls {
|
|
1690
|
+
display: flex;
|
|
1691
|
+
flex-wrap: wrap;
|
|
1692
|
+
align-items: center;
|
|
1693
|
+
gap: 12px;
|
|
1694
|
+
}
|
|
1695
|
+
.button-field {
|
|
1696
|
+
display: flex;
|
|
1697
|
+
align-items: center;
|
|
1698
|
+
gap: 8px;
|
|
1699
|
+
flex: none;
|
|
1700
|
+
}
|
|
1701
|
+
.button-field > span {
|
|
1702
|
+
white-space: nowrap;
|
|
1703
|
+
}
|
|
1704
|
+
.button-field :deep(.button-select) {
|
|
1705
|
+
width: 136px;
|
|
1706
|
+
flex: none;
|
|
1707
|
+
}
|
|
1708
|
+
</style>
|
|
1709
|
+
```
|
|
1710
|
+
|
|
1584
1711
|
### 外部水波纹
|
|
1585
1712
|
|
|
1586
|
-
|
|
1713
|
+
点击按钮查看反馈。禁用、加载或文本按钮不显示水波纹。
|
|
1587
1714
|
|
|
1588
1715
|
```vue
|
|
1589
1716
|
<script setup lang="ts">
|
|
@@ -1595,6 +1722,7 @@ import { Button } from 'x-next';
|
|
|
1595
1722
|
<Button>默认水波纹</Button>
|
|
1596
1723
|
<Button type="primary">主要水波纹</Button>
|
|
1597
1724
|
<Button status="danger">危险水波纹</Button>
|
|
1725
|
+
<Button type="outline" status="danger">危险描边水波纹</Button>
|
|
1598
1726
|
<Button loading>加载不触发</Button>
|
|
1599
1727
|
<Button disabled>禁用不触发</Button>
|
|
1600
1728
|
</template>
|
|
@@ -1602,6 +1730,8 @@ import { Button } from 'x-next';
|
|
|
1602
1730
|
|
|
1603
1731
|
### 状态
|
|
1604
1732
|
|
|
1733
|
+
通过 `status` 表达成功、警告、危险等状态。
|
|
1734
|
+
|
|
1605
1735
|
```vue
|
|
1606
1736
|
<script setup lang="ts">
|
|
1607
1737
|
import 'x-next/style.css';
|
|
@@ -1619,15 +1749,45 @@ import { Button } from 'x-next';
|
|
|
1619
1749
|
</template>
|
|
1620
1750
|
```
|
|
1621
1751
|
|
|
1622
|
-
###
|
|
1752
|
+
### 暗色状态按钮
|
|
1753
|
+
|
|
1754
|
+
通过 `ConfigProvider` 的 `dark` 属性设置局部暗色。
|
|
1623
1755
|
|
|
1624
|
-
|
|
1756
|
+
```vue
|
|
1757
|
+
<script setup lang="ts">
|
|
1758
|
+
import 'x-next/style.css';
|
|
1759
|
+
import { Button as XButton, ConfigProvider as XConfigProvider } from 'x-next';
|
|
1760
|
+
import 'x-next/style/base.css';
|
|
1761
|
+
import 'x-next/style/button.css';
|
|
1762
|
+
</script>
|
|
1763
|
+
<template>
|
|
1764
|
+
<XConfigProvider :dark="true" class="button-dark-example">
|
|
1765
|
+
<XButton>默认</XButton>
|
|
1766
|
+
<XButton status="success">成功</XButton>
|
|
1767
|
+
<XButton status="warning">警告</XButton>
|
|
1768
|
+
<XButton status="strong">强调</XButton>
|
|
1769
|
+
<XButton status="danger">危险</XButton>
|
|
1770
|
+
<XButton status="info">信息</XButton>
|
|
1771
|
+
<XButton disabled>禁用</XButton>
|
|
1772
|
+
</XConfigProvider>
|
|
1773
|
+
</template>
|
|
1774
|
+
<style scoped>
|
|
1775
|
+
.button-dark-example {
|
|
1776
|
+
display: flex;
|
|
1777
|
+
flex-wrap: wrap;
|
|
1778
|
+
gap: 12px;
|
|
1779
|
+
padding: 20px;
|
|
1780
|
+
border-radius: 8px;
|
|
1781
|
+
background: var(--x-color-bg-surface);
|
|
1782
|
+
}
|
|
1783
|
+
</style>
|
|
1784
|
+
```
|
|
1625
1785
|
|
|
1626
|
-
|
|
1786
|
+
### 状态色实心按钮
|
|
1627
1787
|
|
|
1628
|
-
|
|
1788
|
+
实心按钮适合强调操作,搭配 `status` 设置颜色。
|
|
1629
1789
|
|
|
1630
|
-
|
|
1790
|
+
黄色、橙色实心按钮的文字对比较弱,需要更高可读性时可选用描边或弱底形态。
|
|
1631
1791
|
|
|
1632
1792
|
```vue
|
|
1633
1793
|
<script setup lang="ts">
|
|
@@ -1646,25 +1806,11 @@ import { Button } from 'x-next';
|
|
|
1646
1806
|
|
|
1647
1807
|
### 类型与边框
|
|
1648
1808
|
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
`link` 保持透明背景和对应状态文字色,非圆形链接按钮的高度随文字行高变化、没有水平内边距。禁用和加载期间不会响应悬浮或按下颜色。
|
|
1809
|
+
`:border="false"` 只隐藏边框。需要弱底危险按钮时使用 `type="subtle" status="danger"`,实心危险按钮使用 `type="solid" status="danger"`。
|
|
1652
1810
|
|
|
1653
|
-
|
|
1811
|
+
### 交互状态
|
|
1654
1812
|
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
按钮的常态、悬浮、按下按**渐深梯度**设计,每一级都可感知且保持轻盈(明度差 ≥ 0.025,由门禁守护):
|
|
1658
|
-
|
|
1659
|
-
| 形态 | 常态 | 悬浮 | 按下 |
|
|
1660
|
-
| --- | --- | --- | --- |
|
|
1661
|
-
| 默认 / 信息(灰色系) | `fill-2` | `neutral-3` | `neutral-4` |
|
|
1662
|
-
| 彩色弱底 / 描边 / 文本(除 warning) | 无色或同色浅底 | 同色浅底混入按钮文字色 10% | 同色浅底混入按钮文字色 16% |
|
|
1663
|
-
| warning 弱底 / 描边 / 文本 | 无色或同色浅底 | 同色浅底混入按钮文字色 25% | 同色浅底混入按钮文字色 40% |
|
|
1664
|
-
| 链接 | 透明背景、状态文字色 | 保持常态 | 保持常态 |
|
|
1665
|
-
| 实色 | 种子实底 | 混白 8%(更亮) | 混恒定深 10%(更深) |
|
|
1666
|
-
|
|
1667
|
-
默认按钮不用 `fill-2/3/4` 递进:全局 fill 灰阶在浅端被压缩,`fill-2` 与 `fill-3` 只差 3 个通道,悬浮态几乎看不出变化;改用 `neutral-3/4` 后与 Arco 的步进一致。
|
|
1813
|
+
悬浮或按住按钮查看状态变化,也可用 Tab 聚焦后按 Space / Enter 操作。第二组展示局部暗色。
|
|
1668
1814
|
|
|
1669
1815
|
```vue
|
|
1670
1816
|
<script setup lang="ts">
|
|
@@ -1678,15 +1824,52 @@ import { Button } from 'x-next';
|
|
|
1678
1824
|
<Button type="text">文本按钮</Button>
|
|
1679
1825
|
<Button plain status="success">朴素成功</Button>
|
|
1680
1826
|
<Button :border="false" status="danger">无边框危险</Button>
|
|
1681
|
-
<Button
|
|
1682
|
-
<Button
|
|
1683
|
-
<Button
|
|
1827
|
+
<Button type="text" narrow>紧凑文本</Button>
|
|
1828
|
+
<Button type="text" narrow status="danger">危险文本</Button>
|
|
1829
|
+
<Button type="text" narrow disabled>禁用文本</Button>
|
|
1684
1830
|
</template>
|
|
1685
1831
|
```
|
|
1686
1832
|
|
|
1687
|
-
|
|
1833
|
+
```vue
|
|
1834
|
+
<script setup lang="ts">
|
|
1835
|
+
import 'x-next/style.css';
|
|
1836
|
+
import { ref } from 'vue';
|
|
1837
|
+
import { Button as XButton, ConfigProvider as XConfigProvider } from 'x-next';
|
|
1838
|
+
import 'x-next/style/base.css';
|
|
1839
|
+
import 'x-next/style/button.css';
|
|
1688
1840
|
|
|
1689
|
-
|
|
1841
|
+
const count = ref(0);
|
|
1842
|
+
const statuses = ['default', 'primary', 'success', 'warning', 'strong', 'danger', 'info'] as const;
|
|
1843
|
+
</script>
|
|
1844
|
+
<template>
|
|
1845
|
+
<div v-for="status in statuses" :key="status">
|
|
1846
|
+
<XButton type="outline" :status="status" @click="count++">描边</XButton>
|
|
1847
|
+
<XButton type="dashed" :status="status" @click="count++">虚线</XButton>
|
|
1848
|
+
<XButton type="text" :status="status" @click="count++">文本</XButton>
|
|
1849
|
+
<XButton type="text" narrow :status="status" @click="count++">紧凑文本</XButton>
|
|
1850
|
+
</div>
|
|
1851
|
+
<XConfigProvider :dark="true" class="button-dark-example">
|
|
1852
|
+
<XButton type="outline" @click="count++">暗色描边</XButton>
|
|
1853
|
+
<XButton type="dashed" @click="count++">暗色虚线</XButton>
|
|
1854
|
+
<XButton type="text" @click="count++">暗色文本</XButton>
|
|
1855
|
+
<XButton type="text" narrow @click="count++">暗色紧凑文本</XButton>
|
|
1856
|
+
<XButton type="outline" disabled>禁用</XButton>
|
|
1857
|
+
<XButton type="text" loading>加载</XButton>
|
|
1858
|
+
</XConfigProvider>
|
|
1859
|
+
<span role="status">已触发 {{ count }} 次</span>
|
|
1860
|
+
</template>
|
|
1861
|
+
<style scoped>
|
|
1862
|
+
.button-dark-example {
|
|
1863
|
+
display: flex;
|
|
1864
|
+
flex-wrap: wrap;
|
|
1865
|
+
gap: 12px;
|
|
1866
|
+
padding: 20px;
|
|
1867
|
+
background: var(--x-color-bg-surface);
|
|
1868
|
+
}
|
|
1869
|
+
</style>
|
|
1870
|
+
```
|
|
1871
|
+
|
|
1872
|
+
### 状态矩阵
|
|
1690
1873
|
|
|
1691
1874
|
```vue
|
|
1692
1875
|
<script setup lang="ts">
|
|
@@ -1798,6 +1981,15 @@ const pushLog = (label: string) => {
|
|
|
1798
1981
|
|
|
1799
1982
|
`type` 控制视觉样式,`html-type` 控制原生按钮行为。默认 `html-type="button"`,不会因为放进表单而意外提交。
|
|
1800
1983
|
|
|
1984
|
+
### 原生动作与防重复点击
|
|
1985
|
+
|
|
1986
|
+
<form class="example-box example-box-column" data-demo="button-native-debounce" @submit.prevent="nativeCount++" @reset="formStatus = '防重复示例已重置'">
|
|
1987
|
+
<label>必填内容 <input name="message" required value="初始内容" /></label>
|
|
1988
|
+
<span role="status">已提交 {{ nativeCount }} 次;{{ formStatus }}</span>
|
|
1989
|
+
</form>
|
|
1990
|
+
|
|
1991
|
+
`debounce` 用于防止重复点击,提交结果在表单的 submit 事件中处理。
|
|
1992
|
+
|
|
1801
1993
|
```vue
|
|
1802
1994
|
<script setup lang="ts">
|
|
1803
1995
|
import 'x-next/style.css';
|
|
@@ -1815,6 +2007,23 @@ const handleSubmit = () => {
|
|
|
1815
2007
|
</template>
|
|
1816
2008
|
```
|
|
1817
2009
|
|
|
2010
|
+
```vue
|
|
2011
|
+
<script setup lang="ts">
|
|
2012
|
+
import 'x-next/style.css';
|
|
2013
|
+
import { Button } from 'x-next';
|
|
2014
|
+
import { ref } from 'vue';
|
|
2015
|
+
const count = ref(0), message = ref('尚未重置');
|
|
2016
|
+
</script>
|
|
2017
|
+
<template>
|
|
2018
|
+
<form @submit.prevent="count++" @reset="message = '已重置'">
|
|
2019
|
+
<label>必填内容 <input name="message" required value="初始内容" /></label>
|
|
2020
|
+
<Button type="solid" status="primary" html-type="submit" :debounce="800">防重复提交</Button>
|
|
2021
|
+
<Button html-type="reset" :debounce="800">防重复重置</Button>
|
|
2022
|
+
<span role="status">已提交 {{ count }} 次;{{ message }}</span>
|
|
2023
|
+
</form>
|
|
2024
|
+
</template>
|
|
2025
|
+
```
|
|
2026
|
+
|
|
1818
2027
|
### 文字与图标
|
|
1819
2028
|
|
|
1820
2029
|
按钮支持中英文混排,可以通过 `prefix`、`suffix` 插槽添加图标或附加文字。下面展示不同尺寸的组合,切换加载状态可查看加载图标与内容的排列。
|
|
@@ -1948,6 +2157,8 @@ const nativeAttrs1 = { "aria-label": "切换填充加载" } satisfies ButtonHTML
|
|
|
1948
2157
|
|
|
1949
2158
|
按钮组只连接相邻边缘,保留两端的形状;只有一个按钮时仍保留完整圆角。
|
|
1950
2159
|
|
|
2160
|
+
circle 与 block 同用时保持圆形等宽高;普通纯图标与 block 同用时撑满父宽。按钮组中无边框、subtle 和 text 形态不自动补左侧分隔边框。
|
|
2161
|
+
|
|
1951
2162
|
```vue
|
|
1952
2163
|
<script setup lang="ts">
|
|
1953
2164
|
import 'x-next/style.css';
|
|
@@ -5244,6 +5455,38 @@ import { Alert } from 'x-next';
|
|
|
5244
5455
|
</template>
|
|
5245
5456
|
```
|
|
5246
5457
|
|
|
5458
|
+
### 暗色主题
|
|
5459
|
+
|
|
5460
|
+
暗色提示与 Button 状态按钮、Link 悬浮背景及反馈图标底使用同组状态配色,正文保持浅色,图标保留类型辨识度。`normal` 继续使用中性弱提示背景。下面通过 ConfigProvider 展示局部暗色,页面主题切换时也会应用相同配色。
|
|
5461
|
+
|
|
5462
|
+
```vue
|
|
5463
|
+
<script setup lang="ts">
|
|
5464
|
+
import 'x-next/style.css';
|
|
5465
|
+
import { Alert as XAlert, ConfigProvider as XConfigProvider } from 'x-next';
|
|
5466
|
+
import 'x-next/style/base.css';
|
|
5467
|
+
import 'x-next/style/alert.css';
|
|
5468
|
+
</script>
|
|
5469
|
+
<template>
|
|
5470
|
+
<XConfigProvider :dark="true" class="alert-dark-example">
|
|
5471
|
+
<XAlert type="info">用于普通信息提示。</XAlert>
|
|
5472
|
+
<XAlert type="success">用于成功状态反馈。</XAlert>
|
|
5473
|
+
<XAlert type="warning">用于需要关注的警告信息。</XAlert>
|
|
5474
|
+
<XAlert type="strong">用于需要强调的提醒信息。</XAlert>
|
|
5475
|
+
<XAlert type="error">用于错误或失败信息。</XAlert>
|
|
5476
|
+
<XAlert type="normal">用于弱提示或中性说明。</XAlert>
|
|
5477
|
+
</XConfigProvider>
|
|
5478
|
+
</template>
|
|
5479
|
+
<style scoped>
|
|
5480
|
+
.alert-dark-example {
|
|
5481
|
+
display: grid;
|
|
5482
|
+
gap: 12px;
|
|
5483
|
+
padding: 20px;
|
|
5484
|
+
border-radius: 8px;
|
|
5485
|
+
background: var(--x-color-bg-surface);
|
|
5486
|
+
}
|
|
5487
|
+
</style>
|
|
5488
|
+
```
|
|
5489
|
+
|
|
5247
5490
|
### 标题
|
|
5248
5491
|
|
|
5249
5492
|
```vue
|
|
@@ -19730,13 +19973,12 @@ interface BarChartLayout {
|
|
|
19730
19973
|
| loadingFill | 加载时居中覆盖内容并保持尺寸;结束后恢复文字和插槽 | undefined | false | true | 否 | false |
|
|
19731
19974
|
| debounce | 点击后保持 loading 态的时间,单位 ms,用于防重复点击 | undefined | number | 否 | 0 |
|
|
19732
19975
|
| shape | 胶囊形、圆形或直角;未设置时使用默认圆角 | undefined | "round" | "circle" | "square" | 否 | undefined |
|
|
19733
|
-
|
|
|
19734
|
-
| type | 按钮类型 | undefined | "default" | "primary" | "dashed" | "outline" | "text" | 否 | "default" |
|
|
19976
|
+
| type | 按钮形态;primary 是实心形态的快捷类型,默认使用品牌色 | undefined | "default" | "primary" | "solid" | "subtle" | "dashed" | "outline" | "text" | 否 | "default" |
|
|
19735
19977
|
| htmlType | 原生按钮类型;模板中使用 html-type | undefined | "button" | "submit" | "reset" | 否 | "button" |
|
|
19736
|
-
| status |
|
|
19737
|
-
| plain |
|
|
19978
|
+
| status | 按钮颜色 | undefined | "default" | "success" | "warning" | "strong" | "info" | "primary" | "danger" | 否 | "default" |
|
|
19979
|
+
| plain | 将 default / solid / primary 改为弱底,保留颜色 | undefined | false | true | 否 | false |
|
|
19738
19980
|
| size | 按钮尺寸 | undefined | "mini" | "small" | "medium" | "large" | "huge" | 否 | undefined |
|
|
19739
|
-
| border |
|
|
19981
|
+
| border | 是否允许形态的边框;false 只隐藏边框 | undefined | false | true | 否 | true |
|
|
19740
19982
|
| narrow | 是否使用窄按钮,无内边距 | undefined | false | true | 否 | false |
|
|
19741
19983
|
|
|
19742
19984
|
### Events
|
|
@@ -19752,7 +19994,7 @@ interface BarChartLayout {
|
|
|
19752
19994
|
| default | 按钮内容 | () => any |
|
|
19753
19995
|
| prefix | 前置内容 | () => any |
|
|
19754
19996
|
| suffix | 后置内容 | () => any |
|
|
19755
|
-
| icon |
|
|
19997
|
+
| icon | 图标内容,会渲染在文字前;仅有此插槽时通常等宽高,block 时撑满父宽;请设置 aria-label | any |
|
|
19756
19998
|
|
|
19757
19999
|
### 实例方法
|
|
19758
20000
|
|
|
@@ -19765,9 +20007,9 @@ interface BarChartLayout {
|
|
|
19765
20007
|
```typescript-reference
|
|
19766
20008
|
type ButtonSize = 'mini' | 'small' | 'medium' | 'large' | 'huge';
|
|
19767
20009
|
|
|
19768
|
-
type ButtonStatus = 'default' | 'success' | 'warning' | 'strong' | 'danger' | 'info';
|
|
20010
|
+
type ButtonStatus = 'default' | 'primary' | 'success' | 'warning' | 'strong' | 'danger' | 'info';
|
|
19769
20011
|
|
|
19770
|
-
type ButtonTypes = 'primary' | 'default' | 'dashed' | 'outline' | 'text';
|
|
20012
|
+
type ButtonTypes = 'primary' | 'default' | 'solid' | 'subtle' | 'dashed' | 'outline' | 'text';
|
|
19771
20013
|
|
|
19772
20014
|
type ButtonHtmlType = 'button' | 'submit' | 'reset';
|
|
19773
20015
|
|
|
@@ -19780,7 +20022,6 @@ type ButtonProps = {
|
|
|
19780
20022
|
loadingFill?: boolean;
|
|
19781
20023
|
debounce?: number;
|
|
19782
20024
|
shape?: ButtonShape;
|
|
19783
|
-
link?: boolean;
|
|
19784
20025
|
type?: ButtonTypes;
|
|
19785
20026
|
htmlType?: ButtonHtmlType;
|
|
19786
20027
|
status?: ButtonStatus;
|
|
@@ -19800,11 +20041,11 @@ type ButtonProps = {
|
|
|
19800
20041
|
|
|
19801
20042
|
| 名称 | 用途 | 公开类型 | 必填 | 声明默认值 |
|
|
19802
20043
|
| --- | --- | --- | --- | --- |
|
|
19803
|
-
| type | 子按钮默认类型 | undefined | "default" | "primary" | "dashed" | "outline" | "text" | 否 | 未声明 |
|
|
19804
|
-
| status | 子按钮默认状态 | undefined | "default" | "success" | "warning" | "strong" | "info" | "danger" | 否 | 未声明 |
|
|
20044
|
+
| type | 子按钮默认类型 | undefined | "default" | "primary" | "solid" | "subtle" | "dashed" | "outline" | "text" | 否 | 未声明 |
|
|
20045
|
+
| status | 子按钮默认状态 | undefined | "default" | "success" | "warning" | "strong" | "info" | "primary" | "danger" | 否 | 未声明 |
|
|
19805
20046
|
| shape | 子按钮默认形状 | undefined | "round" | "circle" | "square" | 否 | 未声明 |
|
|
19806
20047
|
| size | 子按钮默认尺寸 | undefined | "mini" | "small" | "medium" | "large" | "huge" | 否 | 未声明 |
|
|
19807
|
-
| disabled |
|
|
20048
|
+
| disabled | 子按钮默认禁用值;子按钮显式值优先 | undefined | false | true | 否 | false(Vue Boolean 转换) |
|
|
19808
20049
|
|
|
19809
20050
|
### Events
|
|
19810
20051
|
|
|
@@ -19825,9 +20066,9 @@ type ButtonProps = {
|
|
|
19825
20066
|
```typescript-reference
|
|
19826
20067
|
type ButtonSize = 'mini' | 'small' | 'medium' | 'large' | 'huge';
|
|
19827
20068
|
|
|
19828
|
-
type ButtonStatus = 'default' | 'success' | 'warning' | 'strong' | 'danger' | 'info';
|
|
20069
|
+
type ButtonStatus = 'default' | 'primary' | 'success' | 'warning' | 'strong' | 'danger' | 'info';
|
|
19829
20070
|
|
|
19830
|
-
type ButtonTypes = 'primary' | 'default' | 'dashed' | 'outline' | 'text';
|
|
20071
|
+
type ButtonTypes = 'primary' | 'default' | 'solid' | 'subtle' | 'dashed' | 'outline' | 'text';
|
|
19831
20072
|
|
|
19832
20073
|
type ButtonHtmlType = 'button' | 'submit' | 'reset';
|
|
19833
20074
|
|
|
@@ -19840,7 +20081,6 @@ type ButtonProps = {
|
|
|
19840
20081
|
loadingFill?: boolean;
|
|
19841
20082
|
debounce?: number;
|
|
19842
20083
|
shape?: ButtonShape;
|
|
19843
|
-
link?: boolean;
|
|
19844
20084
|
type?: ButtonTypes;
|
|
19845
20085
|
htmlType?: ButtonHtmlType;
|
|
19846
20086
|
status?: ButtonStatus;
|
|
@@ -20680,8 +20920,8 @@ interface UseDraggableOptions<T> extends Options {
|
|
|
20680
20920
|
| okText | 确认按钮文案 | undefined | string | 否 | "" |
|
|
20681
20921
|
| cancelText | 取消按钮文案 | undefined | string | 否 | "" |
|
|
20682
20922
|
| okLoading | 确认按钮是否 loading | undefined | false | true | 否 | false |
|
|
20683
|
-
| okButtonProps | 确认按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape;
|
|
20684
|
-
| cancelButtonProps | 取消按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape;
|
|
20923
|
+
| okButtonProps | 确认按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape; type?: ButtonTypes; htmlType?: ButtonHtmlType; status?: ButtonStatus; plain?: boolean; size?: ButtonSize; border?: boolean; narrow?: boolean; } | 否 | 未声明 |
|
|
20924
|
+
| cancelButtonProps | 取消按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape; type?: ButtonTypes; htmlType?: ButtonHtmlType; status?: ButtonStatus; plain?: boolean; size?: ButtonSize; border?: boolean; narrow?: boolean; } | 否 | 未声明 |
|
|
20685
20925
|
| hideCancel | 是否隐藏默认取消按钮 | undefined | false | true | 否 | false |
|
|
20686
20926
|
| onBeforeOk | 确认前拦截,返回 false 阻止关闭 | undefined | (event?: Event) => boolean | void | Promise<boolean | void> | 否 | 未声明 |
|
|
20687
20927
|
| onBeforeCancel | 取消前拦截,返回 false 阻止关闭 | undefined | (event?: Event) => boolean | void | Promise<boolean | void> | 否 | 未声明 |
|
|
@@ -20854,9 +21094,9 @@ interface DropdownPanelRef {
|
|
|
20854
21094
|
| position | 弹出位置 | undefined | "top" | "bottom" | "tl" | "tr" | "bl" | "br" | 否 | "br" |
|
|
20855
21095
|
| popupContainer | 弹出层挂载容器 | undefined | string | HTMLElement | 否 | 未声明 |
|
|
20856
21096
|
| disabled | 是否禁用 | undefined | false | true | 否 | false |
|
|
20857
|
-
| type | 按钮类型 | undefined | "default" | "primary" | "dashed" | "outline" | "text" | 否 | "default" |
|
|
21097
|
+
| type | 按钮类型 | undefined | "default" | "primary" | "solid" | "subtle" | "dashed" | "outline" | "text" | 否 | "default" |
|
|
20858
21098
|
| size | 按钮尺寸 | undefined | "mini" | "small" | "medium" | "large" | "huge" | 否 | "medium" |
|
|
20859
|
-
| buttonProps | 左侧主按钮属性 | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape;
|
|
21099
|
+
| buttonProps | 左侧主按钮属性 | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape; type?: ButtonTypes; htmlType?: ButtonHtmlType; status?: ButtonStatus; plain?: boolean; size?: ButtonSize; border?: boolean; narrow?: boolean; } | 否 | 未声明 |
|
|
20860
21100
|
| hideOnSelect | 选择后是否隐藏弹出层 | undefined | false | true | 否 | true |
|
|
20861
21101
|
|
|
20862
21102
|
### Events
|
|
@@ -27491,7 +27731,7 @@ interface ActionType {
|
|
|
27491
27731
|
| disabled | 禁用输入和搜索按钮 | undefined | false | true | 否 | false |
|
|
27492
27732
|
| size | 尺寸,继承 Form / 全局配置 | undefined | "mini" | "small" | "medium" | "large" | 否 | 未声明 |
|
|
27493
27733
|
| buttonText | 搜索按钮文字 | undefined | string | 否 | 未声明 |
|
|
27494
|
-
| buttonProps | 搜索按钮属性 | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape;
|
|
27734
|
+
| buttonProps | 搜索按钮属性 | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape; type?: ButtonTypes; htmlType?: ButtonHtmlType; status?: ButtonStatus; plain?: boolean; size?: ButtonSize; border?: boolean; narrow?: boolean; } | 否 | 未声明 |
|
|
27495
27735
|
| modelValue | 见场景用法与类型 | undefined | string | 否 | 透传内层组件;默认值见对应组件 |
|
|
27496
27736
|
| type | 见场景用法与类型 | undefined | "text" | "password" | 否 | 透传内层组件;默认值见对应组件 |
|
|
27497
27737
|
| error | 见场景用法与类型 | undefined | false | true | 否 | 透传内层组件;默认值见对应组件 |
|
|
@@ -29480,8 +29720,8 @@ interface PieChartSegment {
|
|
|
29480
29720
|
| okText | 确认按钮文案 | undefined | string | 否 | undefined |
|
|
29481
29721
|
| cancelText | 取消按钮文案 | undefined | string | 否 | undefined |
|
|
29482
29722
|
| okLoading | 确认按钮是否为 loading | undefined | false | true | 否 | false |
|
|
29483
|
-
| okButtonProps | 确认按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape;
|
|
29484
|
-
| cancelButtonProps | 取消按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape;
|
|
29723
|
+
| okButtonProps | 确认按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape; type?: ButtonTypes; htmlType?: ButtonHtmlType; status?: ButtonStatus; plain?: boolean; size?: ButtonSize; border?: boolean; narrow?: boolean; } | 否 | 未声明 |
|
|
29724
|
+
| cancelButtonProps | 取消按钮 props | undefined | { disabled?: boolean; block?: boolean; loading?: boolean; loadingFill?: boolean; debounce?: number; shape?: ButtonShape; type?: ButtonTypes; htmlType?: ButtonHtmlType; status?: ButtonStatus; plain?: boolean; size?: ButtonSize; border?: boolean; narrow?: boolean; } | 否 | 未声明 |
|
|
29485
29725
|
| onBeforeOk | 确认前拦截,返回 false 阻止关闭;返回 Promise 时确认按钮进入 loading | undefined | (e: Event) => boolean | void | Promise<boolean | void> | 否 | undefined |
|
|
29486
29726
|
| onBeforeCancel | 取消前拦截,返回 false 阻止关闭;返回 Promise 时取消按钮进入 loading | undefined | (e: Event) => boolean | void | Promise<boolean | void> | 否 | undefined |
|
|
29487
29727
|
| renderTo | 弹层挂载容器 | undefined | string | HTMLElement | 否 | 未声明 |
|
|
@@ -34255,7 +34495,7 @@ type Filters = Record<string, string[]>;
|
|
|
34255
34495
|
| 名称 | 用途 | 公开类型 | 必填 | 声明默认值 |
|
|
34256
34496
|
| --- | --- | --- | --- | --- |
|
|
34257
34497
|
| reverse | 是否倒序展示 | undefined | false | true | 否 | false(Vue Boolean 转换) |
|
|
34258
|
-
| lineType | 轴线样式 | undefined | "
|
|
34498
|
+
| lineType | 轴线样式 | undefined | "solid" | "dashed" | "dotted" | 否 | "solid" |
|
|
34259
34499
|
| direction | 时间线方向 | undefined | "horizontal" | "vertical" | 否 | "vertical" |
|
|
34260
34500
|
| mode | 展示模式 | undefined | "top" | "bottom" | "right" | "left" | "alternate" | 否 | "left" |
|
|
34261
34501
|
| pending | 是否展示幽灵节点,传入字符串时作为节点内容展示 | undefined | string | false | true | 否 | false(Vue Boolean 转换) |
|
|
@@ -34308,7 +34548,7 @@ type TimelineItemPosition = 'left' | 'right' | 'top' | 'bottom';
|
|
|
34308
34548
|
| label | 标签文本 | undefined | string | 否 | 未声明 |
|
|
34309
34549
|
| dotColor | 时间点颜色 | undefined | string & {} | "initial" | "red" | "orangered" | "orange" | "gold" | "lime" | "green" | "cyan" | "blue" | "purple" | "magenta" | "gray" | "-moz-initial" | "inherit" | "revert" | "revert-layer" | "unset" | "aliceblue" | "antiquewhite" | "aqua" | "aquamarine" | "azure" | "beige" | "bisque" | "black" | "blanchedalmond" | "blueviolet" | "brown" | "burlywood" | "cadetblue" | "chartreuse" | "chocolate" | "coral" | "cornflowerblue" | "cornsilk" | "crimson" | "darkblue" | "darkcyan" | "darkgoldenrod" | "darkgray" | "darkgreen" | "darkgrey" | "darkkhaki" | "darkmagenta" | "darkolivegreen" | "darkorange" | "darkorchid" | "darkred" | "darksalmon" | "darkseagreen" | "darkslateblue" | "darkslategray" | "darkslategrey" | "darkturquoise" | "darkviolet" | "deeppink" | "deepskyblue" | "dimgray" | "dimgrey" | "dodgerblue" | "firebrick" | "floralwhite" | "forestgreen" | "fuchsia" | "gainsboro" | "ghostwhite" | "goldenrod" | "greenyellow" | "grey" | "honeydew" | "hotpink" | "indianred" | "indigo" | "ivory" | "khaki" | "lavender" | "lavenderblush" | "lawngreen" | "lemonchiffon" | "lightblue" | "lightcoral" | "lightcyan" | "lightgoldenrodyellow" | "lightgray" | "lightgreen" | "lightgrey" | "lightpink" | "lightsalmon" | "lightseagreen" | "lightskyblue" | "lightslategray" | "lightslategrey" | "lightsteelblue" | "lightyellow" | "limegreen" | "linen" | "maroon" | "mediumaquamarine" | "mediumblue" | "mediumorchid" | "mediumpurple" | "mediumseagreen" | "mediumslateblue" | "mediumspringgreen" | "mediumturquoise" | "mediumvioletred" | "midnightblue" | "mintcream" | "mistyrose" | "moccasin" | "navajowhite" | "navy" | "oldlace" | "olive" | "olivedrab" | "orchid" | "palegoldenrod" | "palegreen" | "paleturquoise" | "palevioletred" | "papayawhip" | "peachpuff" | "peru" | "pink" | "plum" | "powderblue" | "rebeccapurple" | "rosybrown" | "royalblue" | "saddlebrown" | "salmon" | "sandybrown" | "seagreen" | "seashell" | "sienna" | "silver" | "skyblue" | "slateblue" | "slategray" | "slategrey" | "snow" | "springgreen" | "steelblue" | "tan" | "teal" | "thistle" | "tomato" | "turquoise" | "violet" | "wheat" | "white" | "whitesmoke" | "yellow" | "yellowgreen" | "transparent" | "AccentColor" | "AccentColorText" | "ActiveText" | "ButtonBorder" | "ButtonFace" | "ButtonText" | "Canvas" | "CanvasText" | "Field" | "FieldText" | "GrayText" | "Highlight" | "HighlightText" | "LinkText" | "Mark" | "MarkText" | "SelectedItem" | "SelectedItemText" | "VisitedText" | "ActiveBorder" | "ActiveCaption" | "AppWorkspace" | "Background" | "ButtonHighlight" | "ButtonShadow" | "CaptionText" | "InactiveBorder" | "InactiveCaption" | "InactiveCaptionText" | "InfoBackground" | "InfoText" | "Menu" | "MenuText" | "Scrollbar" | "ThreeDDarkShadow" | "ThreeDFace" | "ThreeDHighlight" | "ThreeDLightShadow" | "ThreeDShadow" | "Window" | "WindowFrame" | "WindowText" | "currentColor" | 否 | 未声明 |
|
|
34310
34550
|
| dotType | 时间点类型 | undefined | "solid" | "hollow" | 否 | "solid" |
|
|
34311
|
-
| lineType | 当前节点后的轴线样式 | undefined | "
|
|
34551
|
+
| lineType | 当前节点后的轴线样式 | undefined | "solid" | "dashed" | "dotted" | 否 | 未声明 |
|
|
34312
34552
|
| lineColor | 当前节点后的轴线颜色 | undefined | string & {} | "initial" | "red" | "orangered" | "orange" | "gold" | "lime" | "green" | "cyan" | "blue" | "purple" | "magenta" | "gray" | "-moz-initial" | "inherit" | "revert" | "revert-layer" | "unset" | "aliceblue" | "antiquewhite" | "aqua" | "aquamarine" | "azure" | "beige" | "bisque" | "black" | "blanchedalmond" | "blueviolet" | "brown" | "burlywood" | "cadetblue" | "chartreuse" | "chocolate" | "coral" | "cornflowerblue" | "cornsilk" | "crimson" | "darkblue" | "darkcyan" | "darkgoldenrod" | "darkgray" | "darkgreen" | "darkgrey" | "darkkhaki" | "darkmagenta" | "darkolivegreen" | "darkorange" | "darkorchid" | "darkred" | "darksalmon" | "darkseagreen" | "darkslateblue" | "darkslategray" | "darkslategrey" | "darkturquoise" | "darkviolet" | "deeppink" | "deepskyblue" | "dimgray" | "dimgrey" | "dodgerblue" | "firebrick" | "floralwhite" | "forestgreen" | "fuchsia" | "gainsboro" | "ghostwhite" | "goldenrod" | "greenyellow" | "grey" | "honeydew" | "hotpink" | "indianred" | "indigo" | "ivory" | "khaki" | "lavender" | "lavenderblush" | "lawngreen" | "lemonchiffon" | "lightblue" | "lightcoral" | "lightcyan" | "lightgoldenrodyellow" | "lightgray" | "lightgreen" | "lightgrey" | "lightpink" | "lightsalmon" | "lightseagreen" | "lightskyblue" | "lightslategray" | "lightslategrey" | "lightsteelblue" | "lightyellow" | "limegreen" | "linen" | "maroon" | "mediumaquamarine" | "mediumblue" | "mediumorchid" | "mediumpurple" | "mediumseagreen" | "mediumslateblue" | "mediumspringgreen" | "mediumturquoise" | "mediumvioletred" | "midnightblue" | "mintcream" | "mistyrose" | "moccasin" | "navajowhite" | "navy" | "oldlace" | "olive" | "olivedrab" | "orchid" | "palegoldenrod" | "palegreen" | "paleturquoise" | "palevioletred" | "papayawhip" | "peachpuff" | "peru" | "pink" | "plum" | "powderblue" | "rebeccapurple" | "rosybrown" | "royalblue" | "saddlebrown" | "salmon" | "sandybrown" | "seagreen" | "seashell" | "sienna" | "silver" | "skyblue" | "slateblue" | "slategray" | "slategrey" | "snow" | "springgreen" | "steelblue" | "tan" | "teal" | "thistle" | "tomato" | "turquoise" | "violet" | "wheat" | "white" | "whitesmoke" | "yellow" | "yellowgreen" | "transparent" | "AccentColor" | "AccentColorText" | "ActiveText" | "ButtonBorder" | "ButtonFace" | "ButtonText" | "Canvas" | "CanvasText" | "Field" | "FieldText" | "GrayText" | "Highlight" | "HighlightText" | "LinkText" | "Mark" | "MarkText" | "SelectedItem" | "SelectedItemText" | "VisitedText" | "ActiveBorder" | "ActiveCaption" | "AppWorkspace" | "Background" | "ButtonHighlight" | "ButtonShadow" | "CaptionText" | "InactiveBorder" | "InactiveCaption" | "InactiveCaptionText" | "InfoBackground" | "InfoText" | "Menu" | "MenuText" | "Scrollbar" | "ThreeDDarkShadow" | "ThreeDFace" | "ThreeDHighlight" | "ThreeDLightShadow" | "ThreeDShadow" | "Window" | "WindowFrame" | "WindowText" | "currentColor" | 否 | 未声明 |
|
|
34313
34553
|
| position | 交替模式下的单项位置 | undefined | "top" | "bottom" | "right" | "left" | 否 | 未声明 |
|
|
34314
34554
|
|