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

Form label fixed width #17409

Closed
1 task done
silent-tan opened this issue Jul 2, 2019 · 4 comments
Closed
1 task done

Form label fixed width #17409

silent-tan opened this issue Jul 2, 2019 · 4 comments

Comments

@silent-tan
Copy link

silent-tan commented Jul 2, 2019

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

What problem does this feature solve?

當 labelAlign 為 left 的時候,屏幕寬度不同導致 label 和 input(獲取其他表單組件) 的間隙較大,不美觀

when labelAlign is left, different screen widths result in large gaps between label and Form component (like input or select), not beautiful

example:

image

What does the proposed API look like?

<Form {...formItemLayout} labelAlign="left" labelWidth={200}>
...
</Form>
@silent-tan silent-tan changed the title Form 表單label固定長度,表單組件Flex:1 Form label fixed width Jul 2, 2019
@afc163
Copy link
Member

afc163 commented Jul 2, 2019

<Form layout="inline">

@afc163 afc163 closed this as completed Jul 2, 2019
@yezongyang
Copy link

使用浮动百分比很奇怪啊,页面宽度变化,label 还会显示错位

@chengwb53
Copy link

这个需求还没处理吗?

@peakandyuri
Copy link

peakandyuri commented Oct 17, 2022

<Form.Item labelCol={{style: {width: 200}}}>
...
</Form.Item>

文档上确实没有标明,我也是无意中搜索到的,试了下可行

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants