ant-design / ant-design

An enterprise-class UI design language and React UI library
https://ant.design
MIT License
93.72k stars 51.17k forks source link

Space.Compact Bug #52619

Closed andrewww05 closed 2 weeks ago

andrewww05 commented 2 weeks ago

Reproduction link

Edit on CodeSandbox

Steps to reproduce

Use space.compact with input and button

What is expected?

The button is the same height as the input

What is actually happening?

the height of the button is less than the height of the input

Environment Info
antd 5.23.3
React v19 Vite
System Kubuntu 24.04.1 LTS
Browser Google Chrome Version 132.0.6834.83 (Official Build) (64-bit)
petercat-assistant[bot] commented 2 weeks ago

It seems that there have been some related issues and pull requests concerning Space.Compact and alignment problems in the Ant Design repository. Here are some of them:

  1. Issue #38341: Space.Compact broken when using Input with suffix
  2. Issue #42851: Alignment issue when using Select multiple mode with Space.Compact
  3. PR #44475: refactor: button default not use compact style

These issues and pull requests might provide some insights or solutions related to the problem you are experiencing with Space.Compact. You can explore these links for more detailed information and potential fixes.

If you need further assistance or have any other questions, feel free to ask!

🪧 Tips For further assistance, please describe your question in the comments and @petercat-assistant to start a conversation with me.
afc163 commented 2 weeks ago

Please remove style={{ height: "100%" }}.