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

feat(checkbox): 增加至少选择项数量的设置功能 #1859

Merged
merged 5 commits into from
Jan 19, 2024

Conversation

oasis-cloud
Copy link
Collaborator

🤔 这个变动的性质是?

  • 新特性提交

🔗 相关 Issue

💡 需求背景和解决方案

增加 和 max 属性对应的 min 属性,用于限制必须选择的项数量,例如 min=1 ,则至少选择 1 项

Copy link

codecov bot commented Jan 15, 2024

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (2bccea4) 75.86% compared to head (b55a998) 75.97%.
Report is 13 commits behind head on next.

Files Patch % Lines
src/packages/checkboxgroup/checkboxgroup.tsx 85.71% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             next    #1859      +/-   ##
==========================================
+ Coverage   75.86%   75.97%   +0.10%     
==========================================
  Files         215      215              
  Lines        8661     8682      +21     
  Branches     2479     2489      +10     
==========================================
+ Hits         6571     6596      +25     
+ Misses       1893     1889       -4     
  Partials      197      197              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@oasis-cloud oasis-cloud marked this pull request as ready for review January 17, 2024 01:44
Copy link
Collaborator

@xiaoyatong xiaoyatong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个功能非常好。
如果可以在设置了 max 和 min 后,选择多余max的选项或者少于 min的选项时,可以给一个callback,会更好~

社群反馈 Me:checkboxGroup使用,限制最大可选数 不可选应该有一个提示(2023.11.22)

src/packages/checkboxgroup/checkboxgroup.tsx Outdated Show resolved Hide resolved
@oasis-cloud
Copy link
Collaborator Author

这个功能非常好。 如果可以在设置了 max 和 min 后,选择多余max的选项或者少于 min的选项时,可以给一个callback,会更好~

社群反馈 Me:checkboxGroup使用,限制最大可选数 不可选应该有一个提示(2023.11.22)

增加了 onLimit 事件

@xiaoyatong xiaoyatong merged commit 33a70a2 into jdf2e:next Jan 19, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants