@teamix/pro 1.0.22 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/all.css +1 -1
- package/dist/all.js +12421 -13334
- package/dist/all.min.css +1 -1
- package/dist/all.min.js +1 -1
- package/es/actions/base.d.ts +13 -0
- package/es/actions/base.js +23 -0
- package/es/actions/confirm.d.ts +7 -0
- package/es/actions/confirm.js +11 -0
- package/es/actions/danger-confirm.d.ts +7 -0
- package/es/actions/danger-confirm.js +14 -0
- package/es/actions/dialog-component.d.ts +10 -0
- package/es/actions/dialog-component.js +25 -0
- package/es/actions/dialog-form.d.ts +15 -0
- package/es/actions/dialog-form.js +129 -0
- package/es/actions/dialog-table.d.ts +4 -0
- package/es/actions/dialog-table.js +1 -0
- package/es/actions/dialog.d.ts +17 -0
- package/es/actions/dialog.js +197 -0
- package/es/actions/drawer-form.d.ts +6 -0
- package/es/actions/drawer-form.js +7 -0
- package/es/actions/drawer-table.d.ts +2 -0
- package/es/actions/drawer-table.js +1 -0
- package/es/actions/drawer.d.ts +6 -0
- package/es/actions/drawer.js +7 -0
- package/es/actions/error.d.ts +7 -0
- package/es/actions/error.js +11 -0
- package/es/actions/index.d.ts +76 -0
- package/es/actions/index.js +317 -0
- package/es/actions/index.scss +34 -0
- package/es/actions/link.d.ts +14 -0
- package/es/actions/link.js +45 -0
- package/es/actions/notice.d.ts +7 -0
- package/es/actions/notice.js +11 -0
- package/es/actions/request.d.ts +9 -0
- package/es/actions/request.js +60 -0
- package/es/card/index.d.ts +30 -0
- package/es/card/index.js +159 -0
- package/es/card/index.scss +98 -0
- package/es/field/index.d.ts +3 -0
- package/es/field/index.js +3 -0
- package/es/form/Components/Editable/index.d.ts +20 -0
- package/es/form/Components/Editable/index.js +228 -0
- package/es/form/Components/FormGroup/index.d.ts +13 -0
- package/es/form/Components/FormGroup/index.js +89 -0
- package/es/form/Components/FormGroup/index.scss +23 -0
- package/es/form/Components/ProField/index.d.ts +150 -0
- package/es/form/Components/ProField/index.js +53 -0
- package/es/form/Components/Query/index.d.ts +4 -0
- package/es/form/Components/Query/index.js +70 -0
- package/es/form/Components/Query/index.scss +90 -0
- package/es/form/Components/QueryFilter/index.d.ts +3 -0
- package/es/form/Components/QueryFilter/index.js +111 -0
- package/es/form/Components/Search/index.d.ts +11 -0
- package/es/form/Components/Search/index.js +89 -0
- package/es/form/Filter/index.d.ts +16 -0
- package/es/form/Filter/index.js +218 -0
- package/es/form/ProForm/index.d.ts +5 -0
- package/es/form/ProForm/index.js +100 -0
- package/es/form/ProForm/index.scss +248 -0
- package/es/form/SchemaForm/adapterComponent.d.ts +5 -0
- package/es/form/SchemaForm/adapterComponent.js +17 -0
- package/es/form/SchemaForm/adapterDecorator.d.ts +6 -0
- package/es/form/SchemaForm/adapterDecorator.js +28 -0
- package/es/form/SchemaForm/adapterType.d.ts +5 -0
- package/es/form/SchemaForm/adapterType.js +54 -0
- package/es/form/SchemaForm/index.d.ts +4 -0
- package/es/form/SchemaForm/index.js +258 -0
- package/es/form/SchemaForm/initializeArrayCards.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayCards.js +69 -0
- package/es/form/SchemaForm/initializeArrayCollapse.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayCollapse.js +78 -0
- package/es/form/SchemaForm/initializeArrayIcon.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayIcon.js +50 -0
- package/es/form/SchemaForm/initializeArrayItems.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayItems.js +97 -0
- package/es/form/SchemaForm/initializeArrayTable.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayTable.js +66 -0
- package/es/form/SchemaForm/initializeFormButton.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormButton.js +75 -0
- package/es/form/SchemaForm/initializeFormCollapse.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormCollapse.js +43 -0
- package/es/form/SchemaForm/initializeFormGroup.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormGroup.js +46 -0
- package/es/form/SchemaForm/initializeFormStep.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormStep.js +48 -0
- package/es/form/SchemaForm/initializeFormTab.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormTab.js +53 -0
- package/es/form/SchemaForm/initializeProField.d.ts +5 -0
- package/es/form/SchemaForm/initializeProField.js +69 -0
- package/es/form/SchemaForm/initializeRequest.d.ts +11 -0
- package/es/form/SchemaForm/initializeRequest.js +25 -0
- package/es/form/SchemaForm/reactions.d.ts +4 -0
- package/es/form/SchemaForm/reactions.js +62 -0
- package/es/form/index.d.ts +20 -0
- package/es/form/index.js +24 -0
- package/es/form/typing.d.ts +78 -0
- package/es/form/typing.js +1 -0
- package/es/form/utils.d.ts +9 -0
- package/es/form/utils.js +108 -0
- package/es/form/warning.d.ts +3 -0
- package/es/form/warning.js +20 -0
- package/es/hooks/index.d.ts +2 -0
- package/es/hooks/index.js +2 -0
- package/es/index.d.ts +24 -22
- package/es/index.js +25 -23
- package/es/info/components/FormItem/index.d.ts +5 -0
- package/es/info/components/FormItem/index.js +63 -0
- package/es/info/components/FormItem/index.scss +49 -0
- package/es/info/components/InfoGroup/index.d.ts +5 -0
- package/es/info/components/InfoGroup/index.js +16 -0
- package/es/info/components/InfoGroup/index.scss +8 -0
- package/es/info/components/InfoValueItem/index.d.ts +5 -0
- package/es/info/components/InfoValueItem/index.js +211 -0
- package/es/info/components/InfoValueItem/index.scss +21 -0
- package/es/info/components/baseInfo/index.d.ts +7 -0
- package/es/info/components/baseInfo/index.js +72 -0
- package/es/info/components/baseInfo/index.scss +3 -0
- package/es/info/components/headerInfo/index.d.ts +7 -0
- package/es/info/components/headerInfo/index.js +84 -0
- package/es/info/components/headerInfo/index.scss +0 -0
- package/es/info/components/tableInfo/index.d.ts +8 -0
- package/es/info/components/tableInfo/index.js +172 -0
- package/es/info/components/tableInfo/index.scss +18 -0
- package/es/info/index.d.ts +9 -0
- package/es/info/index.js +85 -0
- package/es/info/index.scss +8 -0
- package/es/info/typing.d.ts +143 -0
- package/es/info/typing.js +1 -0
- package/es/info/utils/index.d.ts +3 -0
- package/es/info/utils/index.js +12 -0
- package/es/info/utils/layout.d.ts +2 -0
- package/es/info/utils/layout.js +58 -0
- package/es/info/utils/useInfoRequest.d.ts +14 -0
- package/es/info/utils/useInfoRequest.js +73 -0
- package/es/info/utils/utils.d.ts +1 -0
- package/es/info/utils/utils.js +13 -0
- package/es/layout/index.d.ts +3 -0
- package/es/layout/index.js +3 -0
- package/es/nocode/configurators/Card.d.ts +3 -0
- package/es/nocode/configurators/Card.js +109 -0
- package/es/nocode/configurators/PageHeader.d.ts +3 -0
- package/es/nocode/configurators/PageHeader.js +196 -0
- package/es/nocode/configurators/ProTable.d.ts +3 -0
- package/es/nocode/configurators/ProTable.js +317 -0
- package/es/nocode/configurators/common.d.ts +176 -0
- package/es/nocode/configurators/common.js +314 -0
- package/es/nocode/configurators/index.d.ts +15 -0
- package/es/nocode/configurators/index.js +27 -0
- package/es/nocode/configurators/map.d.ts +2 -0
- package/es/nocode/configurators/map.js +8 -0
- package/es/nocode/index.d.ts +8 -0
- package/es/nocode/index.js +11 -0
- package/es/nocode/index.scss +93 -0
- package/es/nocode/pages/editor.d.ts +12 -0
- package/es/nocode/pages/editor.js +40 -0
- package/es/nocode/pages/index.d.ts +14 -0
- package/es/nocode/pages/index.js +41 -0
- package/es/nocode/pages/playground.d.ts +11 -0
- package/es/nocode/pages/playground.js +130 -0
- package/es/nocode/pages/renderer.d.ts +10 -0
- package/es/nocode/pages/renderer.js +144 -0
- package/es/nocode/playground.d.ts +14 -0
- package/es/nocode/playground.js +68 -0
- package/es/page-container/index.d.ts +3 -0
- package/es/page-container/index.js +3 -0
- package/es/page-header/index.d.ts +42 -0
- package/es/page-header/index.js +222 -0
- package/es/page-header/index.scss +171 -0
- package/es/skeleton/index.d.ts +3 -0
- package/es/skeleton/index.js +3 -0
- package/es/table/components/Filter/index.d.ts +9 -0
- package/es/table/components/Filter/index.js +231 -0
- package/es/table/components/Filter/index.scss +23 -0
- package/es/table/components/Layout/index.d.ts +5 -0
- package/es/table/components/Layout/index.js +241 -0
- package/es/table/components/Layout/index.scss +39 -0
- package/es/table/components/QuickAction/index.d.ts +10 -0
- package/es/table/components/QuickAction/index.js +53 -0
- package/es/table/components/QuickAction/index.scss +0 -0
- package/es/table/components/ToolBar/DensityIcon.d.ts +4 -0
- package/es/table/components/ToolBar/DensityIcon.js +117 -0
- package/es/table/components/ToolBar/FilterColumnIcon.d.ts +4 -0
- package/es/table/components/ToolBar/FilterColumnIcon.js +284 -0
- package/es/table/components/ToolBar/FullScreenIcon.d.ts +4 -0
- package/es/table/components/ToolBar/FullScreenIcon.js +89 -0
- package/es/table/components/ToolBar/Fullscreen.d.ts +10 -0
- package/es/table/components/ToolBar/Fullscreen.js +68 -0
- package/es/table/components/ToolBar/RefreshIcon.d.ts +4 -0
- package/es/table/components/ToolBar/RefreshIcon.js +45 -0
- package/es/table/components/ToolBar/index.d.ts +5 -0
- package/es/table/components/ToolBar/index.js +79 -0
- package/es/table/components/ToolBar/index.scss +110 -0
- package/es/table/index.d.ts +7 -0
- package/es/table/index.js +620 -0
- package/es/table/index.scss +104 -0
- package/es/table/typing.d.ts +222 -0
- package/es/table/typing.js +1 -0
- package/es/table/utils/columnRender.d.ts +13 -0
- package/es/table/utils/columnRender.js +185 -0
- package/es/table/utils/genProColumnToColumn.d.ts +9 -0
- package/es/table/utils/genProColumnToColumn.js +51 -0
- package/es/table/utils/getTableProps.d.ts +2 -0
- package/es/table/utils/getTableProps.js +4 -0
- package/es/table/utils/getTableSortIcons.d.ts +3 -0
- package/es/table/utils/getTableSortIcons.js +21 -0
- package/es/table/utils/index.d.ts +4 -0
- package/es/table/utils/index.js +100 -0
- package/es/table/utils/useTableSelection.d.ts +3 -0
- package/es/table/utils/useTableSelection.js +107 -0
- package/es/templates/Detail/index.d.ts +2 -0
- package/es/templates/Detail/index.js +5 -0
- package/es/templates/Detail/index.scss +3 -0
- package/es/templates/Form/index.d.ts +2 -0
- package/es/templates/Form/index.js +5 -0
- package/es/templates/Form/index.scss +3 -0
- package/es/templates/List/index.d.ts +9 -0
- package/es/templates/List/index.js +45 -0
- package/es/templates/List/index.scss +3 -0
- package/es/templates/index.d.ts +5 -0
- package/es/templates/index.js +7 -0
- package/es/templates/index.scss +3 -0
- package/es/utils/index.d.ts +2 -0
- package/es/utils/index.js +2 -0
- package/lib/actions/base.d.ts +13 -0
- package/lib/actions/base.js +33 -0
- package/lib/actions/confirm.d.ts +7 -0
- package/lib/actions/confirm.js +25 -0
- package/lib/actions/danger-confirm.d.ts +7 -0
- package/lib/actions/danger-confirm.js +28 -0
- package/lib/actions/dialog-component.d.ts +10 -0
- package/lib/actions/dialog-component.js +39 -0
- package/lib/actions/dialog-form.d.ts +15 -0
- package/lib/actions/dialog-form.js +152 -0
- package/lib/actions/dialog-table.d.ts +4 -0
- package/lib/actions/dialog-table.js +5 -0
- package/lib/actions/dialog.d.ts +17 -0
- package/lib/actions/dialog.js +219 -0
- package/lib/actions/drawer-form.d.ts +6 -0
- package/lib/actions/drawer-form.js +18 -0
- package/lib/actions/drawer-table.d.ts +2 -0
- package/lib/actions/drawer-table.js +5 -0
- package/lib/actions/drawer.d.ts +6 -0
- package/lib/actions/drawer.js +20 -0
- package/lib/actions/error.d.ts +7 -0
- package/lib/actions/error.js +25 -0
- package/lib/actions/index.d.ts +76 -0
- package/lib/actions/index.js +356 -0
- package/lib/actions/index.scss +34 -0
- package/lib/actions/link.d.ts +14 -0
- package/lib/actions/link.js +60 -0
- package/lib/actions/notice.d.ts +7 -0
- package/lib/actions/notice.js +25 -0
- package/lib/actions/request.d.ts +9 -0
- package/lib/actions/request.js +75 -0
- package/lib/card/index.d.ts +30 -0
- package/lib/card/index.js +179 -0
- package/lib/card/index.scss +98 -0
- package/lib/field/index.d.ts +3 -0
- package/lib/field/index.js +30 -0
- package/lib/form/Components/Editable/index.d.ts +20 -0
- package/lib/form/Components/Editable/index.js +251 -0
- package/lib/form/Components/FormGroup/index.d.ts +13 -0
- package/lib/form/Components/FormGroup/index.js +103 -0
- package/lib/form/Components/FormGroup/index.scss +23 -0
- package/lib/form/Components/ProField/index.d.ts +150 -0
- package/lib/form/Components/ProField/index.js +68 -0
- package/lib/form/Components/Query/index.d.ts +4 -0
- package/lib/form/Components/Query/index.js +91 -0
- package/lib/form/Components/Query/index.scss +90 -0
- package/lib/form/Components/QueryFilter/index.d.ts +3 -0
- package/lib/form/Components/QueryFilter/index.js +130 -0
- package/lib/form/Components/Search/index.d.ts +11 -0
- package/lib/form/Components/Search/index.js +103 -0
- package/lib/form/Filter/index.d.ts +16 -0
- package/lib/form/Filter/index.js +242 -0
- package/lib/form/ProForm/index.d.ts +5 -0
- package/lib/form/ProForm/index.js +125 -0
- package/lib/form/ProForm/index.scss +248 -0
- package/lib/form/SchemaForm/adapterComponent.d.ts +5 -0
- package/lib/form/SchemaForm/adapterComponent.js +27 -0
- package/lib/form/SchemaForm/adapterDecorator.d.ts +6 -0
- package/lib/form/SchemaForm/adapterDecorator.js +34 -0
- package/lib/form/SchemaForm/adapterType.d.ts +5 -0
- package/lib/form/SchemaForm/adapterType.js +64 -0
- package/lib/form/SchemaForm/index.d.ts +4 -0
- package/lib/form/SchemaForm/index.js +301 -0
- package/lib/form/SchemaForm/initializeArrayCards.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayCards.js +76 -0
- package/lib/form/SchemaForm/initializeArrayCollapse.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayCollapse.js +85 -0
- package/lib/form/SchemaForm/initializeArrayIcon.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayIcon.js +61 -0
- package/lib/form/SchemaForm/initializeArrayItems.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayItems.js +104 -0
- package/lib/form/SchemaForm/initializeArrayTable.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayTable.js +73 -0
- package/lib/form/SchemaForm/initializeFormButton.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormButton.js +82 -0
- package/lib/form/SchemaForm/initializeFormCollapse.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormCollapse.js +50 -0
- package/lib/form/SchemaForm/initializeFormGroup.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormGroup.js +53 -0
- package/lib/form/SchemaForm/initializeFormStep.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormStep.js +55 -0
- package/lib/form/SchemaForm/initializeFormTab.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormTab.js +60 -0
- package/lib/form/SchemaForm/initializeProField.d.ts +5 -0
- package/lib/form/SchemaForm/initializeProField.js +76 -0
- package/lib/form/SchemaForm/initializeRequest.d.ts +11 -0
- package/lib/form/SchemaForm/initializeRequest.js +34 -0
- package/lib/form/SchemaForm/reactions.d.ts +4 -0
- package/lib/form/SchemaForm/reactions.js +72 -0
- package/lib/form/index.d.ts +20 -0
- package/lib/form/index.js +149 -0
- package/lib/form/typing.d.ts +78 -0
- package/lib/form/typing.js +5 -0
- package/lib/form/utils.d.ts +9 -0
- package/lib/form/utils.js +124 -0
- package/lib/form/warning.d.ts +3 -0
- package/lib/form/warning.js +28 -0
- package/lib/hooks/index.d.ts +2 -0
- package/lib/hooks/index.js +17 -0
- package/lib/index.d.ts +24 -22
- package/lib/index.js +84 -57
- package/lib/info/components/FormItem/index.d.ts +5 -0
- package/lib/info/components/FormItem/index.js +78 -0
- package/lib/info/components/FormItem/index.scss +49 -0
- package/lib/info/components/InfoGroup/index.d.ts +5 -0
- package/lib/info/components/InfoGroup/index.js +27 -0
- package/lib/info/components/InfoGroup/index.scss +8 -0
- package/lib/info/components/InfoValueItem/index.d.ts +5 -0
- package/lib/info/components/InfoValueItem/index.js +237 -0
- package/lib/info/components/InfoValueItem/index.scss +21 -0
- package/lib/info/components/baseInfo/index.d.ts +7 -0
- package/lib/info/components/baseInfo/index.js +99 -0
- package/lib/info/components/baseInfo/index.scss +3 -0
- package/lib/info/components/headerInfo/index.d.ts +7 -0
- package/lib/info/components/headerInfo/index.js +111 -0
- package/lib/info/components/headerInfo/index.scss +0 -0
- package/lib/info/components/tableInfo/index.d.ts +8 -0
- package/lib/info/components/tableInfo/index.js +193 -0
- package/lib/info/components/tableInfo/index.scss +18 -0
- package/lib/info/index.d.ts +9 -0
- package/lib/info/index.js +121 -0
- package/lib/info/index.scss +8 -0
- package/lib/info/typing.d.ts +143 -0
- package/lib/info/typing.js +5 -0
- package/lib/info/utils/index.d.ts +3 -0
- package/lib/info/utils/index.js +19 -0
- package/lib/info/utils/layout.d.ts +2 -0
- package/lib/info/utils/layout.js +65 -0
- package/lib/info/utils/useInfoRequest.d.ts +14 -0
- package/lib/info/utils/useInfoRequest.js +82 -0
- package/lib/info/utils/utils.d.ts +1 -0
- package/lib/info/utils/utils.js +20 -0
- package/lib/layout/index.d.ts +3 -0
- package/lib/layout/index.js +30 -0
- package/lib/nocode/configurators/Card.d.ts +3 -0
- package/lib/nocode/configurators/Card.js +116 -0
- package/lib/nocode/configurators/PageHeader.d.ts +3 -0
- package/lib/nocode/configurators/PageHeader.js +205 -0
- package/lib/nocode/configurators/ProTable.d.ts +3 -0
- package/lib/nocode/configurators/ProTable.js +326 -0
- package/lib/nocode/configurators/common.d.ts +176 -0
- package/lib/nocode/configurators/common.js +325 -0
- package/lib/nocode/configurators/index.d.ts +15 -0
- package/lib/nocode/configurators/index.js +44 -0
- package/lib/nocode/configurators/map.d.ts +2 -0
- package/lib/nocode/configurators/map.js +21 -0
- package/lib/nocode/index.d.ts +8 -0
- package/lib/nocode/index.js +76 -0
- package/lib/nocode/index.scss +93 -0
- package/lib/nocode/pages/editor.d.ts +12 -0
- package/lib/nocode/pages/editor.js +58 -0
- package/lib/nocode/pages/index.d.ts +14 -0
- package/lib/nocode/pages/index.js +93 -0
- package/lib/nocode/pages/playground.d.ts +11 -0
- package/lib/nocode/pages/playground.js +158 -0
- package/lib/nocode/pages/renderer.d.ts +10 -0
- package/lib/nocode/pages/renderer.js +164 -0
- package/lib/nocode/playground.d.ts +14 -0
- package/lib/nocode/playground.js +91 -0
- package/lib/page-container/index.d.ts +3 -0
- package/lib/page-container/index.js +30 -0
- package/lib/page-header/index.d.ts +42 -0
- package/lib/page-header/index.js +240 -0
- package/lib/page-header/index.scss +171 -0
- package/lib/skeleton/index.d.ts +3 -0
- package/lib/skeleton/index.js +30 -0
- package/lib/table/components/Filter/index.d.ts +9 -0
- package/lib/table/components/Filter/index.js +252 -0
- package/lib/table/components/Filter/index.scss +23 -0
- package/lib/table/components/Layout/index.d.ts +5 -0
- package/lib/table/components/Layout/index.js +265 -0
- package/lib/table/components/Layout/index.scss +39 -0
- package/lib/table/components/QuickAction/index.d.ts +10 -0
- package/lib/table/components/QuickAction/index.js +65 -0
- package/lib/table/components/QuickAction/index.scss +0 -0
- package/lib/table/components/ToolBar/DensityIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/DensityIcon.js +135 -0
- package/lib/table/components/ToolBar/FilterColumnIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/FilterColumnIcon.js +303 -0
- package/lib/table/components/ToolBar/FullScreenIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/FullScreenIcon.js +107 -0
- package/lib/table/components/ToolBar/Fullscreen.d.ts +10 -0
- package/lib/table/components/ToolBar/Fullscreen.js +85 -0
- package/lib/table/components/ToolBar/RefreshIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/RefreshIcon.js +60 -0
- package/lib/table/components/ToolBar/index.d.ts +5 -0
- package/lib/table/components/ToolBar/index.js +96 -0
- package/lib/table/components/ToolBar/index.scss +110 -0
- package/lib/table/index.d.ts +7 -0
- package/lib/table/index.js +681 -0
- package/lib/table/index.scss +104 -0
- package/lib/table/typing.d.ts +222 -0
- package/lib/table/typing.js +5 -0
- package/lib/table/utils/columnRender.d.ts +13 -0
- package/lib/table/utils/columnRender.js +201 -0
- package/lib/table/utils/genProColumnToColumn.d.ts +9 -0
- package/lib/table/utils/genProColumnToColumn.js +62 -0
- package/lib/table/utils/getTableProps.d.ts +2 -0
- package/lib/table/utils/getTableProps.js +13 -0
- package/lib/table/utils/getTableSortIcons.d.ts +3 -0
- package/lib/table/utils/getTableSortIcons.js +34 -0
- package/lib/table/utils/index.d.ts +4 -0
- package/lib/table/utils/index.js +112 -0
- package/lib/table/utils/useTableSelection.d.ts +3 -0
- package/lib/table/utils/useTableSelection.js +112 -0
- package/lib/templates/Detail/index.d.ts +2 -0
- package/lib/templates/Detail/index.js +18 -0
- package/lib/templates/Detail/index.scss +3 -0
- package/lib/templates/Form/index.d.ts +2 -0
- package/lib/templates/Form/index.js +18 -0
- package/lib/templates/Form/index.scss +3 -0
- package/lib/templates/List/index.d.ts +9 -0
- package/lib/templates/List/index.js +67 -0
- package/lib/templates/List/index.scss +3 -0
- package/lib/templates/index.d.ts +5 -0
- package/lib/templates/index.js +59 -0
- package/lib/templates/index.scss +3 -0
- package/lib/utils/index.d.ts +2 -0
- package/lib/utils/index.js +17 -0
- package/package.json +21 -11
@@ -0,0 +1,73 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
var _excluded = ["title", "decoratorProps"],
|
8
|
+
_excluded2 = ["props", "children", "items"];
|
9
|
+
|
10
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
11
|
+
|
12
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
13
|
+
|
14
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
15
|
+
|
16
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
17
|
+
|
18
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
19
|
+
|
20
|
+
var initializeChildren = function initializeChildren(item) {
|
21
|
+
return _objectSpread(_objectSpread({}, item), {}, {
|
22
|
+
component: 'ArrayTable.Addition'
|
23
|
+
});
|
24
|
+
};
|
25
|
+
|
26
|
+
var initializeColumn = function initializeColumn(item) {
|
27
|
+
var title = item.title,
|
28
|
+
decoratorProps = item.decoratorProps,
|
29
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
30
|
+
|
31
|
+
return _objectSpread(_objectSpread({}, otherProps), {}, {
|
32
|
+
component: 'ArrayTable.Column',
|
33
|
+
props: _objectSpread(_objectSpread({}, decoratorProps), {}, {
|
34
|
+
title: title
|
35
|
+
}),
|
36
|
+
children: [_objectSpread({}, otherProps)]
|
37
|
+
});
|
38
|
+
};
|
39
|
+
|
40
|
+
var initializeItems = function initializeItems(items) {
|
41
|
+
return [{
|
42
|
+
name: 'items',
|
43
|
+
type: 'object',
|
44
|
+
children: items.map(function (item) {
|
45
|
+
return initializeColumn(item);
|
46
|
+
})
|
47
|
+
}];
|
48
|
+
};
|
49
|
+
|
50
|
+
var initialize = function initialize(item) {
|
51
|
+
var _item$props = item.props,
|
52
|
+
props = _item$props === void 0 ? {} : _item$props,
|
53
|
+
_item$children = item.children,
|
54
|
+
children = _item$children === void 0 ? [] : _item$children,
|
55
|
+
_item$items = item.items,
|
56
|
+
items = _item$items === void 0 ? [] : _item$items,
|
57
|
+
otherProps = _objectWithoutProperties(item, _excluded2);
|
58
|
+
|
59
|
+
return _objectSpread(_objectSpread({}, otherProps), {}, {
|
60
|
+
props: _objectSpread({
|
61
|
+
pagination: {
|
62
|
+
pageSize: 10
|
63
|
+
}
|
64
|
+
}, props),
|
65
|
+
children: children.map(function (item) {
|
66
|
+
return initializeChildren(item);
|
67
|
+
}),
|
68
|
+
items: initializeItems(items)
|
69
|
+
});
|
70
|
+
};
|
71
|
+
|
72
|
+
var _default = initialize;
|
73
|
+
exports.default = _default;
|
@@ -0,0 +1,82 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
var _excluded = ["component", "props"],
|
8
|
+
_excluded2 = ["props", "component"];
|
9
|
+
|
10
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
11
|
+
|
12
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
13
|
+
|
14
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
15
|
+
|
16
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
17
|
+
|
18
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
19
|
+
|
20
|
+
var buttonTextMap = {
|
21
|
+
Submit: '提交',
|
22
|
+
Reset: '重置'
|
23
|
+
};
|
24
|
+
|
25
|
+
var initializeButton = function initializeButton(item) {
|
26
|
+
var component = item.component,
|
27
|
+
props = item.props,
|
28
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
29
|
+
|
30
|
+
return _objectSpread({
|
31
|
+
component: component,
|
32
|
+
props: _objectSpread({
|
33
|
+
children: buttonTextMap[component]
|
34
|
+
}, props)
|
35
|
+
}, otherProps);
|
36
|
+
};
|
37
|
+
|
38
|
+
var initialize = function initialize(item) {
|
39
|
+
var _item$props = item.props,
|
40
|
+
props = _item$props === void 0 ? {} : _item$props,
|
41
|
+
component = item.component,
|
42
|
+
otherProps = _objectWithoutProperties(item, _excluded2);
|
43
|
+
|
44
|
+
var sticky = props.sticky,
|
45
|
+
align = props.align,
|
46
|
+
gutter = props.gutter;
|
47
|
+
var alignProps = align ? {
|
48
|
+
align: align
|
49
|
+
} : {};
|
50
|
+
var gutterProps = gutter ? {
|
51
|
+
gutter: gutter
|
52
|
+
} : {};
|
53
|
+
|
54
|
+
if (component && ['Submit', 'Reset'].includes(component)) {
|
55
|
+
return initializeButton(item);
|
56
|
+
}
|
57
|
+
|
58
|
+
var decoratorTemp = {
|
59
|
+
title: ' ',
|
60
|
+
decorator: 'FormButtonGroup.FormItem',
|
61
|
+
decoratorProps: {
|
62
|
+
inset: false
|
63
|
+
},
|
64
|
+
props: _objectSpread(_objectSpread({}, alignProps), gutterProps)
|
65
|
+
};
|
66
|
+
|
67
|
+
if (sticky) {
|
68
|
+
decoratorTemp = {
|
69
|
+
title: '',
|
70
|
+
decorator: 'FormButtonGroup.Sticky',
|
71
|
+
decoratorProps: _objectSpread({}, alignProps),
|
72
|
+
props: _objectSpread({}, gutterProps)
|
73
|
+
};
|
74
|
+
}
|
75
|
+
|
76
|
+
return _objectSpread(_objectSpread({
|
77
|
+
component: component
|
78
|
+
}, decoratorTemp), otherProps);
|
79
|
+
};
|
80
|
+
|
81
|
+
var _default = initialize;
|
82
|
+
exports.default = _default;
|
@@ -0,0 +1,50 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
var _excluded = ["children", "title", "props"],
|
8
|
+
_excluded2 = ["children"];
|
9
|
+
|
10
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
11
|
+
|
12
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
13
|
+
|
14
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
15
|
+
|
16
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
17
|
+
|
18
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
19
|
+
|
20
|
+
var initializeCollapsePanel = function initializeCollapsePanel(item) {
|
21
|
+
var _item$children = item.children,
|
22
|
+
children = _item$children === void 0 ? [] : _item$children,
|
23
|
+
title = item.title,
|
24
|
+
_item$props = item.props,
|
25
|
+
props = _item$props === void 0 ? {} : _item$props,
|
26
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
27
|
+
|
28
|
+
return _objectSpread({
|
29
|
+
component: 'FormCollapse.CollapsePanel',
|
30
|
+
props: _objectSpread({
|
31
|
+
title: title
|
32
|
+
}, props),
|
33
|
+
children: children
|
34
|
+
}, otherProps);
|
35
|
+
};
|
36
|
+
|
37
|
+
var initialize = function initialize(item) {
|
38
|
+
var _item$children2 = item.children,
|
39
|
+
children = _item$children2 === void 0 ? [] : _item$children2,
|
40
|
+
otherProps = _objectWithoutProperties(item, _excluded2);
|
41
|
+
|
42
|
+
return _objectSpread({
|
43
|
+
children: children.map(function (item) {
|
44
|
+
return initializeCollapsePanel(item);
|
45
|
+
})
|
46
|
+
}, otherProps);
|
47
|
+
};
|
48
|
+
|
49
|
+
var _default = initialize;
|
50
|
+
exports.default = _default;
|
@@ -0,0 +1,53 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
var _excluded = ["props", "children", "title"],
|
8
|
+
_excluded2 = ["props", "children"];
|
9
|
+
|
10
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
11
|
+
|
12
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
13
|
+
|
14
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
15
|
+
|
16
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
17
|
+
|
18
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
19
|
+
|
20
|
+
var initializeGroupPanel = function initializeGroupPanel(item) {
|
21
|
+
var _item$props = item.props,
|
22
|
+
props = _item$props === void 0 ? {} : _item$props,
|
23
|
+
_item$children = item.children,
|
24
|
+
children = _item$children === void 0 ? [] : _item$children,
|
25
|
+
title = item.title,
|
26
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
27
|
+
|
28
|
+
return _objectSpread({
|
29
|
+
component: 'FormGroup.GroupPanel',
|
30
|
+
props: _objectSpread({
|
31
|
+
title: title
|
32
|
+
}, props),
|
33
|
+
children: children
|
34
|
+
}, otherProps);
|
35
|
+
};
|
36
|
+
|
37
|
+
var initialize = function initialize(item) {
|
38
|
+
var _item$props2 = item.props,
|
39
|
+
props = _item$props2 === void 0 ? {} : _item$props2,
|
40
|
+
_item$children2 = item.children,
|
41
|
+
children = _item$children2 === void 0 ? [] : _item$children2,
|
42
|
+
otherProps = _objectWithoutProperties(item, _excluded2);
|
43
|
+
|
44
|
+
return _objectSpread({
|
45
|
+
props: props,
|
46
|
+
children: children.map(function (item) {
|
47
|
+
return initializeGroupPanel(item);
|
48
|
+
})
|
49
|
+
}, otherProps);
|
50
|
+
};
|
51
|
+
|
52
|
+
var _default = initialize;
|
53
|
+
exports.default = _default;
|
@@ -0,0 +1,55 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
var _excluded = ["props", "children", "title"],
|
8
|
+
_excluded2 = ["props", "children"];
|
9
|
+
|
10
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
11
|
+
|
12
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
13
|
+
|
14
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
15
|
+
|
16
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
17
|
+
|
18
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
19
|
+
|
20
|
+
var initializeStepPane = function initializeStepPane(item) {
|
21
|
+
var _item$props = item.props,
|
22
|
+
props = _item$props === void 0 ? {} : _item$props,
|
23
|
+
_item$children = item.children,
|
24
|
+
children = _item$children === void 0 ? [] : _item$children,
|
25
|
+
title = item.title,
|
26
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
27
|
+
|
28
|
+
return _objectSpread({
|
29
|
+
component: 'FormStep.StepPane',
|
30
|
+
props: _objectSpread({
|
31
|
+
title: title
|
32
|
+
}, props),
|
33
|
+
children: children
|
34
|
+
}, otherProps);
|
35
|
+
};
|
36
|
+
|
37
|
+
var initialize = function initialize(item) {
|
38
|
+
var _item$props2 = item.props,
|
39
|
+
props = _item$props2 === void 0 ? {} : _item$props2,
|
40
|
+
_item$children2 = item.children,
|
41
|
+
children = _item$children2 === void 0 ? [] : _item$children2,
|
42
|
+
otherProps = _objectWithoutProperties(item, _excluded2);
|
43
|
+
|
44
|
+
return _objectSpread({
|
45
|
+
props: _objectSpread({
|
46
|
+
labelPlacement: 'hoz'
|
47
|
+
}, props),
|
48
|
+
children: children.map(function (item) {
|
49
|
+
return initializeStepPane(item);
|
50
|
+
})
|
51
|
+
}, otherProps);
|
52
|
+
};
|
53
|
+
|
54
|
+
var _default = initialize;
|
55
|
+
exports.default = _default;
|
@@ -0,0 +1,60 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
var _excluded = ["props", "children", "title"],
|
8
|
+
_excluded2 = ["props", "children"];
|
9
|
+
|
10
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
11
|
+
|
12
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
13
|
+
|
14
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
15
|
+
|
16
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
17
|
+
|
18
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
19
|
+
|
20
|
+
var initializeTabPane = function initializeTabPane(item) {
|
21
|
+
var _item$props = item.props,
|
22
|
+
props = _item$props === void 0 ? {} : _item$props,
|
23
|
+
_item$children = item.children,
|
24
|
+
children = _item$children === void 0 ? [] : _item$children,
|
25
|
+
title = item.title,
|
26
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
27
|
+
|
28
|
+
return _objectSpread({
|
29
|
+
component: 'FormTab.TabPane',
|
30
|
+
props: _objectSpread({
|
31
|
+
tab: title
|
32
|
+
}, props),
|
33
|
+
children: children
|
34
|
+
}, otherProps);
|
35
|
+
};
|
36
|
+
|
37
|
+
var initialize = function initialize(item) {
|
38
|
+
var _item$props2 = item.props,
|
39
|
+
props = _item$props2 === void 0 ? {} : _item$props2,
|
40
|
+
_item$children2 = item.children,
|
41
|
+
children = _item$children2 === void 0 ? [] : _item$children2,
|
42
|
+
otherProps = _objectWithoutProperties(item, _excluded2);
|
43
|
+
|
44
|
+
return _objectSpread({
|
45
|
+
props: _objectSpread({
|
46
|
+
navStyle: {
|
47
|
+
lineHeight: 1.5
|
48
|
+
},
|
49
|
+
contentStyle: {
|
50
|
+
paddingTop: 16
|
51
|
+
}
|
52
|
+
}, props),
|
53
|
+
children: children.map(function (item) {
|
54
|
+
return initializeTabPane(item);
|
55
|
+
})
|
56
|
+
}, otherProps);
|
57
|
+
};
|
58
|
+
|
59
|
+
var _default = initialize;
|
60
|
+
exports.default = _default;
|
@@ -0,0 +1,76 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.proFieldTypeMap = exports.default = void 0;
|
7
|
+
var _excluded = ["component", "props"];
|
8
|
+
|
9
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
10
|
+
|
11
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
12
|
+
|
13
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
14
|
+
|
15
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
16
|
+
|
17
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
18
|
+
|
19
|
+
var proFieldTypeMap = {
|
20
|
+
Input: 'text',
|
21
|
+
Password: 'password',
|
22
|
+
TextArea: 'textArea',
|
23
|
+
NumberPicker: 'number',
|
24
|
+
Percent: 'percent',
|
25
|
+
Money: 'money',
|
26
|
+
Select: 'select',
|
27
|
+
MultipleSelect: 'multipleSelect',
|
28
|
+
TreeSelect: 'treeSelect',
|
29
|
+
Cascader: 'cascader',
|
30
|
+
MultipleCascader: 'multipleCascader',
|
31
|
+
ArbitraryCascader: 'arbitraryCascader',
|
32
|
+
Radio: 'radio',
|
33
|
+
Checkbox: 'checkbox',
|
34
|
+
Switch: 'switch',
|
35
|
+
DatePicker: 'date',
|
36
|
+
TimePicker: 'time',
|
37
|
+
DateTimePicker: 'dateTime',
|
38
|
+
WeekPicker: 'dateWeek',
|
39
|
+
MonthPicker: 'dateMonth',
|
40
|
+
YearPicker: 'dateYear',
|
41
|
+
QuarterPicker: 'dateQuarter',
|
42
|
+
DateRangePicker: 'dateRange',
|
43
|
+
// TimeRangePicker: 'timeRange',
|
44
|
+
DateTimeRangePicker: 'dateTimeRange',
|
45
|
+
WeekRangePicker: 'dateWeekRange',
|
46
|
+
MonthRangePicker: 'dateMonthRange',
|
47
|
+
YearRangePicker: 'dateYearRange',
|
48
|
+
QuarterRangePicker: 'dateQuarterRange',
|
49
|
+
Transfer: 'transfer',
|
50
|
+
ColorPicker: 'color',
|
51
|
+
ColorRadio: 'colorRadio',
|
52
|
+
ColorSwatches: 'colorSwatches',
|
53
|
+
ColorTwitter: 'colorTwitter',
|
54
|
+
IconPicker: 'icon',
|
55
|
+
JsonInput: 'json',
|
56
|
+
Search: 'search' // Upload: 'upload',
|
57
|
+
|
58
|
+
};
|
59
|
+
exports.proFieldTypeMap = proFieldTypeMap;
|
60
|
+
|
61
|
+
var initialize = function initialize(item) {
|
62
|
+
var component = item.component,
|
63
|
+
_item$props = item.props,
|
64
|
+
props = _item$props === void 0 ? {} : _item$props,
|
65
|
+
otherProps = _objectWithoutProperties(item, _excluded);
|
66
|
+
|
67
|
+
return _objectSpread({
|
68
|
+
component: 'ProField',
|
69
|
+
props: _objectSpread({
|
70
|
+
type: proFieldTypeMap[component]
|
71
|
+
}, props)
|
72
|
+
}, otherProps);
|
73
|
+
};
|
74
|
+
|
75
|
+
var _default = initialize;
|
76
|
+
exports.default = _default;
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import type { IRequestConfig } from '../';
|
2
|
+
interface IInitializeRequest {
|
3
|
+
(requestConfig?: IRequestConfig): {
|
4
|
+
reactions: any[];
|
5
|
+
scope: {
|
6
|
+
[x: string]: any;
|
7
|
+
};
|
8
|
+
};
|
9
|
+
}
|
10
|
+
declare const initializeRequest: IInitializeRequest;
|
11
|
+
export default initializeRequest;
|
@@ -0,0 +1,34 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = void 0;
|
7
|
+
|
8
|
+
var _reactions = require("../SchemaForm/reactions");
|
9
|
+
|
10
|
+
var _utils = require("../utils");
|
11
|
+
|
12
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
13
|
+
|
14
|
+
var initializeRequest = function initializeRequest(requestConfig) {
|
15
|
+
if (requestConfig) {
|
16
|
+
var _scope;
|
17
|
+
|
18
|
+
// todo 可根据request的功能类型配置不同内置的方法,如:useAsyncDataSource
|
19
|
+
var requestScopeName = (0, _utils.getRandomName)('$request');
|
20
|
+
var dataSourceScopeName = "$dataSource";
|
21
|
+
return {
|
22
|
+
reactions: ["{{".concat(dataSourceScopeName, "(").concat(requestScopeName, ")}}")],
|
23
|
+
scope: (_scope = {}, _defineProperty(_scope, requestScopeName, (0, _reactions.useRequest)(requestConfig)), _defineProperty(_scope, dataSourceScopeName, _reactions.useAsyncDataSource), _scope)
|
24
|
+
};
|
25
|
+
}
|
26
|
+
|
27
|
+
return {
|
28
|
+
reactions: [],
|
29
|
+
scope: {}
|
30
|
+
};
|
31
|
+
};
|
32
|
+
|
33
|
+
var _default = initializeRequest;
|
34
|
+
exports.default = _default;
|
@@ -0,0 +1,72 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.useRequest = exports.useAsyncDataSource = void 0;
|
7
|
+
|
8
|
+
var _utils = require("@teamix/utils");
|
9
|
+
|
10
|
+
// 配置请求
|
11
|
+
var useRequest = function useRequest(requestConfig) {
|
12
|
+
return function (field) {
|
13
|
+
var url = requestConfig.url,
|
14
|
+
method = requestConfig.method,
|
15
|
+
params = requestConfig.params,
|
16
|
+
data = requestConfig.data,
|
17
|
+
when = requestConfig.when,
|
18
|
+
formatter = requestConfig.formatter,
|
19
|
+
onSuccess = requestConfig.onSuccess,
|
20
|
+
onError = requestConfig.onError;
|
21
|
+
var whenResult = (0, _utils.isFn)(when) ? when(field) : {};
|
22
|
+
|
23
|
+
var _ref = (0, _utils.isObj)(whenResult) ? whenResult : {},
|
24
|
+
newParams = _ref.params,
|
25
|
+
newData = _ref.data;
|
26
|
+
|
27
|
+
if (when && whenResult === false) {
|
28
|
+
return Promise.reject();
|
29
|
+
}
|
30
|
+
|
31
|
+
return (0, _utils.request)({
|
32
|
+
method: method,
|
33
|
+
url: url,
|
34
|
+
params: newParams !== null && newParams !== void 0 ? newParams : params,
|
35
|
+
data: newData !== null && newData !== void 0 ? newData : data
|
36
|
+
}).then(function (data) {
|
37
|
+
// 默认按request返回res.data.data处理
|
38
|
+
var dataSource = formatter ? formatter(data, {
|
39
|
+
paramMap: _utils.paramMap,
|
40
|
+
listToTree: _utils.listToTree
|
41
|
+
}) : data;
|
42
|
+
onSuccess && onSuccess(dataSource, field);
|
43
|
+
return dataSource;
|
44
|
+
}).catch(function (error) {
|
45
|
+
onError && onError(error);
|
46
|
+
return error;
|
47
|
+
});
|
48
|
+
};
|
49
|
+
}; // 配置DataSource
|
50
|
+
|
51
|
+
|
52
|
+
exports.useRequest = useRequest;
|
53
|
+
|
54
|
+
var useAsyncDataSource = function useAsyncDataSource(services) {
|
55
|
+
return function (field) {
|
56
|
+
field.setState({
|
57
|
+
loading: true
|
58
|
+
});
|
59
|
+
services(field).then(function (dataSource) {
|
60
|
+
field.setState({
|
61
|
+
dataSource: dataSource,
|
62
|
+
loading: false
|
63
|
+
});
|
64
|
+
}).catch(function () {
|
65
|
+
field.setState({
|
66
|
+
loading: false
|
67
|
+
});
|
68
|
+
});
|
69
|
+
};
|
70
|
+
};
|
71
|
+
|
72
|
+
exports.useAsyncDataSource = useAsyncDataSource;
|
@@ -0,0 +1,20 @@
|
|
1
|
+
/**
|
2
|
+
* 导出全部 @teamix/formily 方法,支持完全自主定义表单
|
3
|
+
*/
|
4
|
+
export * as formilyCore from '@formily/core';
|
5
|
+
export * as formilyReact from '@formily/react';
|
6
|
+
export * from '@teamix/formily';
|
7
|
+
export * from './Filter';
|
8
|
+
export * from './typing';
|
9
|
+
/**
|
10
|
+
* 导出常用方法等
|
11
|
+
*/
|
12
|
+
import { createForm, registerValidateRules as registerRules, registerValidateFormats as registerFormats, registerValidateLocale, setValidateLanguage } from '@formily/core';
|
13
|
+
import { createSchemaField, Field, FormConsumer } from '@formily/react';
|
14
|
+
import { toJS } from '@formily/reactive';
|
15
|
+
export { createForm, registerRules, registerFormats, registerValidateLocale, setValidateLanguage, Field, createSchemaField, FormConsumer, toJS, };
|
16
|
+
/**
|
17
|
+
* 导出封装的 ProForm 组件,支持快速搭建表单
|
18
|
+
*/
|
19
|
+
import ProForm from './ProForm';
|
20
|
+
export default ProForm;
|