-
Notifications
You must be signed in to change notification settings - Fork 52
fix: clear button should have type="button" #83
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
Conversation
Walkthrough此次更改涉及 Changes
Assessment against linked issues
Possibly related PRs
📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
🔇 Additional comments (2)src/BaseInput.tsx (2)Line range hint 按钮的事件处理实现非常完整:
这些都是很好的实践。
这个改动很好地解决了清除按钮意外触发表单提交的问题。通过明确指定 让我们验证一下代码库中是否还有其他类似的按钮需要添加 type 属性: ✅ Verification successful代码库中的按钮类型属性设置正确 经过验证,代码库中只有一个 🏁 Scripts executedThe following scripts were executed for the analysis: Script: Length of output: 326 Script: Length of output: 168 Script: Length of output: 159 Script: Length of output: 5834 Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files☔ View full report in Codecov by Sentry. |
close #82
Summary by CodeRabbit
type="button"属性,以确保点击时不会提交表单,提升了可访问性和功能性。