基于 antd封装的 formily表单组件库
布局组件
- FormLayout
- FormLayoutDeepContext
- FormLayoutShallowContext
- FormGrid 网格布局
- FormGrid.createFormGrid
- FormItem
- FormItem.BaseItem 需要依赖 FormItem 的样式布局
- FormButtonGroup 提交按钮
- Form
- FormProvider + FormLayout + form 标签的组合组件
- Space
- Submit
- Reset
- GridColumn
["useFormDeepLayout","useFormGrid","useFormLayout","useFormShallowLayout","useGridColumn","useGridSpan"]
FormButtonGroup 按钮组容器
- FormButtonGroup.FormItem 按钮组与主表单 FormItem 对齐表单
- FormButtonGroup.Sticky 按钮组浮动定位
- FormButtonGroup 处理按钮组间隙
FormItem 对齐表单
Sticky 固定在网页底部

<FormButtonGroup.Sticky align="center"><FormButtonGroup><Submit onSubmit={console.log}>提交</Submit><Reset>重置</Reset></FormButtonGroup></FormButtonGroup.Sticky><FormButtonGroup.FormItem><Submit onSubmit={console.log}>提交</Submit><Reset>重置</Reset></FormButtonGroup.FormItem>
Schema 布局组件
{"form": {"labelCol": 6,"wrapperCol": 12},"schema": {"type": "object","properties": {"Card": {"type": "void","x-component": "Card","x-component-props": {"title": "Title"},"x-designable-id": "t314h0wlzod","x-index": 0,"name": "Card"},"FormGrid": {"type": "void","x-component": "FormGrid","x-validator": [],"x-component-props": {},"x-designable-id": "qj9hsdlvqba","x-index": 1,"name": "FormGrid","properties": {"a787t95qcjs": {"type": "void","x-component": "FormGrid.GridColumn","x-designable-id": "a787t95qcjs","x-index": 0,"x-validator": [],"x-component-props": {}},"6kl7ga0rcnq": {"type": "void","x-component": "FormGrid.GridColumn","x-designable-id": "6kl7ga0rcnq","x-index": 1,"x-validator": [],"x-component-props": {}},"u6ro1e35o80": {"type": "void","x-component": "FormGrid.GridColumn","x-designable-id": "u6ro1e35o80","x-index": 2}}},"FormTab": {"type": "void","x-component": "FormTab","x-component-props": {},"x-designable-id": "8c2mnbk6hiq","x-index": 2,"name": "FormTab"},"FormLayout": {"type": "void","x-component": "FormLayout","x-component-props": {},"x-designable-id": "gfgbyrhi79d","x-index": 3,"name": "FormLayout"},"FormCollapse": {"type": "void","x-component": "FormCollapse","x-component-props": {},"x-designable-id": "u5u4qceqlaf","x-index": 4,"name": "FormCollapse"},"Space": {"type": "void","x-component": "Space","x-component-props": {},"x-designable-id": "07n7b4hci88","x-index": 5,"name": "Space"},"ArrayCards": {"type": "array","x-decorator": "FormItem","x-component": "ArrayCards","x-component-props": {"title": "Title"},"x-validator": [],"x-decorator-props": {},"x-designable-id": "r2w52bn19xd","x-index": 6,"name": "ArrayCards"},"ArrayTable": {"type": "array","x-decorator": "FormItem","x-component": "ArrayTable","x-validator": [],"x-component-props": {},"x-decorator-props": {},"x-designable-id": "pe6gw36zheg","x-index": 7,"name": "ArrayTable"}},"x-designable-id": "zrpvzy8mza3"}}

输入组件
- Input
- Password
- Select
- TreeSelect
- DatePicker
- TimePicker
- NumberPicker
- Transfer
- Cascader
- Radio
- Checkbox
- Upload
- Switch
- SelectTable
场景组件
- ArrayBase
- ArrayCards 卡片里面的表单
- ArrayItems
- ArrayTable
- SelectTable
- ArrayTabs 选项卡
- ArrayCollapse 手风琴表单
- FormCollapse
- FormStep 分步表单
- FormTab 选项卡表单
- FormDialog
- FormDrawer
- Editable
只支持 Schema模式
ArrayCards/ArrayTable/FormStep 这类组件只支持 Schema 模式,不支持纯 JSX 模式
- JSONSchema 可以做到场景化抽象
- JSX 模式,受限于 JSX 的不可解析性,很难做到 UI 级别的场景化抽象
ArrayItems

ArrayTable

SelectTable

Editable

阅读态组件
PreviewText
