ant-design / ant-design/pro-components
🐛[BUG]ProTable中form部分属性不生效
- Dominant language
- TypeScript
- Stars
- 4.8k
- Forks
- 1.4k
- Avg merge
- 10h 44m
- Merged PRs (30d)
- 3
Description
提问前先看看:
https://github.com/ryanhanwu/How-To-Ask-Questions-The-Smart-Way/blob/main/README-zh_CN.md
### 🐛 bug 描述
在ProTable中form属性中设置labelAlign和labelCol,如下:
`form={{ labelAlign: 'left', labelCol: { flex: '0' } }}`
`labelAlign: 'left'`有效果,label标题会居左。但 `labelCol: { flex: '0' }`没有效果。在Column中设置`formItemProps: { labelCol: { flex: 0 } },`才有效。
### 📷 复现步骤
1.在ProTable中form属性中设置labelAlign和labelCol,如下:
`form={{ labelAlign: 'left', labelCol: { flex: '0' } }}`
### 🏞 期望结果
label与warp之间没有间隔。
### © 版本信息
- ProComponents 版本:2.7.9
### 🚑 其他信息
Contributor guide
Research direction
Start at the ProTable form configuration entry point and reproduce the issue with form.labelAlign and form.labelCol on ProComponents 2.7.9. Compare the form-level labelCol behavior with Column.formItemProps.labelCol; done means the form-level setting removes the gap between the label and wrapper, with a regression test covering the reported configuration.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100