@teamix/pro 1.6.0-beta.4 → 1.6.0-beta.6
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/README.md +1 -1
- package/dist/pro.all.min.css +1 -0
- package/dist/pro.css +1 -1
- package/dist/pro.js +70007 -54355
- package/dist/pro.min.css +1 -1
- package/dist/pro.min.js +1 -1
- package/dist/pro.min.js.LICENSE.txt +9 -0
- package/dist/pro.xconsole.min.css +1 -0
- package/es/actions/base.d.ts +24 -0
- package/es/actions/base.js +1 -1
- package/es/actions/confirm.d.ts +7 -0
- package/es/actions/danger-confirm.d.ts +7 -0
- package/es/actions/danger-pop-confirm.d.ts +5 -0
- package/es/actions/dialog-component.d.ts +10 -0
- package/es/actions/dialog-component.js +4 -1
- package/es/actions/dialog-form.d.ts +29 -0
- package/es/actions/dialog-form.js +8 -8
- package/es/actions/dialog-info.d.ts +9 -0
- package/es/actions/dialog-table.d.ts +9 -0
- package/es/actions/dialog.d.ts +40 -0
- package/es/actions/dialog.js +8 -7
- package/es/actions/drawer-form.d.ts +6 -0
- package/es/actions/drawer-info.d.ts +6 -0
- package/es/actions/drawer-table.d.ts +6 -0
- package/es/actions/drawer.d.ts +6 -0
- package/es/actions/error.d.ts +7 -0
- package/es/actions/index.d.ts +114 -0
- package/es/actions/index.js +69 -60
- package/es/actions/index.scss +10 -1
- package/es/actions/link.d.ts +8 -0
- package/es/actions/link.js +4 -3
- package/es/actions/notice.d.ts +7 -0
- package/es/actions/pop-confirm.d.ts +9 -0
- package/es/actions/quick.d.ts +2 -0
- package/es/actions/quick.js +26 -0
- package/es/actions/request.d.ts +9 -0
- package/es/actions/request.js +4 -3
- package/es/actions/utils.d.ts +1 -0
- package/es/card/card-container.d.ts +18 -0
- package/es/card/card-container.js +5 -12
- package/es/card/divider.d.ts +6 -0
- package/es/card/divider.js +4 -2
- package/es/card/index.d.ts +109 -0
- package/es/card/index.js +11 -22
- package/es/card/index.scss +15 -0
- package/es/card/selectable.d.ts +13 -0
- package/es/card/selectable.js +4 -2
- package/es/card/tab.d.ts +6 -0
- package/es/card/tab.js +4 -2
- package/es/card/utils.d.ts +9 -0
- package/es/card/xconsole.scss +3 -0
- package/es/field/index.d.ts +3 -0
- package/es/form/Components/Editable/index.d.ts +20 -0
- package/es/form/Components/Editable/index.js +2 -2
- package/es/form/Components/FormGroup/index.d.ts +14 -0
- package/es/form/Components/FormGroup/index.js +3 -4
- package/es/form/Components/FormItem2/animation.scss +72 -0
- package/es/form/Components/FormItem2/grid.scss +173 -0
- package/es/form/Components/FormItem2/index.d.ts +41 -0
- package/es/form/Components/FormItem2/index.js +286 -0
- package/es/form/Components/FormItem2/main.scss +413 -0
- package/es/form/Components/FormItem2/scss/variable.scss +118 -0
- package/es/form/Components/FormItem2/style.d.ts +1 -0
- package/es/form/Components/FormItem2/style.js +1 -0
- package/es/form/Components/LightFilter/componentMap.d.ts +3 -0
- package/es/form/Components/LightFilter/index.d.ts +17 -0
- package/es/form/Components/LightFilter/index.js +2 -11
- package/es/form/Components/LightFilter/index.scss +4 -0
- package/es/form/Components/ProField/index.d.ts +2 -0
- package/es/form/Components/ProField/index.js +4 -2
- package/es/form/Components/ProField/mapDateFormat.d.ts +3 -0
- package/es/form/Components/Text/index.d.ts +8 -0
- package/es/form/Components/Text/index.js +4 -2
- package/es/form/Components/__builtins__/empty.d.ts +1 -0
- package/es/form/Components/__builtins__/empty.js +51 -0
- package/es/form/Components/__builtins__/hooks/index.d.ts +2 -0
- package/es/form/Components/__builtins__/hooks/index.js +2 -0
- package/es/form/Components/__builtins__/hooks/useClickAway.d.ts +5 -0
- package/es/form/Components/__builtins__/hooks/useClickAway.js +37 -0
- package/es/form/Components/__builtins__/hooks/usePrefixCls.d.ts +3 -0
- package/es/form/Components/__builtins__/hooks/usePrefixCls.js +8 -0
- package/es/form/Components/__builtins__/icons.d.ts +20 -0
- package/es/form/Components/__builtins__/icons.js +153 -0
- package/es/form/Components/__builtins__/index.d.ts +8 -0
- package/es/form/Components/__builtins__/index.js +8 -0
- package/es/form/Components/__builtins__/loading.d.ts +1 -0
- package/es/form/Components/__builtins__/loading.js +41 -0
- package/es/form/Components/__builtins__/mapSize.d.ts +1 -0
- package/es/form/Components/__builtins__/mapSize.js +13 -0
- package/es/form/Components/__builtins__/mapStatus.d.ts +2 -0
- package/es/form/Components/__builtins__/mapStatus.js +20 -0
- package/es/form/Components/__builtins__/moment.d.ts +2 -0
- package/es/form/Components/__builtins__/moment.js +47 -0
- package/es/form/Components/__builtins__/pickDataProps.d.ts +1 -0
- package/es/form/Components/__builtins__/pickDataProps.js +9 -0
- package/es/form/Components/form-layout/index.d.ts +74 -0
- package/es/form/Components/form-layout/index.js +71 -0
- package/es/form/Components/form-layout/main.scss +0 -0
- package/es/form/Components/form-layout/style.d.ts +1 -0
- package/es/form/Components/form-layout/style.js +3 -0
- package/es/form/Components/form-layout/useResponsiveFormLayout.d.ts +18 -0
- package/es/form/Components/form-layout/useResponsiveFormLayout.js +87 -0
- package/es/form/Filter/AdvancedFilter.d.ts +7 -0
- package/es/form/Filter/AdvancedFilter.js +16 -18
- package/es/form/Filter/Layout.d.ts +5 -0
- package/es/form/Filter/LightFilter.d.ts +7 -0
- package/es/form/Filter/LightFilter.js +9 -13
- package/es/form/Filter/SimpleFilter.d.ts +7 -0
- package/es/form/Filter/SimpleFilter.js +5 -8
- package/es/form/Filter/index.d.ts +9 -0
- package/es/form/Filter/index.js +19 -25
- package/es/form/Filter/index.scss +1 -0
- package/es/form/Filter/index2.d.ts +13 -0
- package/es/form/Filter/index2.js +20 -25
- package/es/form/Filter/index2.scss +1 -0
- package/es/form/Filter/useBindUrl.d.ts +2 -0
- package/es/form/Filter/useBindUrl.js +0 -3
- package/es/form/Filter/useSpecialProps.d.ts +6 -0
- package/es/form/Filter/useSpecialProps.js +0 -1
- package/es/form/ProForm/addCascadeEffect.d.ts +2 -0
- package/es/form/ProForm/customComponent.d.ts +3 -0
- package/es/form/ProForm/index.d.ts +5 -0
- package/es/form/ProForm/index.js +21 -17
- package/es/form/ProForm/useAutoLayout.d.ts +9 -0
- package/es/form/ProForm/useAutoLayout.js +0 -4
- package/es/form/ProForm/useAutoSubmit.d.ts +6 -0
- package/es/form/ProForm/useAutoSubmit.js +4 -3
- package/es/form/ProForm/useFieldRequest.d.ts +5 -0
- package/es/form/ProForm/useFormDisplayValues.d.ts +4 -0
- package/es/form/ProForm/useFormDisplayValues.js +0 -1
- package/es/form/ProForm/useInitialRequest.d.ts +6 -0
- package/es/form/SchemaForm/adapterComponent.d.ts +5 -0
- package/es/form/SchemaForm/adapterComponent.js +0 -1
- package/es/form/SchemaForm/adapterDecorator.d.ts +6 -0
- package/es/form/SchemaForm/adapterDecorator.js +0 -1
- package/es/form/SchemaForm/adapterType.d.ts +5 -0
- package/es/form/SchemaForm/adapterType.js +0 -1
- package/es/form/SchemaForm/index.d.ts +4 -0
- package/es/form/SchemaForm/index.js +0 -13
- package/es/form/SchemaForm/initializeArrayCards.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayCollapse.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayItems.d.ts +3 -0
- package/es/form/SchemaForm/initializeArrayTable.d.ts +3 -0
- package/es/form/SchemaForm/initializeDataSource.d.ts +15 -0
- package/es/form/SchemaForm/initializeDataSource.js +0 -7
- package/es/form/SchemaForm/initializeFormButton.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormButton.js +0 -2
- package/es/form/SchemaForm/initializeFormCollapse.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormGroup.d.ts +3 -0
- package/es/form/SchemaForm/initializeFormStep.d.ts +5 -0
- package/es/form/SchemaForm/initializeFormTab.d.ts +3 -0
- package/es/form/SchemaForm/initializeReactions.d.ts +2 -0
- package/es/form/SchemaForm/initializeReactions.js +0 -1
- package/es/form/SchemaForm/initializeRequest.d.ts +11 -0
- package/es/form/SchemaForm/initializeRules.d.ts +11 -0
- package/es/form/SchemaForm/initializeSelectTable.d.ts +3 -0
- package/es/form/SchemaForm/initializeSelectTable.js +0 -1
- package/es/form/SchemaForm/reactions.d.ts +6 -0
- package/es/form/SchemaForm/reactions.js +0 -5
- package/es/form/docs/ActionResponse.d.ts +8 -0
- package/es/form/fieldTypeMap.d.ts +7 -0
- package/es/form/index.d.ts +125 -0
- package/es/form/index.js +0 -4
- package/es/form/locales/validate.d.ts +159 -0
- package/es/form/schemaNameMap.d.ts +5 -0
- package/es/form/typing.d.ts +194 -0
- package/es/form/utils/parseSchema.d.ts +3 -0
- package/es/form/utils/parseSchema.js +38 -0
- package/es/form/utils.d.ts +55 -0
- package/es/form/utils.js +0 -12
- package/es/form/warning.d.ts +3 -0
- package/es/form/warning.js +0 -2
- package/es/global.scss +3 -1
- package/es/hooks/index.d.ts +2 -0
- package/es/image/index.d.ts +22 -0
- package/es/image/index.js +73 -0
- package/es/image/index.scss +3 -0
- package/es/index-without-icon.d.ts +32 -0
- package/es/index.d.ts +34 -0
- package/es/index.js +14 -3
- package/es/info/components/InfoGroup/index.d.ts +5 -0
- package/es/info/components/InfoGroup/index.js +4 -2
- package/es/info/components/InfoValueItem/index.d.ts +5 -0
- package/es/info/components/InfoValueItem/index.js +20 -32
- package/es/info/components/ProInfoItem/index.d.ts +5 -0
- package/es/info/components/ProInfoItem/index.js +0 -1
- package/es/info/components/baseInfo/index.d.ts +8 -0
- package/es/info/components/baseInfo/index.js +4 -5
- package/es/info/components/headerInfo/index.d.ts +8 -0
- package/es/info/components/tableInfo/index.d.ts +7 -0
- package/es/info/components/tableInfo/index.js +4 -6
- package/es/info/index.d.ts +6 -0
- package/es/info/index.js +17 -21
- package/es/info/typing.d.ts +220 -0
- package/es/info/utils/index.d.ts +20 -0
- package/es/info/utils/index.js +0 -3
- package/es/info/utils/layout.d.ts +2 -0
- package/es/info/utils/utils.d.ts +1 -0
- package/es/layout/index.d.ts +2 -0
- package/es/layout/index.js +0 -2
- package/es/next-xconsole.scss +34 -0
- package/es/nocode/configurators/Card.d.ts +3 -0
- package/es/nocode/configurators/PageHeader.d.ts +3 -0
- package/es/nocode/configurators/ProTable.d.ts +3 -0
- package/es/nocode/configurators/ProTable.js +1 -22
- package/es/nocode/configurators/common.d.ts +280 -0
- package/es/nocode/configurators/index.d.ts +15 -0
- package/es/nocode/configurators/index.js +1 -0
- package/es/nocode/configurators/map.d.ts +2 -0
- package/es/nocode/index.d.ts +8 -0
- package/es/nocode/index.js +0 -2
- package/es/nocode/pages/editor.d.ts +12 -0
- package/es/nocode/pages/index.d.ts +14 -0
- package/es/nocode/pages/index.js +1 -29
- package/es/nocode/pages/playground.d.ts +11 -0
- package/es/nocode/pages/playground.js +5 -3
- package/es/nocode/pages/renderer.d.ts +10 -0
- package/es/nocode/pages/renderer.js +6 -4
- package/es/nocode/playground.d.ts +14 -0
- package/es/nocode/playground.js +4 -2
- package/es/page-container/index.d.ts +3 -0
- package/es/page-header/index.d.ts +74 -0
- package/es/page-header/index.js +13 -23
- package/es/page-header/index.scss +2 -1
- package/es/page-header/xconsole.scss +5 -0
- package/es/sidebar/components/sidebar-container/index.d.ts +5 -0
- package/es/sidebar/components/sidebar-container/index.js +7 -10
- package/es/sidebar/components/tree/index.d.ts +6 -0
- package/es/sidebar/components/tree/index.js +24 -28
- package/es/sidebar/components/tree-node/components/HoverTooltip/index.d.ts +15 -0
- package/es/sidebar/components/tree-node/components/HoverTooltip/index.js +4 -3
- package/es/sidebar/components/tree-node/components/IconAction/index.d.ts +12 -0
- package/es/sidebar/components/tree-node/components/IconAction/index.js +2 -4
- package/es/sidebar/components/tree-node/components/IconSwitch/index.d.ts +23 -0
- package/es/sidebar/components/tree-node/components/IconSwitch/index.js +0 -1
- package/es/sidebar/components/tree-node/components/IconSwitch/index.scss +1 -1
- package/es/sidebar/components/tree-node/index.d.ts +7 -0
- package/es/sidebar/components/tree-node/index.js +16 -29
- package/es/sidebar/index.d.ts +9 -0
- package/es/sidebar/index.js +13 -18
- package/es/sidebar/typing.d.ts +145 -0
- package/es/sidebar/utils/action-ref.d.ts +3 -0
- package/es/sidebar/utils/index.d.ts +364 -0
- package/es/sidebar/utils/index.js +18 -19
- package/es/skeleton/index.d.ts +3 -0
- package/es/table/components/CardView/index.d.ts +5 -0
- package/es/table/components/CardView/index.js +387 -0
- package/es/table/components/CardView/index.scss +46 -0
- package/es/table/components/EmptyContent/index.d.ts +2 -0
- package/es/table/components/Filter/index.d.ts +12 -0
- package/es/table/components/Filter/index.js +110 -79
- package/es/table/components/Layout/index.d.ts +5 -0
- package/es/table/components/Layout/index.js +16 -16
- package/es/table/components/Layout/index.scss +1 -0
- package/es/table/components/LoadMore/index.d.ts +20 -0
- package/es/table/components/LoadMore/index.js +88 -0
- package/es/table/components/LoadMore/index.scss +19 -0
- package/es/table/components/Pagination/index.d.ts +8 -0
- package/es/table/components/Pagination/index.js +48 -31
- package/es/table/components/QuickAction/index.d.ts +11 -0
- package/es/table/components/QuickAction/index.js +2 -3
- package/es/table/components/ToolBar/CardSwitch.d.ts +8 -0
- package/es/table/components/ToolBar/CardSwitch.js +52 -0
- package/es/table/components/ToolBar/DensityIcon.d.ts +4 -0
- package/es/table/components/ToolBar/DensityIcon.js +2 -7
- package/es/table/components/ToolBar/FilterColumnIcon.d.ts +4 -0
- package/es/table/components/ToolBar/FilterColumnIcon.js +41 -35
- package/es/table/components/ToolBar/FullScreenIcon.d.ts +4 -0
- package/es/table/components/ToolBar/FullScreenIcon.js +0 -1
- package/es/table/components/ToolBar/Fullscreen.d.ts +10 -0
- package/es/table/components/ToolBar/Fullscreen.js +10 -3
- package/es/table/components/ToolBar/RefreshIcon.d.ts +4 -0
- package/es/table/components/ToolBar/RefreshIcon.js +162 -26
- package/es/table/components/ToolBar/index.d.ts +5 -0
- package/es/table/components/ToolBar/index.js +65 -33
- package/es/table/components/ToolBar/index.scss +27 -1
- package/es/table/index.d.ts +6 -0
- package/es/table/index.js +308 -137
- package/es/table/index.scss +8 -0
- package/es/table/typing.d.ts +426 -0
- package/es/table/utils/columnRender.d.ts +13 -0
- package/es/table/utils/columnRender.js +32 -37
- package/es/table/utils/genProColumnToColumn.d.ts +13 -0
- package/es/table/utils/genProColumnToColumn.js +10 -3
- package/es/table/utils/getTableProps.d.ts +2 -0
- package/es/table/utils/getTableSortIcons.d.ts +3 -0
- package/es/table/utils/index.d.ts +19 -0
- package/es/table/utils/index.js +0 -6
- package/es/table/utils/pureColumnRender.d.ts +9 -0
- package/es/table/utils/pureColumnRender.js +1 -9
- package/es/table/utils/pureGenProColumnToColumn.d.ts +7 -0
- package/es/table/utils/useTableSelection.d.ts +3 -0
- package/es/table/utils/util.d.ts +5 -0
- package/es/table/utils/util.js +19 -0
- package/es/templates/Detail/index.d.ts +2 -0
- package/es/templates/Form/index.d.ts +2 -0
- package/es/templates/List/index.d.ts +9 -0
- package/es/templates/List/index.js +6 -4
- package/es/templates/index.d.ts +3 -0
- package/es/templates/index.js +1 -2
- package/es/timeline/ProTimeLineItem/index.d.ts +5 -0
- package/es/timeline/ProTimeLineItem/index.js +5 -9
- package/es/timeline/index.d.ts +10 -0
- package/es/timeline/index.js +5 -5
- package/es/timeline/typing.d.ts +107 -0
- package/es/utils/aspect.d.ts +2 -0
- package/es/utils/aspect.js +60 -0
- package/es/utils/index.d.ts +3 -0
- package/es/utils/message.d.ts +3 -0
- package/es/utils/message.js +5 -3
- package/es/xconsole.scss +527 -0
- package/lib/actions/base.d.ts +24 -0
- package/lib/actions/base.js +1 -1
- package/lib/actions/confirm.d.ts +7 -0
- package/lib/actions/danger-confirm.d.ts +7 -0
- package/lib/actions/danger-pop-confirm.d.ts +5 -0
- package/lib/actions/dialog-component.d.ts +10 -0
- package/lib/actions/dialog-component.js +4 -1
- package/lib/actions/dialog-form.d.ts +29 -0
- package/lib/actions/dialog-form.js +7 -9
- package/lib/actions/dialog-info.d.ts +9 -0
- package/lib/actions/dialog-table.d.ts +9 -0
- package/lib/actions/dialog.d.ts +40 -0
- package/lib/actions/dialog.js +7 -8
- package/lib/actions/drawer-form.d.ts +6 -0
- package/lib/actions/drawer-info.d.ts +6 -0
- package/lib/actions/drawer-table.d.ts +6 -0
- package/lib/actions/drawer.d.ts +6 -0
- package/lib/actions/error.d.ts +7 -0
- package/lib/actions/index.d.ts +114 -0
- package/lib/actions/index.js +89 -58
- package/lib/actions/index.scss +10 -1
- package/lib/actions/link.d.ts +8 -0
- package/lib/actions/link.js +2 -3
- package/lib/actions/notice.d.ts +7 -0
- package/lib/actions/pop-confirm.d.ts +9 -0
- package/lib/actions/quick.d.ts +2 -0
- package/lib/actions/quick.js +33 -0
- package/lib/actions/request.d.ts +9 -0
- package/lib/actions/request.js +2 -3
- package/lib/actions/utils.d.ts +1 -0
- package/lib/card/card-container.d.ts +18 -0
- package/lib/card/card-container.js +4 -6
- package/lib/card/divider.d.ts +6 -0
- package/lib/card/divider.js +4 -2
- package/lib/card/index.d.ts +109 -0
- package/lib/card/index.js +10 -20
- package/lib/card/index.scss +15 -0
- package/lib/card/selectable.d.ts +13 -0
- package/lib/card/selectable.js +4 -2
- package/lib/card/tab.d.ts +6 -0
- package/lib/card/tab.js +4 -2
- package/lib/card/utils.d.ts +9 -0
- package/lib/card/xconsole.scss +3 -0
- package/lib/field/index.d.ts +3 -0
- package/lib/form/Components/Editable/index.d.ts +20 -0
- package/lib/form/Components/Editable/index.js +2 -2
- package/lib/form/Components/FormGroup/index.d.ts +14 -0
- package/lib/form/Components/FormGroup/index.js +3 -4
- package/lib/form/Components/FormItem2/animation.scss +72 -0
- package/lib/form/Components/FormItem2/grid.scss +173 -0
- package/lib/form/Components/FormItem2/index.d.ts +41 -0
- package/lib/form/Components/FormItem2/index.js +299 -0
- package/lib/form/Components/FormItem2/main.scss +413 -0
- package/lib/form/Components/FormItem2/scss/variable.scss +118 -0
- package/lib/form/Components/FormItem2/style.d.ts +1 -0
- package/lib/form/Components/FormItem2/style.js +3 -0
- package/lib/form/Components/LightFilter/componentMap.d.ts +3 -0
- package/lib/form/Components/LightFilter/index.d.ts +17 -0
- package/lib/form/Components/LightFilter/index.js +2 -11
- package/lib/form/Components/LightFilter/index.scss +4 -0
- package/lib/form/Components/ProField/index.d.ts +2 -0
- package/lib/form/Components/ProField/index.js +4 -2
- package/lib/form/Components/ProField/mapDateFormat.d.ts +3 -0
- package/lib/form/Components/Text/index.d.ts +8 -0
- package/lib/form/Components/Text/index.js +4 -2
- package/lib/form/Components/__builtins__/empty.d.ts +1 -0
- package/lib/form/Components/__builtins__/empty.js +59 -0
- package/lib/form/Components/__builtins__/hooks/index.d.ts +2 -0
- package/lib/form/Components/__builtins__/hooks/index.js +27 -0
- package/lib/form/Components/__builtins__/hooks/useClickAway.d.ts +5 -0
- package/lib/form/Components/__builtins__/hooks/useClickAway.js +44 -0
- package/lib/form/Components/__builtins__/hooks/usePrefixCls.d.ts +3 -0
- package/lib/form/Components/__builtins__/hooks/usePrefixCls.js +15 -0
- package/lib/form/Components/__builtins__/icons.d.ts +20 -0
- package/lib/form/Components/__builtins__/icons.js +174 -0
- package/lib/form/Components/__builtins__/index.d.ts +8 -0
- package/lib/form/Components/__builtins__/index.js +93 -0
- package/lib/form/Components/__builtins__/loading.d.ts +1 -0
- package/lib/form/Components/__builtins__/loading.js +48 -0
- package/lib/form/Components/__builtins__/mapSize.d.ts +1 -0
- package/lib/form/Components/__builtins__/mapSize.js +20 -0
- package/lib/form/Components/__builtins__/mapStatus.d.ts +2 -0
- package/lib/form/Components/__builtins__/mapStatus.js +27 -0
- package/lib/form/Components/__builtins__/moment.d.ts +2 -0
- package/lib/form/Components/__builtins__/moment.js +56 -0
- package/lib/form/Components/__builtins__/pickDataProps.d.ts +1 -0
- package/lib/form/Components/__builtins__/pickDataProps.js +16 -0
- package/lib/form/Components/form-layout/index.d.ts +74 -0
- package/lib/form/Components/form-layout/index.js +88 -0
- package/lib/form/Components/form-layout/main.scss +0 -0
- package/lib/form/Components/form-layout/style.d.ts +1 -0
- package/lib/form/Components/form-layout/style.js +3 -0
- package/lib/form/Components/form-layout/useResponsiveFormLayout.d.ts +18 -0
- package/lib/form/Components/form-layout/useResponsiveFormLayout.js +94 -0
- package/lib/form/Filter/AdvancedFilter.d.ts +7 -0
- package/lib/form/Filter/AdvancedFilter.js +16 -18
- package/lib/form/Filter/Layout.d.ts +5 -0
- package/lib/form/Filter/LightFilter.d.ts +7 -0
- package/lib/form/Filter/LightFilter.js +9 -13
- package/lib/form/Filter/SimpleFilter.d.ts +7 -0
- package/lib/form/Filter/SimpleFilter.js +5 -8
- package/lib/form/Filter/index.d.ts +9 -0
- package/lib/form/Filter/index.js +19 -25
- package/lib/form/Filter/index.scss +1 -0
- package/lib/form/Filter/index2.d.ts +13 -0
- package/lib/form/Filter/index2.js +20 -25
- package/lib/form/Filter/index2.scss +1 -0
- package/lib/form/Filter/useBindUrl.d.ts +2 -0
- package/lib/form/Filter/useBindUrl.js +0 -3
- package/lib/form/Filter/useSpecialProps.d.ts +6 -0
- package/lib/form/ProForm/addCascadeEffect.d.ts +2 -0
- package/lib/form/ProForm/customComponent.d.ts +3 -0
- package/lib/form/ProForm/index.d.ts +5 -0
- package/lib/form/ProForm/index.js +20 -16
- package/lib/form/ProForm/useAutoLayout.d.ts +9 -0
- package/lib/form/ProForm/useAutoLayout.js +0 -4
- package/lib/form/ProForm/useAutoSubmit.d.ts +6 -0
- package/lib/form/ProForm/useAutoSubmit.js +2 -3
- package/lib/form/ProForm/useFieldRequest.d.ts +5 -0
- package/lib/form/ProForm/useFormDisplayValues.d.ts +4 -0
- package/lib/form/ProForm/useFormDisplayValues.js +0 -1
- package/lib/form/ProForm/useInitialRequest.d.ts +6 -0
- package/lib/form/SchemaForm/adapterComponent.d.ts +5 -0
- package/lib/form/SchemaForm/adapterComponent.js +0 -1
- package/lib/form/SchemaForm/adapterDecorator.d.ts +6 -0
- package/lib/form/SchemaForm/adapterType.d.ts +5 -0
- package/lib/form/SchemaForm/adapterType.js +0 -1
- package/lib/form/SchemaForm/index.d.ts +4 -0
- package/lib/form/SchemaForm/index.js +0 -13
- package/lib/form/SchemaForm/initializeArrayCards.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayCollapse.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayItems.d.ts +3 -0
- package/lib/form/SchemaForm/initializeArrayTable.d.ts +3 -0
- package/lib/form/SchemaForm/initializeDataSource.d.ts +15 -0
- package/lib/form/SchemaForm/initializeDataSource.js +2 -9
- package/lib/form/SchemaForm/initializeFormButton.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormButton.js +0 -2
- package/lib/form/SchemaForm/initializeFormCollapse.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormGroup.d.ts +3 -0
- package/lib/form/SchemaForm/initializeFormStep.d.ts +5 -0
- package/lib/form/SchemaForm/initializeFormTab.d.ts +3 -0
- package/lib/form/SchemaForm/initializeReactions.d.ts +2 -0
- package/lib/form/SchemaForm/initializeReactions.js +0 -1
- package/lib/form/SchemaForm/initializeRequest.d.ts +11 -0
- package/lib/form/SchemaForm/initializeRules.d.ts +11 -0
- package/lib/form/SchemaForm/initializeSelectTable.d.ts +3 -0
- package/lib/form/SchemaForm/reactions.d.ts +6 -0
- package/lib/form/SchemaForm/reactions.js +0 -5
- package/lib/form/docs/ActionResponse.d.ts +8 -0
- package/lib/form/fieldTypeMap.d.ts +7 -0
- package/lib/form/index.d.ts +125 -0
- package/lib/form/locales/validate.d.ts +159 -0
- package/lib/form/schemaNameMap.d.ts +5 -0
- package/lib/form/typing.d.ts +194 -0
- package/lib/form/typing.js +5 -1
- package/lib/form/utils/parseSchema.d.ts +3 -0
- package/lib/form/utils/parseSchema.js +45 -0
- package/lib/form/utils.d.ts +55 -0
- package/lib/form/utils.js +0 -11
- package/lib/form/warning.d.ts +3 -0
- package/lib/form/warning.js +0 -2
- package/lib/global.scss +3 -1
- package/lib/hooks/index.d.ts +2 -0
- package/lib/image/index.d.ts +22 -0
- package/lib/image/index.js +83 -0
- package/lib/image/index.scss +3 -0
- package/lib/index-without-icon.d.ts +32 -0
- package/lib/index.d.ts +34 -0
- package/lib/index.js +31 -2
- package/lib/info/components/InfoGroup/index.d.ts +5 -0
- package/lib/info/components/InfoGroup/index.js +4 -2
- package/lib/info/components/InfoValueItem/index.d.ts +5 -0
- package/lib/info/components/InfoValueItem/index.js +20 -32
- package/lib/info/components/ProInfoItem/index.d.ts +5 -0
- package/lib/info/components/ProInfoItem/index.js +0 -1
- package/lib/info/components/baseInfo/index.d.ts +8 -0
- package/lib/info/components/baseInfo/index.js +4 -5
- package/lib/info/components/headerInfo/index.d.ts +8 -0
- package/lib/info/components/tableInfo/index.d.ts +7 -0
- package/lib/info/components/tableInfo/index.js +4 -6
- package/lib/info/index.d.ts +6 -0
- package/lib/info/index.js +16 -20
- package/lib/info/typing.d.ts +220 -0
- package/lib/info/typing.js +5 -1
- package/lib/info/utils/index.d.ts +20 -0
- package/lib/info/utils/index.js +0 -3
- package/lib/info/utils/layout.d.ts +2 -0
- package/lib/info/utils/utils.d.ts +1 -0
- package/lib/layout/index.d.ts +2 -0
- package/lib/next-xconsole.scss +34 -0
- package/lib/nocode/configurators/Card.d.ts +3 -0
- package/lib/nocode/configurators/PageHeader.d.ts +3 -0
- package/lib/nocode/configurators/ProTable.d.ts +3 -0
- package/lib/nocode/configurators/ProTable.js +1 -22
- package/lib/nocode/configurators/common.d.ts +280 -0
- package/lib/nocode/configurators/index.d.ts +15 -0
- package/lib/nocode/configurators/index.js +1 -0
- package/lib/nocode/configurators/map.d.ts +2 -0
- package/lib/nocode/index.d.ts +8 -0
- package/lib/nocode/pages/editor.d.ts +12 -0
- package/lib/nocode/pages/index.d.ts +14 -0
- package/lib/nocode/pages/index.js +2 -27
- package/lib/nocode/pages/playground.d.ts +11 -0
- package/lib/nocode/pages/playground.js +5 -3
- package/lib/nocode/pages/renderer.d.ts +10 -0
- package/lib/nocode/pages/renderer.js +6 -4
- package/lib/nocode/playground.d.ts +14 -0
- package/lib/nocode/playground.js +4 -2
- package/lib/page-container/index.d.ts +3 -0
- package/lib/page-header/index.d.ts +74 -0
- package/lib/page-header/index.js +11 -22
- package/lib/page-header/index.scss +2 -1
- package/lib/page-header/xconsole.scss +5 -0
- package/lib/sidebar/components/sidebar-container/index.d.ts +5 -0
- package/lib/sidebar/components/sidebar-container/index.js +7 -10
- package/lib/sidebar/components/tree/index.d.ts +6 -0
- package/lib/sidebar/components/tree/index.js +24 -28
- package/lib/sidebar/components/tree-node/components/HoverTooltip/index.d.ts +15 -0
- package/lib/sidebar/components/tree-node/components/HoverTooltip/index.js +4 -3
- package/lib/sidebar/components/tree-node/components/IconAction/index.d.ts +12 -0
- package/lib/sidebar/components/tree-node/components/IconAction/index.js +2 -4
- package/lib/sidebar/components/tree-node/components/IconSwitch/index.d.ts +23 -0
- package/lib/sidebar/components/tree-node/components/IconSwitch/index.js +0 -1
- package/lib/sidebar/components/tree-node/components/IconSwitch/index.scss +1 -1
- package/lib/sidebar/components/tree-node/index.d.ts +7 -0
- package/lib/sidebar/components/tree-node/index.js +16 -29
- package/lib/sidebar/index.d.ts +9 -0
- package/lib/sidebar/index.js +20 -18
- package/lib/sidebar/typing.d.ts +145 -0
- package/lib/sidebar/typing.js +5 -1
- package/lib/sidebar/utils/action-ref.d.ts +3 -0
- package/lib/sidebar/utils/index.d.ts +364 -0
- package/lib/sidebar/utils/index.js +18 -19
- package/lib/skeleton/index.d.ts +3 -0
- package/lib/table/components/CardView/index.d.ts +5 -0
- package/lib/table/components/CardView/index.js +397 -0
- package/lib/table/components/CardView/index.scss +46 -0
- package/lib/table/components/EmptyContent/index.d.ts +2 -0
- package/lib/table/components/Filter/index.d.ts +12 -0
- package/lib/table/components/Filter/index.js +109 -78
- package/lib/table/components/Layout/index.d.ts +5 -0
- package/lib/table/components/Layout/index.js +17 -17
- package/lib/table/components/Layout/index.scss +1 -0
- package/lib/table/components/LoadMore/index.d.ts +20 -0
- package/lib/table/components/LoadMore/index.js +99 -0
- package/lib/table/components/LoadMore/index.scss +19 -0
- package/lib/table/components/Pagination/index.d.ts +8 -0
- package/lib/table/components/Pagination/index.js +47 -30
- package/lib/table/components/QuickAction/index.d.ts +11 -0
- package/lib/table/components/QuickAction/index.js +2 -3
- package/lib/table/components/ToolBar/CardSwitch.d.ts +8 -0
- package/lib/table/components/ToolBar/CardSwitch.js +60 -0
- package/lib/table/components/ToolBar/DensityIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/DensityIcon.js +2 -7
- package/lib/table/components/ToolBar/FilterColumnIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/FilterColumnIcon.js +40 -34
- package/lib/table/components/ToolBar/FullScreenIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/FullScreenIcon.js +0 -1
- package/lib/table/components/ToolBar/Fullscreen.d.ts +10 -0
- package/lib/table/components/ToolBar/Fullscreen.js +10 -3
- package/lib/table/components/ToolBar/RefreshIcon.d.ts +4 -0
- package/lib/table/components/ToolBar/RefreshIcon.js +164 -29
- package/lib/table/components/ToolBar/index.d.ts +5 -0
- package/lib/table/components/ToolBar/index.js +64 -32
- package/lib/table/components/ToolBar/index.scss +27 -1
- package/lib/table/index.d.ts +6 -0
- package/lib/table/index.js +307 -136
- package/lib/table/index.scss +8 -0
- package/lib/table/typing.d.ts +426 -0
- package/lib/table/typing.js +5 -1
- package/lib/table/utils/columnRender.d.ts +13 -0
- package/lib/table/utils/columnRender.js +32 -36
- package/lib/table/utils/genProColumnToColumn.d.ts +13 -0
- package/lib/table/utils/genProColumnToColumn.js +10 -3
- package/lib/table/utils/getTableProps.d.ts +2 -0
- package/lib/table/utils/getTableSortIcons.d.ts +3 -0
- package/lib/table/utils/index.d.ts +19 -0
- package/lib/table/utils/index.js +0 -6
- package/lib/table/utils/pureColumnRender.d.ts +9 -0
- package/lib/table/utils/pureColumnRender.js +1 -9
- package/lib/table/utils/pureGenProColumnToColumn.d.ts +7 -0
- package/lib/table/utils/useTableSelection.d.ts +3 -0
- package/lib/table/utils/util.d.ts +5 -0
- package/lib/table/utils/util.js +25 -0
- package/lib/templates/Detail/index.d.ts +2 -0
- package/lib/templates/Form/index.d.ts +2 -0
- package/lib/templates/List/index.d.ts +9 -0
- package/lib/templates/List/index.js +6 -4
- package/lib/templates/index.d.ts +3 -0
- package/lib/timeline/ProTimeLineItem/index.d.ts +5 -0
- package/lib/timeline/ProTimeLineItem/index.js +5 -9
- package/lib/timeline/index.d.ts +10 -0
- package/lib/timeline/index.js +5 -5
- package/lib/timeline/typing.d.ts +107 -0
- package/lib/timeline/typing.js +5 -1
- package/lib/utils/aspect.d.ts +2 -0
- package/lib/utils/aspect.js +67 -0
- package/lib/utils/index.d.ts +3 -0
- package/lib/utils/message.d.ts +3 -0
- package/lib/utils/message.js +5 -3
- package/lib/xconsole.scss +527 -0
- package/package.json +9 -8
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Field } from '@alicloudfe/components';
|
|
2
|
+
import { ConfiguratorMap } from '../configurators';
|
|
3
|
+
import { PageMap, PageType, PageDefaultInitialValues } from '.';
|
|
4
|
+
export interface PageEditorProps {
|
|
5
|
+
type: PageType;
|
|
6
|
+
initialValues?: any;
|
|
7
|
+
field?: Field;
|
|
8
|
+
configuratorMap?: ConfiguratorMap;
|
|
9
|
+
pageMap?: PageMap;
|
|
10
|
+
pageDefaultInitialValues?: PageDefaultInitialValues;
|
|
11
|
+
}
|
|
12
|
+
export declare const PageEditor: (props: PageEditorProps) => JSX.Element;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { PageProps } from '../../page-container';
|
|
3
|
+
export * from './editor';
|
|
4
|
+
export * from './playground';
|
|
5
|
+
export * from './renderer';
|
|
6
|
+
export declare type PageType = 'LIST' | 'DETAIL' | 'FORM' | string;
|
|
7
|
+
export declare type PageMap = {
|
|
8
|
+
[key in PageType]: React.FC<PageProps>;
|
|
9
|
+
};
|
|
10
|
+
export declare const PageMap: PageMap;
|
|
11
|
+
export declare type PageDefaultInitialValues = {
|
|
12
|
+
[key in PageType]: any;
|
|
13
|
+
};
|
|
14
|
+
export declare const PageDefaultInitialValues: PageDefaultInitialValues;
|
|
@@ -51,35 +51,10 @@ var PageMap = {
|
|
|
51
51
|
DETAIL: _templates.DetailPage,
|
|
52
52
|
FORM: _templates.FormPage
|
|
53
53
|
};
|
|
54
|
-
exports.PageMap = PageMap;
|
|
55
54
|
// 全部页面模板默认初始值
|
|
55
|
+
exports.PageMap = PageMap;
|
|
56
56
|
var PageDefaultInitialValues = {
|
|
57
|
-
LIST: {
|
|
58
|
-
header: {
|
|
59
|
-
title: '页面标题'
|
|
60
|
-
},
|
|
61
|
-
content: {
|
|
62
|
-
header: {
|
|
63
|
-
title: '表格标题'
|
|
64
|
-
},
|
|
65
|
-
columns: [{
|
|
66
|
-
dataIndex: 'instanceName',
|
|
67
|
-
title: '实例ID/实例名称'
|
|
68
|
-
}, {
|
|
69
|
-
dataIndex: 'organizationName',
|
|
70
|
-
title: '组织',
|
|
71
|
-
tooltip: '我这一列是可以被复制的~',
|
|
72
|
-
render: {
|
|
73
|
-
copy: true
|
|
74
|
-
}
|
|
75
|
-
}],
|
|
76
|
-
url: 'https://oneapi.alibaba-inc.com/mock/teamix-pro/api/getTableResource',
|
|
77
|
-
formatResult: {
|
|
78
|
-
data: 'data',
|
|
79
|
-
total: 'pageInfo.total'
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
},
|
|
57
|
+
LIST: {},
|
|
83
58
|
DETAIL: {},
|
|
84
59
|
FORM: {}
|
|
85
60
|
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { PageProps } from '../../page-container';
|
|
3
|
+
import { ConfiguratorMap } from '../configurators';
|
|
4
|
+
interface PagePlayGroundProps<T = any> {
|
|
5
|
+
initialValues: T;
|
|
6
|
+
page: React.FC<PageProps<T>>;
|
|
7
|
+
onValuesChange?: (values: any) => void;
|
|
8
|
+
configuratorMap?: ConfiguratorMap;
|
|
9
|
+
}
|
|
10
|
+
export declare const PagePlayground: (props: PagePlayGroundProps) => JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -18,7 +18,9 @@ var _playground = require("../playground");
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
20
20
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
21
|
-
function
|
|
21
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
22
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
23
|
+
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; }
|
|
22
24
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
23
25
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
24
26
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
@@ -96,7 +98,7 @@ var PagePlayground = function PagePlayground(props) {
|
|
|
96
98
|
return "page-".concat(Math.random());
|
|
97
99
|
}, [pageProps]);
|
|
98
100
|
return /*#__PURE__*/_react.default.createElement(_playground.PlayGroundLayout, {
|
|
99
|
-
component: /*#__PURE__*/_react.default.createElement(PageContainer,
|
|
101
|
+
component: /*#__PURE__*/_react.default.createElement(PageContainer, _objectSpread({
|
|
100
102
|
key: pageKey
|
|
101
103
|
}, pageContainerProps)),
|
|
102
104
|
configurator: Configurator ? /*#__PURE__*/_react.default.createElement(Configurator, {
|
|
@@ -111,7 +113,7 @@ var PagePlayground = function PagePlayground(props) {
|
|
|
111
113
|
}), /*#__PURE__*/_react.default.createElement("p", null, "\u8BF7\u9009\u62E9\u4E00\u4E2A\u7EC4\u4EF6\u8FDB\u884C\u7F16\u8F91")),
|
|
112
114
|
tools: /*#__PURE__*/_react.default.createElement(_components.Balloon, {
|
|
113
115
|
align: "l",
|
|
114
|
-
trigger: /*#__PURE__*/_react.default.createElement(_icon.default,
|
|
116
|
+
trigger: /*#__PURE__*/_react.default.createElement(_icon.default, _objectSpread({
|
|
115
117
|
type: "set-line",
|
|
116
118
|
size: "large"
|
|
117
119
|
}, setterAction)),
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { PageProps } from '../../page-container';
|
|
2
|
+
import { PageMap } from '.';
|
|
3
|
+
export interface PageRendererProps<T = any> extends PageProps<T> {
|
|
4
|
+
type?: any;
|
|
5
|
+
error?: any;
|
|
6
|
+
title?: string;
|
|
7
|
+
pageMap?: PageMap;
|
|
8
|
+
}
|
|
9
|
+
export declare const PageRenderer: (props: PageRendererProps) => JSX.Element;
|
|
10
|
+
export default PageRenderer;
|
|
@@ -27,10 +27,12 @@ function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) ===
|
|
|
27
27
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
28
28
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
29
29
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
30
|
-
function
|
|
30
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
31
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
32
|
+
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; }
|
|
31
33
|
var cls = (0, _utils.usePrefixCls)('teamix-pro-nocode');
|
|
32
34
|
var Loading = function Loading(props) {
|
|
33
|
-
return /*#__PURE__*/_react.default.createElement(_pageContainer.default,
|
|
35
|
+
return /*#__PURE__*/_react.default.createElement(_pageContainer.default, _objectSpread({
|
|
34
36
|
header: /*#__PURE__*/_react.default.createElement(_pageHeader.default, {
|
|
35
37
|
loading: true,
|
|
36
38
|
title: "",
|
|
@@ -97,7 +99,7 @@ var PageRenderer = function PageRenderer(props) {
|
|
|
97
99
|
});
|
|
98
100
|
}
|
|
99
101
|
if (!type) {
|
|
100
|
-
return /*#__PURE__*/_react.default.createElement(Loading, others);
|
|
102
|
+
return /*#__PURE__*/_react.default.createElement(Loading, _objectSpread({}, others));
|
|
101
103
|
}
|
|
102
104
|
var Page = _.PageMap[type] || (pageMap === null || pageMap === void 0 ? void 0 : pageMap[type]);
|
|
103
105
|
if (!Page) {
|
|
@@ -108,7 +110,7 @@ var PageRenderer = function PageRenderer(props) {
|
|
|
108
110
|
}
|
|
109
111
|
return /*#__PURE__*/_react.default.createElement(ErrorBoundary, null, /*#__PURE__*/_react.default.createElement(_reactHelmet.default, {
|
|
110
112
|
title: title
|
|
111
|
-
}), /*#__PURE__*/_react.default.createElement(Page,
|
|
113
|
+
}), /*#__PURE__*/_react.default.createElement(Page, _objectSpread({
|
|
112
114
|
loading: loading,
|
|
113
115
|
pageProps: pageProps || {}
|
|
114
116
|
}, others)));
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Configurator } from './configurators';
|
|
3
|
+
export interface PlayGroundLayoutProps {
|
|
4
|
+
component: React.ReactNode;
|
|
5
|
+
configurator: React.ReactNode;
|
|
6
|
+
tools?: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
export declare const PlayGroundLayout: (props: PlayGroundLayoutProps) => JSX.Element;
|
|
9
|
+
export interface PlayGround<T = any> {
|
|
10
|
+
component: React.FC<T>;
|
|
11
|
+
configurator: Configurator;
|
|
12
|
+
initialValues: T;
|
|
13
|
+
}
|
|
14
|
+
export declare const PlayGround: <T extends {}>(props: PlayGround<T>) => JSX.Element;
|
package/lib/nocode/playground.js
CHANGED
|
@@ -11,7 +11,9 @@ var _hooks = require("@teamix/hooks");
|
|
|
11
11
|
var _configurators = require("./configurators");
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
|
-
function
|
|
14
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
15
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
16
|
+
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
17
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
16
18
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
17
19
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
@@ -52,7 +54,7 @@ var PlayGround = function PlayGround(props) {
|
|
|
52
54
|
}),
|
|
53
55
|
onValuesChange = _useDebounceFn.run;
|
|
54
56
|
return /*#__PURE__*/_react.default.createElement(PlayGroundLayout, {
|
|
55
|
-
component: /*#__PURE__*/_react.default.createElement(Component,
|
|
57
|
+
component: /*#__PURE__*/_react.default.createElement(Component, _objectSpread({
|
|
56
58
|
key: componentKey
|
|
57
59
|
}, componentState)),
|
|
58
60
|
configurator: /*#__PURE__*/_react.default.createElement(Configurator, {
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ItemProps } from '@alicloudfe/components/types/breadcrumb';
|
|
3
|
+
import { LinkPath } from '@teamix/utils';
|
|
4
|
+
import { CapsuleTabType, ProTagItem } from '../field';
|
|
5
|
+
import { ProActionGroupProps } from '../actions';
|
|
6
|
+
import { ProInfoProps } from '../info';
|
|
7
|
+
import './index.scss';
|
|
8
|
+
export interface ProPageHeaderBreadcrumbItem extends ItemProps {
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated 建议使用 children 代替
|
|
11
|
+
*/
|
|
12
|
+
text?: string;
|
|
13
|
+
}
|
|
14
|
+
export declare type ProPageHeaderTagItem = ProTagItem;
|
|
15
|
+
declare type Color = 'blue' | 'green' | 'orange' | 'red' | 'yellow' | string;
|
|
16
|
+
export declare type ProPageHeaderDataItem = {
|
|
17
|
+
title: string;
|
|
18
|
+
num: number;
|
|
19
|
+
color?: Color;
|
|
20
|
+
} & React.HTMLAttributes<HTMLElement>;
|
|
21
|
+
export declare type ProPageHeaderProps = {
|
|
22
|
+
/** 标题 */
|
|
23
|
+
title?: React.ReactNode;
|
|
24
|
+
/** 标题说明 */
|
|
25
|
+
titleTooltip?: React.ReactNode;
|
|
26
|
+
/** 描述 */
|
|
27
|
+
description?: React.ReactNode;
|
|
28
|
+
/** 图标 */
|
|
29
|
+
icon?: React.ReactNode;
|
|
30
|
+
/** 图标颜色 */
|
|
31
|
+
iconColor?: Color;
|
|
32
|
+
/** 图标背景类型 */
|
|
33
|
+
iconBackgroundType?: 'circle' | 'square';
|
|
34
|
+
/** 图标背景色 */
|
|
35
|
+
iconBackgroundColor?: Color;
|
|
36
|
+
/** 返回按钮配置 */
|
|
37
|
+
goback?: boolean | LinkPath | ((e: React.MouseEvent) => void);
|
|
38
|
+
/** 背景图 */
|
|
39
|
+
image?: string;
|
|
40
|
+
/** 加载中 */
|
|
41
|
+
loading?: boolean;
|
|
42
|
+
/** 面包屑配置 */
|
|
43
|
+
breadcrumb?: ProPageHeaderBreadcrumbItem[];
|
|
44
|
+
/** 额外信息区配置 */
|
|
45
|
+
extra?: ProActionGroupProps | React.ReactNode | any[];
|
|
46
|
+
/** 操作区配置 */
|
|
47
|
+
operation?: ProActionGroupProps | React.ReactNode | any[];
|
|
48
|
+
/** 标签组 */
|
|
49
|
+
tags?: ProPageHeaderTagItem[];
|
|
50
|
+
/** 数据概览项 */
|
|
51
|
+
data?: ProPageHeaderDataItem[];
|
|
52
|
+
/** 底部详情 */
|
|
53
|
+
info?: ProInfoProps | React.ReactNode;
|
|
54
|
+
/** 切换 tabs */
|
|
55
|
+
tabs?: CapsuleTabType;
|
|
56
|
+
} & Omit<React.HTMLAttributes<HTMLElement>, 'title'>;
|
|
57
|
+
declare const ProPageHeader: React.FC<ProPageHeaderProps>;
|
|
58
|
+
export default ProPageHeader;
|
|
59
|
+
/**
|
|
60
|
+
* @deprecated 建议使用 ProPageHeaderBreadcrumbItem 代替
|
|
61
|
+
*/
|
|
62
|
+
export declare type BreadcrumbItem = ProPageHeaderBreadcrumbItem;
|
|
63
|
+
/**
|
|
64
|
+
* @deprecated 建议使用 ProPageHeaderTagItem 代替
|
|
65
|
+
*/
|
|
66
|
+
export declare type TagItem = ProPageHeaderTagItem;
|
|
67
|
+
/**
|
|
68
|
+
* @deprecated 建议使用 ProPageHeaderDataItem 代替
|
|
69
|
+
*/
|
|
70
|
+
export declare type DataItem = ProPageHeaderDataItem;
|
|
71
|
+
/**
|
|
72
|
+
* @deprecated 建议使用 ProPageHeaderProps 代替
|
|
73
|
+
*/
|
|
74
|
+
export declare type PageHeaderProps = ProPageHeaderProps;
|
package/lib/page-header/index.js
CHANGED
|
@@ -5,11 +5,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
|
-
var
|
|
8
|
+
var _utils = require("@teamix/utils");
|
|
9
9
|
var _classnames2 = _interopRequireDefault(require("classnames"));
|
|
10
10
|
var _icon = _interopRequireDefault(require("@teamix/icon"));
|
|
11
11
|
var _components = require("@alicloudfe/components");
|
|
12
|
-
var _utils = require("@teamix/utils");
|
|
13
12
|
var _field = require("../field");
|
|
14
13
|
var _actions = require("../actions");
|
|
15
14
|
var _skeleton = require("../skeleton");
|
|
@@ -22,7 +21,6 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
22
21
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
23
22
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
24
23
|
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; }
|
|
25
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
26
24
|
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; }
|
|
27
25
|
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; }
|
|
28
26
|
var cls = (0, _utils.usePrefixCls)('teamix-pro-page-header');
|
|
@@ -33,7 +31,7 @@ var renderNav = function renderNav(breadcrumbs) {
|
|
|
33
31
|
var text = b.text,
|
|
34
32
|
children = b.children,
|
|
35
33
|
others = _objectWithoutProperties(b, _excluded);
|
|
36
|
-
return /*#__PURE__*/_react.default.createElement(_components.Breadcrumb.Item,
|
|
34
|
+
return /*#__PURE__*/_react.default.createElement(_components.Breadcrumb.Item, _objectSpread({
|
|
37
35
|
key: i
|
|
38
36
|
}, others), text || children);
|
|
39
37
|
}));
|
|
@@ -52,7 +50,7 @@ var renderActionGroup = function renderActionGroup(group, defaultProps) {
|
|
|
52
50
|
type: buttonType
|
|
53
51
|
}, item);
|
|
54
52
|
});
|
|
55
|
-
return /*#__PURE__*/_react.default.createElement(_actions.ProActionGroup,
|
|
53
|
+
return /*#__PURE__*/_react.default.createElement(_actions.ProActionGroup, _objectSpread(_objectSpread(_objectSpread({}, defaultProps), actionGroup), {}, {
|
|
56
54
|
actions: actions
|
|
57
55
|
}));
|
|
58
56
|
}
|
|
@@ -91,7 +89,7 @@ var renderData = function renderData(data) {
|
|
|
91
89
|
var _getColorAndStyle = getColorAndStyle(color),
|
|
92
90
|
className = _getColorAndStyle.className,
|
|
93
91
|
style = _getColorAndStyle.style;
|
|
94
|
-
return /*#__PURE__*/_react.default.createElement("div",
|
|
92
|
+
return /*#__PURE__*/_react.default.createElement("div", _objectSpread({
|
|
95
93
|
key: i,
|
|
96
94
|
className: (0, _classnames2.default)(cls('data-item'), customClassName)
|
|
97
95
|
}, others), /*#__PURE__*/_react.default.createElement("div", {
|
|
@@ -104,7 +102,7 @@ var renderData = function renderData(data) {
|
|
|
104
102
|
};
|
|
105
103
|
var renderInfo = function renderInfo(info) {
|
|
106
104
|
if (info === null || info === void 0 ? void 0 : info.columns) {
|
|
107
|
-
return /*#__PURE__*/_react.default.createElement(_info.default,
|
|
105
|
+
return /*#__PURE__*/_react.default.createElement(_info.default, _objectSpread({
|
|
108
106
|
type: "header"
|
|
109
107
|
}, info));
|
|
110
108
|
}
|
|
@@ -112,7 +110,7 @@ var renderInfo = function renderInfo(info) {
|
|
|
112
110
|
};
|
|
113
111
|
var renderTabs = function renderTabs(tabs) {
|
|
114
112
|
if (tabs) {
|
|
115
|
-
return /*#__PURE__*/_react.default.createElement(_field.CapsuleTab, tabs);
|
|
113
|
+
return /*#__PURE__*/_react.default.createElement(_field.CapsuleTab, _objectSpread({}, tabs));
|
|
116
114
|
}
|
|
117
115
|
return null;
|
|
118
116
|
};
|
|
@@ -139,12 +137,7 @@ var ProPageHeader = function ProPageHeader(props) {
|
|
|
139
137
|
style = props.style,
|
|
140
138
|
tabs = props.tabs,
|
|
141
139
|
others = _objectWithoutProperties(props, _excluded3);
|
|
142
|
-
|
|
143
|
-
// const history = useHistory();
|
|
144
|
-
// console.log('history', history);
|
|
145
|
-
var navigate = (0, _reactRouterDom.useNavigate)();
|
|
146
|
-
// console.log('navigate', useNavigate);
|
|
147
|
-
|
|
140
|
+
var history = (0, _utils.useRealHistory)();
|
|
148
141
|
var backgroundImage = image ? "url('".concat(image, "')") : undefined;
|
|
149
142
|
var showList = function showList(list) {
|
|
150
143
|
var _list$actions;
|
|
@@ -166,11 +159,10 @@ var ProPageHeader = function ProPageHeader(props) {
|
|
|
166
159
|
return;
|
|
167
160
|
}
|
|
168
161
|
if (goback === true) {
|
|
169
|
-
|
|
170
|
-
navigate(-1);
|
|
162
|
+
history && history.go && history.go(-1);
|
|
171
163
|
return;
|
|
172
164
|
}
|
|
173
|
-
(0, _utils.goToLink)(goback,
|
|
165
|
+
(0, _utils.goToLink)(goback, history);
|
|
174
166
|
};
|
|
175
167
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, goback && /*#__PURE__*/_react.default.createElement(_icon.default, {
|
|
176
168
|
className: cls('goback'),
|
|
@@ -194,7 +186,7 @@ var ProPageHeader = function ProPageHeader(props) {
|
|
|
194
186
|
align: "t"
|
|
195
187
|
}, titleTooltip)), (0, _field.renderTags)(tags, 'large'), renderTabs(tabs !== null && tabs !== void 0 ? tabs : {}));
|
|
196
188
|
};
|
|
197
|
-
return /*#__PURE__*/_react.default.createElement("header",
|
|
189
|
+
return /*#__PURE__*/_react.default.createElement("header", _objectSpread({
|
|
198
190
|
className: (0, _classnames2.default)(cls(), className),
|
|
199
191
|
style: _objectSpread({
|
|
200
192
|
backgroundImage: loading ? undefined : backgroundImage
|
|
@@ -226,10 +218,7 @@ var ProPageHeader = function ProPageHeader(props) {
|
|
|
226
218
|
className: cls('operation')
|
|
227
219
|
}, !loading && renderActionGroup(operation)))), info && /*#__PURE__*/_react.default.createElement("section", {
|
|
228
220
|
className: (0, _classnames2.default)(cls('section'), cls('info'))
|
|
229
|
-
}, !loading && renderInfo(info), loading && /*#__PURE__*/_react.default.createElement(_skeleton.ProSkeletonRaw.Info.Header, null)), children);
|
|
221
|
+
}, /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, !loading && renderInfo(info), loading && /*#__PURE__*/_react.default.createElement(_skeleton.ProSkeletonRaw.Info.Header, null))), children);
|
|
230
222
|
};
|
|
231
223
|
var _default = ProPageHeader;
|
|
232
|
-
/**
|
|
233
|
-
* @deprecated 建议使用 ProPageHeaderBreadcrumbItem 代替
|
|
234
|
-
*/
|
|
235
224
|
exports.default = _default;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
@import "xconsole";
|
|
1
2
|
$prefix: 'teamix-pro-page-header';
|
|
2
3
|
|
|
3
4
|
.#{$prefix} {
|
|
@@ -12,7 +13,7 @@ $prefix: 'teamix-pro-page-header';
|
|
|
12
13
|
justify-content: space-between;
|
|
13
14
|
align-items: center;
|
|
14
15
|
min-height: 18px;
|
|
15
|
-
height:
|
|
16
|
+
height: auto;
|
|
16
17
|
margin-bottom: var(--s-2, 8px);
|
|
17
18
|
|
|
18
19
|
&.with-description {
|
|
@@ -20,7 +20,9 @@ function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableTo
|
|
|
20
20
|
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
21
21
|
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
22
22
|
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
23
|
-
function
|
|
23
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
24
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
25
|
+
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; }
|
|
24
26
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
25
27
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
26
28
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
@@ -61,13 +63,11 @@ var ProSidebarContainer = function ProSidebarContainer(props) {
|
|
|
61
63
|
_useState2 = _slicedToArray(_useState, 2),
|
|
62
64
|
treeHeight = _useState2[0],
|
|
63
65
|
setTreeHeight = _useState2[1];
|
|
64
|
-
|
|
65
66
|
// 展开全部状态
|
|
66
67
|
var _useState3 = (0, _react.useState)(false),
|
|
67
68
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
68
69
|
expandAllState = _useState4[0],
|
|
69
70
|
setExpandAllState = _useState4[1];
|
|
70
|
-
|
|
71
71
|
// 展开层级状态
|
|
72
72
|
var _useState5 = (0, _react.useState)(1),
|
|
73
73
|
_useState6 = _slicedToArray(_useState5, 2),
|
|
@@ -95,13 +95,12 @@ var ProSidebarContainer = function ProSidebarContainer(props) {
|
|
|
95
95
|
onExpandAllChange === null || onExpandAllChange === void 0 ? void 0 : onExpandAllChange(expandAllStateProp);
|
|
96
96
|
});
|
|
97
97
|
}, [expandAllStateProp]);
|
|
98
|
-
|
|
99
98
|
// 渲染搜索区域
|
|
100
99
|
var renderSearch = function renderSearch() {
|
|
101
100
|
if (customSearch || showSearch) {
|
|
102
101
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
103
102
|
className: cls('search')
|
|
104
|
-
}, !!customSearch && customSearch, showSearch && /*#__PURE__*/_react.default.createElement(_proField.default,
|
|
103
|
+
}, !!customSearch && customSearch, showSearch && /*#__PURE__*/_react.default.createElement(_proField.default, _objectSpread({
|
|
105
104
|
mode: "edit",
|
|
106
105
|
type: "text",
|
|
107
106
|
placeholder: searchPlaceholder,
|
|
@@ -111,16 +110,15 @@ var ProSidebarContainer = function ProSidebarContainer(props) {
|
|
|
111
110
|
}
|
|
112
111
|
return null;
|
|
113
112
|
};
|
|
114
|
-
|
|
115
113
|
// 渲染通知区域
|
|
116
114
|
var renderNotice = function renderNotice() {
|
|
117
115
|
if (message || customMessage) {
|
|
118
116
|
return /*#__PURE__*/_react.default.createElement("div", {
|
|
119
117
|
className: cls('notice')
|
|
120
|
-
}, message && /*#__PURE__*/_react.default.createElement(_components.Message,
|
|
118
|
+
}, message && /*#__PURE__*/_react.default.createElement(_components.Message, _objectSpread(_objectSpread({
|
|
121
119
|
type: "notice",
|
|
122
120
|
closeable: true
|
|
123
|
-
}, messageProps, {
|
|
121
|
+
}, messageProps), {}, {
|
|
124
122
|
onClose: function onClose() {
|
|
125
123
|
var _ref$current$offsetTo2, _ref$current2;
|
|
126
124
|
var remainHeight = (_ref$current$offsetTo2 = ref === null || ref === void 0 ? void 0 : (_ref$current2 = ref.current) === null || _ref$current2 === void 0 ? void 0 : _ref$current2.offsetTop) !== null && _ref$current$offsetTo2 !== void 0 ? _ref$current$offsetTo2 : 0 + 40;
|
|
@@ -130,7 +128,6 @@ var ProSidebarContainer = function ProSidebarContainer(props) {
|
|
|
130
128
|
}
|
|
131
129
|
return null;
|
|
132
130
|
};
|
|
133
|
-
|
|
134
131
|
// 渲染折叠区
|
|
135
132
|
var renderFold = function renderFold() {
|
|
136
133
|
if (showExpandAll || showExpandLevel) {
|
|
@@ -166,7 +163,7 @@ var ProSidebarContainer = function ProSidebarContainer(props) {
|
|
|
166
163
|
'': true,
|
|
167
164
|
'not-is-tree': !isTree
|
|
168
165
|
})
|
|
169
|
-
}, /*#__PURE__*/_react.default.createElement(_card.ProCard,
|
|
166
|
+
}, /*#__PURE__*/_react.default.createElement(_card.ProCard, _objectSpread({
|
|
170
167
|
bordered: false,
|
|
171
168
|
compacted: true
|
|
172
169
|
}, others), renderSearch(), renderNotice(), renderFold(), /*#__PURE__*/_react.default.createElement("div", {
|