We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
能够在任意html标签中使用,例如button、div等,而不局限于特定的vant组件
<van-badge :value="12" :max="99"> html标签 </van-badge>
value 值 string, number max 最大值,超过会显示最大值 dot 小圆点 boolean hidden 隐藏 badge boolean type 类型 string 类型,可选值为 primary info warning danger
The text was updated successfully, but these errors were encountered:
后续会加一个
Sorry, something went wrong.
最近遇到了这个需求,徽标在一些场景确实需要,比如做新闻类型的项目。一些 icon 上 需要加徽标 。数字 点赞数 评论数这些。很需要徽标作为单独组件使用。
feat: add Badge component #6573
475e60b
已在 3.0.0-beta.3 版本增加 Badge 组件
No branches or pull requests
这个功能解决了什么问题
能够在任意html标签中使用,例如button、div等,而不局限于特定的vant组件
描述您想要的解决方案
建议的API是什么样的
value 值 string, number
max 最大值,超过会显示最大值
dot 小圆点 boolean
hidden 隐藏 badge boolean
type 类型 string 类型,可选值为 primary info warning danger
The text was updated successfully, but these errors were encountered: