Skip to content

formItem的高度由于class ant-form-item-control设置的line-height导致大于input组件的实际高度 #1418

@see311

Description

@see311
  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

1.4.4

Environment

chrome 78

Reproduction link

https://www.antdv.com/components/form-cn/#components-form-demo-coordinated-controls

Steps to reproduce

官方网站的form例子就是这样的。

.ant-form-item-control {
position: relative;
line-height: 40px;
zoom: 1;
}

而内部的input.ant-input实际高度也就32px

What is expected?

.ant-form-item-control 的line-height与内部组件高度一致

What is actually happening?

由于form-item的高度与其他default size的组件不一致,导致动态渲染的时候出现抖动
临时解决方法就是覆盖.ant-form-item-control的样式

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions