mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-29 05:29:37 +08:00
docs: Update form demo (#22483)
This commit is contained in:
parent
4e270e1873
commit
d33784b813
@ -247,7 +247,14 @@ const RegistrationForm = () => {
|
||||
</Row>
|
||||
</Form.Item>
|
||||
|
||||
<Form.Item name="agreement" valuePropName="checked" {...tailFormItemLayout}>
|
||||
<Form.Item
|
||||
name="agreement"
|
||||
valuePropName="checked"
|
||||
rules={[
|
||||
{ validator:(_, value) => value ? Promise.resolve() : Promise.reject('Should accept agreement') },
|
||||
]}
|
||||
{...tailFormItemLayout}
|
||||
>
|
||||
<Checkbox>
|
||||
I have read the <a href="">agreement</a>
|
||||
</Checkbox>
|
||||
|
Loading…
Reference in New Issue
Block a user