ant-design / ant-design/pro-components

🐛[BUG] StepFrom中套用ProForm时,ProForm样式乱套,colon失效

Open
#7,698 2 comments 0 reactions 0 assignees View on GitHub
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 描述
StepFrom中套用ProForm时,ProForm样式乱套,colon失效
![image](https://github.com/ant-design/pro-components/assets/50571024/2905f404-bfa3-41ac-a1e8-998d45213dbc)

### 🏞 期望结果
不受外层样式影响

### 💻 复现代码
https://codesandbox.io/s/form-de-layout-qie-huan-forked-wqsqsq?file=/App.tsx:0-793
```tsx
import { ProForm, ProFormText, StepsForm } from "@ant-design/pro-components";
import { Col, Input } from "antd";

const MyProForm = () => (








);

export default () => {
return (




{/* A */}



{/* B */}


);
};

```
### © 版本信息

- ProComponents 版本: [e.g. 4.0.0]
- umi 版本
- 浏览器环境
- 开发环境 [e.g. mac OS]

### 🚑 其他信息

Contributor guide

Open the contributing guide

Research direction

Start with the App.tsx reproduction in the linked CodeSandbox, comparing the MyProForm rendered inside StepsForm.StepForm with the standalone form. Verify the affected ProForm layout and colon behavior, then confirm that the nested form is no longer altered by the outer styling and that colon works as configured.

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
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.