ant-design / ant-design/pro-components
ProFormCaptcha 设置 width 属性并不生效
- Dominant language
- TypeScript
- Stars
- 4.8k
- Forks
- 1.4k
- Avg merge
- 10h 44m
- Merged PRs (30d)
- 3
Description
### 🐛 bug 描述
,
}}
captchaProps={{
size: 'large',
}}
// 手机号的 name,onGetCaptcha 会注入这个值
phoneName="phone"
name="captcha"
rules={[
{
required: true,
message: '请输入验证码',
},
]}
placeholder="请输入验证码"
// 如果需要失败可以 throw 一个错误出来,onGetCaptcha 会自动停止
// throw new Error("获取验证码错误")
onGetCaptcha={async (phone) => {
await waitTime(1000);
message.success(`手机号 ${phone} 验证码发送成功!`);
}}
/>
### 📷 复现步骤
ProFormCaptcha 组件设置 `width` 属性
### 🏞 期望结果
对应的 `width` 并未生效
### 💻 复现代码
### © 版本信息
- ProComponents 版本: [2.5.0]
### 🚑 其他信息
Contributor guide
Research direction
Locate the ProFormCaptcha entry point in the ProComponents source and reproduce the reported width="md" case with the supplied fieldProps and captchaProps. Trace how width reaches the rendered control, then verify that the requested width takes effect and check for relevant regression coverage.
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
- 35/100