feat: add suffix and deprecate suffixIcon - #1014
Conversation
|
@QDyanbing is attempting to deploy a commit to the React Component Team on Vercel. A member of the Team first needs to authorize it. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (15)
Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review. WalkthroughPicker 组件新增 Changessuffix 属性迁移
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to Picker components now support suffix as the preferred custom suffix prop while retaining suffixIcon compatibility. The documented rendering behavior and precedence are covered, with no remaining concrete merge-blocking risk. Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 5 functions across 13 files. (2 skipped: 2 unsupported.)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1014 +/- ##
=======================================
Coverage 98.88% 98.88%
=======================================
Files 68 68
Lines 2867 2868 +1
Branches 822 795 -27
=======================================
+ Hits 2835 2836 +1
Misses 29 29
Partials 3 3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
新增统一的
suffix属性,并将suffixIcon标记为废弃,兼容现有调用。单选、多选、时间和范围选择统一使用suffix ?? suffixIcon:suffix为null或undefined时回退到旧属性,其余值优先使用新属性。同步更新内部属性传递、中文和英文 README、示例及测试,保留现有 DOM 结构和语义样式。
验证:
Summary by CodeRabbit
suffix属性,用于自定义后缀内容。suffix与旧版suffixIcon时,优先使用suffix。suffixIcon已标记为弃用,建议迁移至suffix;现有用法仍保持兼容。suffix的使用方式。