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

fix(card): 修复 Card 组件中 actions 和 toolbar 中的 dropdown-button 组件失效的问题 #11605

Merged

Conversation

BeMxself
Copy link
Contributor

What

  • 渲染 toolbar 和 actions 时,在传入 subProps 中指定 onClick 为 undefined
  • 避免 Cards 中为 Cards 功能特性增加的点击处理函数意外传给 Card 的 toolbar 和 actions
  • 修复 renderField 拼写错误

Why

  • Cards 渲染 Card 的时候会传入 onClick
  • Card 渲染 actions、toolbar 区域的时候会把这个属性带入到相关组件的渲染中
  • 导致 dropdown-button 这样的组件,在点击下拉菜单项的时候触发了 rowClick 事件,而不是 button 的 click 事件

How

  • Card 渲染可能会包含下拉菜单的部件的时候把 onClick 置为 undefined

- 渲染 toolbar 和 actions 时,在传入 subProps 中指定 onClick 为 undefined
- 避免 Cards 中为 Cards 功能特性增加的点击处理函数意外传给 Card 的 toolbar 和 actions
- 修复 renderField 拼写错误
@github-actions github-actions bot added the fix label Feb 14, 2025
Copy link

👍 Thanks for this!
🏷 I have applied any labels matching special text in your issue.

Please review the labels and make any necessary changes.

@2betop 2betop merged commit e8dd7a8 into baidu:master Feb 21, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants