Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[新功能需求] 上传组件增加后缀名范围限制 #581

Open
flowerwOw0316 opened this issue Sep 6, 2024 · 5 comments
Open

[新功能需求] 上传组件增加后缀名范围限制 #581

flowerwOw0316 opened this issue Sep 6, 2024 · 5 comments
Assignees
Labels
feature 新特性

Comments

@flowerwOw0316
Copy link

这个功能解决了什么问题?

现在控制范围比较广泛,希望精确控制文件上传的后缀名。

你期望的 API 是什么样子的?


与现有的泛控制accept二选一,用了accept就不能用accept-ext

@flowerwOw0316 flowerwOw0316 added the feature: need confirm 待确认的新特性 label Sep 6, 2024
@flowerwOw0316
Copy link
Author

<上传组件 accept-ext=".jpg|.pdf"></上传组件>
或<上传组件 :accept-ext="['.jpg','.pdf']"></上传组件>

我发现用了上传的英文被吞了,大概这个意思

@Moonofweisheng
Copy link
Owner

<上传组件 accept-ext=".jpg|.pdf"></上传组件> 或<上传组件 :accept-ext="['.jpg','.pdf']"></上传组件>

我发现用了上传的英文被吞了,大概这个意思

目前的实现大概只有微信选文件和h5可以有这个功能,等回头我看看

@wss-git
Copy link

wss-git commented Sep 29, 2024

官方都是使用 extension 属性,建议也使用 extension

<upload :extension="['.jpg','.pdf']"></upload>

@Moonofweisheng
Copy link
Owner

Moonofweisheng commented Nov 23, 2024

计划排期在12月,支持extension属性。

@Tindtily
Copy link

加油

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature 新特性
Projects
None yet
Development

No branches or pull requests

4 participants