@9troisquarts/antd-form.ant-form 中文文档教程
AntForm
AntForm 是一个组件,可让您轻松构建具有架构
bit
bit import 9troisquarts.antd-form/ant-form
yarn/npm
npm config set '@9troisquarts:registry' https://node.bit.dev
yarn add @ant-form/ant-form
OR
npm i @ant-form/ant-form
Usage/Examples
import AntForm from '@ant-form/ant-form';
function App() {
return (
<AntForm
schema={[]}
object={{}}
/>
)
}
API Reference
AntForm Props
All AntDesign Form props 在 AntForm 上可用
Parameter | Type | Description | Default |
---|---|---|---|
actionsWrapperProps | object | Props of the div wrapping actions | - |
errors | object | Set the current errors of the object (See example) | - |
extraActions | Array\<React.Component> | Extra actions displayed at the left of the submit button | - |
loading | boolean | Set the loading state of submit button | false |
object | object | required Object used in form | - |
onChange | function(changedField, allFields) | Trigger when field updated | - |
onSubmit | function(allFields) | Triger after submitting the form, submit button will be hide if not provided | - |
readOnly | boolean | Set the readonly state of the form | false |
rowProps | RowProps | Set the props on rows surrounded each fields group | - |
schema | Schema | required Set the schema used by the form | - |
submitButtonProps | ButtonProps | Submit button props | - |
submitText | string | Change the text in the submit button | Save |
Available fields type
- Rate
- Select
- String / Text
- Number
- Radio
- Autocomplete
- Upload
- Checkbox / Checkboxes
- Slider
- Switch
- Date
- List
AntForm
AntForm is a component allowing you to easily build form with schema
bit
bit import 9troisquarts.antd-form/ant-form
yarn/npm
npm config set '@9troisquarts:registry' https://node.bit.dev
yarn add @ant-form/ant-form
OR
npm i @ant-form/ant-form
Usage/Examples
import AntForm from '@ant-form/ant-form';
function App() {
return (
<AntForm
schema={[]}
object={{}}
/>
)
}
API Reference
AntForm Props
All AntDesign Form props is available on AntForm
Parameter | Type | Description | Default |
---|---|---|---|
actionsWrapperProps | object | Props of the div wrapping actions | - |
errors | object | Set the current errors of the object (See example) | - |
extraActions | Array\<React.Component> | Extra actions displayed at the left of the submit button | - |
loading | boolean | Set the loading state of submit button | false |
object | object | required Object used in form | - |
onChange | function(changedField, allFields) | Trigger when field updated | - |
onSubmit | function(allFields) | Triger after submitting the form, submit button will be hide if not provided | - |
readOnly | boolean | Set the readonly state of the form | false |
rowProps | RowProps | Set the props on rows surrounded each fields group | - |
schema | Schema | required Set the schema used by the form | - |
submitButtonProps | ButtonProps | Submit button props | - |
submitText | string | Change the text in the submit button | Save |
Available fields type
- Rate
- Select
- String / Text
- Number
- Radio
- Autocomplete
- Upload
- Checkbox / Checkboxes
- Slider
- Switch
- Date
- List
更多
你可能也喜欢
- 9c-lord-backend 中文文档教程
- @0bsnetwork/event-sender 中文文档教程
- @0x04/string-mutilator 中文文档教程
- @0xcert/wanchain-order-gateway 中文文档教程
- @2060digital/prettier-config 中文文档教程
- @3rdweb/chain-icons 中文文档教程
- @4geit/swg-message-model 中文文档教程
- @4keys/svg.resize.js 中文文档教程
- @8xprotocol/service-node-core 中文文档教程
- @9renpoto/eslint-config-typescript 中文文档教程