kiner-tang(文辉)
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with
65 additions and
19 deletions
-
components/form/__tests__/__snapshots__/demo-extend.test.ts.snap
-
components/form/__tests__/__snapshots__/demo.test.tsx.snap
-
components/form/demo/validate-other.tsx
-
package.json
|
|
@ -20625,14 +20625,35 @@ exports[`renders components/form/demo/validate-other.tsx extend context correctl |
|
|
|
<div |
|
|
|
class="ant-form-item-control-input-content" |
|
|
|
> |
|
|
|
<button |
|
|
|
class="ant-btn ant-btn-primary" |
|
|
|
type="submit" |
|
|
|
<div |
|
|
|
class="ant-space ant-space-horizontal ant-space-align-center" |
|
|
|
> |
|
|
|
<span> |
|
|
|
Submit |
|
|
|
</span> |
|
|
|
</button> |
|
|
|
<div |
|
|
|
class="ant-space-item" |
|
|
|
style="margin-right: 8px;" |
|
|
|
> |
|
|
|
<button |
|
|
|
class="ant-btn ant-btn-primary" |
|
|
|
type="submit" |
|
|
|
> |
|
|
|
<span> |
|
|
|
Submit |
|
|
|
</span> |
|
|
|
</button> |
|
|
|
</div> |
|
|
|
<div |
|
|
|
class="ant-space-item" |
|
|
|
> |
|
|
|
<button |
|
|
|
class="ant-btn ant-btn-default" |
|
|
|
type="reset" |
|
|
|
> |
|
|
|
<span> |
|
|
|
reset |
|
|
|
</span> |
|
|
|
</button> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
@ -9505,14 +9505,35 @@ exports[`renders components/form/demo/validate-other.tsx correctly 1`] = ` |
|
|
|
<div |
|
|
|
class="ant-form-item-control-input-content" |
|
|
|
> |
|
|
|
<button |
|
|
|
class="ant-btn ant-btn-primary" |
|
|
|
type="submit" |
|
|
|
<div |
|
|
|
class="ant-space ant-space-horizontal ant-space-align-center" |
|
|
|
> |
|
|
|
<span> |
|
|
|
Submit |
|
|
|
</span> |
|
|
|
</button> |
|
|
|
<div |
|
|
|
class="ant-space-item" |
|
|
|
style="margin-right:8px" |
|
|
|
> |
|
|
|
<button |
|
|
|
class="ant-btn ant-btn-primary" |
|
|
|
type="submit" |
|
|
|
> |
|
|
|
<span> |
|
|
|
Submit |
|
|
|
</span> |
|
|
|
</button> |
|
|
|
</div> |
|
|
|
<div |
|
|
|
class="ant-space-item" |
|
|
|
> |
|
|
|
<button |
|
|
|
class="ant-btn ant-btn-default" |
|
|
|
type="reset" |
|
|
|
> |
|
|
|
<span> |
|
|
|
reset |
|
|
|
</span> |
|
|
|
</button> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
@ -1,4 +1,3 @@ |
|
|
|
import React from 'react'; |
|
|
|
import { InboxOutlined, UploadOutlined } from '@ant-design/icons'; |
|
|
|
import { |
|
|
|
Button, |
|
|
@ -11,9 +10,11 @@ import { |
|
|
|
Row, |
|
|
|
Select, |
|
|
|
Slider, |
|
|
|
Space, |
|
|
|
Switch, |
|
|
|
Upload, |
|
|
|
} from 'antd'; |
|
|
|
import React from 'react'; |
|
|
|
|
|
|
|
const { Option } = Select; |
|
|
|
|
|
|
@ -181,9 +182,12 @@ const App: React.FC = () => ( |
|
|
|
</Form.Item> |
|
|
|
|
|
|
|
<Form.Item wrapperCol={{ span: 12, offset: 6 }}> |
|
|
|
<Button type="primary" htmlType="submit"> |
|
|
|
Submit |
|
|
|
</Button> |
|
|
|
<Space> |
|
|
|
<Button type="primary" htmlType="submit"> |
|
|
|
Submit |
|
|
|
</Button> |
|
|
|
<Button htmlType="reset">reset</Button> |
|
|
|
</Space> |
|
|
|
</Form.Item> |
|
|
|
</Form> |
|
|
|
); |
|
|
|
|
|
@ -126,7 +126,7 @@ |
|
|
|
"rc-dialog": "~9.1.0", |
|
|
|
"rc-drawer": "~6.1.1", |
|
|
|
"rc-dropdown": "~4.0.0", |
|
|
|
"rc-field-form": "~1.29.0", |
|
|
|
"rc-field-form": "~1.30.0", |
|
|
|
"rc-image": "~5.16.0", |
|
|
|
"rc-input": "~1.0.4", |
|
|
|
"rc-input-number": "~7.4.0", |
|
|
|