diff --git a/packages/varlet-ui/src/uploader/Uploader.vue b/packages/varlet-ui/src/uploader/Uploader.vue index a036a5ca5ad..d4f8ce401bc 100644 --- a/packages/varlet-ui/src/uploader/Uploader.vue +++ b/packages/varlet-ui/src/uploader/Uploader.vue @@ -9,9 +9,19 @@ @click="preview(f)" >
{{ f.name || f.url }}
-
- -
+ +
+ +
+
void` | ### Style Variables diff --git a/packages/varlet-ui/src/uploader/docs/zh-CN.md b/packages/varlet-ui/src/uploader/docs/zh-CN.md index f840c98c264..d9126aee2e8 100644 --- a/packages/varlet-ui/src/uploader/docs/zh-CN.md +++ b/packages/varlet-ui/src/uploader/docs/zh-CN.md @@ -510,6 +510,7 @@ const files = ref([ | --- | --- | --- | | `default` | 上传按钮内容 | `-` | | `extra-message` | 附加信息 | `-` | +| `remove-button` | 删除按钮 | `remove: () => void` | ### 样式变量 diff --git a/packages/varlet-ui/types/uploader.d.ts b/packages/varlet-ui/types/uploader.d.ts index 0e220174b64..82de27ee91c 100644 --- a/packages/varlet-ui/types/uploader.d.ts +++ b/packages/varlet-ui/types/uploader.d.ts @@ -67,6 +67,7 @@ export class Uploader extends VarComponent { $slots: { default(): VNode[] 'extra-message'(): VNode[] + 'remove-button'(remove: () => void): VNode[] } getLoading(): VarFile[]