@luck-design-biz/luckda 0.0.24-2 → 0.0.24-3
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/es/components/Builder/index.js +27 -22
- package/es/components/LdAutoForm/index.js +15 -5
- package/es/components/LdFormList/index.js +4 -1
- package/es/components/LdGrid/index.js +15 -18
- package/es/components/LdGridForm/index.js +12 -4
- package/es/helper/form.js +8 -2
- package/es/helper/ldBuilder.js +4 -1
- package/es/lowcode/constants/api-url.js +1 -292
- package/es/lowcode/constants/event-topics.js +1 -14
- package/es/lowcode/engine/meta/button.props.default.json +7 -15
- package/es/lowcode/engine/meta/cardlist.props.default.json +9 -17
- package/{lib/lowcode/engine/meta/button.props.json → es/lowcode/engine/meta/components/button.json} +103 -126
- package/es/lowcode/engine/meta/{cardlist.props.json → components/card-list.json} +142 -143
- package/es/lowcode/engine/meta/{drawer.props.json → components/drawer.json} +142 -143
- package/es/lowcode/engine/meta/{form.props.json → components/form.json} +115 -116
- package/{lib/lowcode/engine/meta/iframe.props.json → es/lowcode/engine/meta/components/iframe.json} +30 -31
- package/{lib/lowcode/engine/meta/image.props.json → es/lowcode/engine/meta/components/image.json} +112 -113
- package/{lib/lowcode/engine/meta/imex.props.json → es/lowcode/engine/meta/components/imex.json} +80 -81
- package/es/lowcode/engine/meta/{jsx.props.json → components/jsx.json} +23 -24
- package/es/lowcode/engine/meta/{layout.props.json → components/layout.json} +106 -107
- package/{lib/lowcode/engine/meta/link.props.json → es/lowcode/engine/meta/components/link.json} +110 -111
- package/es/lowcode/engine/meta/{dialog.props.json → components/modal.json} +119 -120
- package/{lib/lowcode/engine/meta/section.props.json → es/lowcode/engine/meta/components/section.json} +106 -107
- package/{lib/lowcode/engine/meta/split.props.json → es/lowcode/engine/meta/components/split.json} +70 -71
- package/es/lowcode/{view/lc-components/CardList/meta.json → engine/meta/components/table.json} +28 -11
- package/{lib/lowcode/engine/meta/tabs.props.json → es/lowcode/engine/meta/components/tabs.json} +139 -140
- package/{lib/lowcode/engine/meta/text.props.json → es/lowcode/engine/meta/components/text.json} +64 -65
- package/es/lowcode/engine/meta/{tree.props.json → components/tree.json} +155 -156
- package/es/lowcode/engine/meta/components-list.json +121 -127
- package/es/lowcode/engine/meta/drawer.props.default.json +9 -17
- package/es/lowcode/engine/meta/form.props.default.json +4 -12
- package/es/lowcode/engine/meta/iframe.props.default.json +2 -10
- package/es/lowcode/engine/meta/image.props.default.json +7 -15
- package/es/lowcode/engine/meta/imex.props.default.json +3 -11
- package/es/lowcode/engine/meta/jsx.props.default.json +1 -10
- package/es/lowcode/engine/meta/layout.props.default.json +4 -12
- package/es/lowcode/engine/meta/link.props.default.json +5 -13
- package/es/lowcode/engine/meta/modal.props.default.json +11 -0
- package/es/lowcode/engine/meta/section.props.default.json +8 -16
- package/es/lowcode/engine/meta/split.props.default.json +4 -12
- package/es/lowcode/engine/meta/table.props.default.json +9 -29
- package/es/lowcode/engine/meta/tabs.props.default.json +9 -17
- package/es/lowcode/engine/meta/text.props.default.json +3 -11
- package/es/lowcode/engine/meta/tree.props.default.json +8 -16
- package/es/lowcode/engine/provider/ContextProvider.js +41 -46
- package/es/lowcode/engine/provider/EventBusProvider.js +2 -2
- package/es/lowcode/engine/tools/dataProcess.js +8 -85
- package/es/lowcode/engine/tools/helper.js +0 -68
- package/es/lowcode/engine/tools/lcid.js +16 -0
- package/es/lowcode/index.js +1 -3
- package/es/lowcode/painter/Design.js +85 -40
- package/es/lowcode/painter/I18n.js +2 -202
- package/es/lowcode/painter/Outline.js +54 -63
- package/es/lowcode/painter/Panel.js +2 -239
- package/es/lowcode/painter/Ribbon.js +55 -61
- package/es/lowcode/painter/components/PanelItem.js +11 -83
- package/es/lowcode/painter/components/RuleInput.js +7 -9
- package/es/lowcode/painter/index.js +3 -33
- package/es/lowcode/painter/panel-section/LayoutRatio.js +49 -57
- package/es/lowcode/painter/panel-section/Radio.js +58 -0
- package/es/lowcode/painter/style/design.less +5 -116
- package/es/lowcode/painter/style/index.less +1 -0
- package/es/lowcode/painter/style/layout-ratio.less +1 -1
- package/es/lowcode/painter/style/outline.less +0 -2
- package/es/lowcode/painter/style/panel-item.less +12 -45
- package/es/lowcode/painter/style/panel.less +0 -124
- package/es/lowcode/painter/style/ribbon.less +0 -1
- package/es/lowcode/view/Canvas.js +70 -79
- package/es/lowcode/view/Page.js +28 -10
- package/es/lowcode/view/index.js +6 -5
- package/es/lowcode/view/lc-components/Box/index.js +5 -22
- package/es/lowcode/view/lc-components/Button/index.js +7 -75
- package/es/lowcode/view/lc-components/Dialog/index.js +11 -20
- package/es/lowcode/view/lc-components/Dialog/index.less +1 -1
- package/es/lowcode/view/lc-components/Drawer/index.js +9 -22
- package/es/lowcode/view/lc-components/Layout/index.js +7 -40
- package/es/lowcode/view/lc-components/Table/index.js +9 -229
- package/es/lowcode/view/lc-components/Wrapper.js +23 -32
- package/es/lowcode/view/style/page.less +1 -0
- package/es/services.js +24 -7
- package/es/upload/Form/gridForm.js +5 -4
- package/es/upload/FormItem/index.js +4 -3
- package/es/utils/form.js +37 -3
- package/es/utils/grid.js +9 -8
- package/lib/components/Builder/index.js +25 -20
- package/lib/components/LdAutoForm/index.js +14 -4
- package/lib/components/LdFormList/index.js +5 -1
- package/lib/components/LdGrid/index.js +15 -18
- package/lib/components/LdGridForm/index.js +11 -3
- package/lib/helper/form.js +8 -2
- package/lib/helper/ldBuilder.js +4 -1
- package/lib/lowcode/constants/api-url.js +2 -294
- package/lib/lowcode/constants/event-topics.js +2 -15
- package/lib/lowcode/engine/meta/button.props.default.json +7 -15
- package/lib/lowcode/engine/meta/cardlist.props.default.json +9 -17
- package/{es/lowcode/engine/meta/button.props.json → lib/lowcode/engine/meta/components/button.json} +103 -126
- package/lib/lowcode/engine/meta/{cardlist.props.json → components/card-list.json} +142 -143
- package/lib/lowcode/engine/meta/{drawer.props.json → components/drawer.json} +142 -143
- package/lib/lowcode/engine/meta/{form.props.json → components/form.json} +115 -116
- package/{es/lowcode/engine/meta/iframe.props.json → lib/lowcode/engine/meta/components/iframe.json} +30 -31
- package/{es/lowcode/engine/meta/image.props.json → lib/lowcode/engine/meta/components/image.json} +112 -113
- package/{es/lowcode/engine/meta/imex.props.json → lib/lowcode/engine/meta/components/imex.json} +80 -81
- package/lib/lowcode/engine/meta/{jsx.props.json → components/jsx.json} +23 -24
- package/lib/lowcode/engine/meta/{layout.props.json → components/layout.json} +106 -107
- package/{es/lowcode/engine/meta/link.props.json → lib/lowcode/engine/meta/components/link.json} +110 -111
- package/lib/lowcode/engine/meta/{dialog.props.json → components/modal.json} +119 -120
- package/{es/lowcode/engine/meta/section.props.json → lib/lowcode/engine/meta/components/section.json} +106 -107
- package/{es/lowcode/engine/meta/split.props.json → lib/lowcode/engine/meta/components/split.json} +70 -71
- package/lib/lowcode/{view/lc-components/CardList/meta.json → engine/meta/components/table.json} +28 -11
- package/{es/lowcode/engine/meta/tabs.props.json → lib/lowcode/engine/meta/components/tabs.json} +139 -140
- package/{es/lowcode/engine/meta/text.props.json → lib/lowcode/engine/meta/components/text.json} +64 -65
- package/lib/lowcode/engine/meta/{tree.props.json → components/tree.json} +155 -156
- package/lib/lowcode/engine/meta/components-list.json +121 -127
- package/lib/lowcode/engine/meta/drawer.props.default.json +9 -17
- package/lib/lowcode/engine/meta/form.props.default.json +4 -12
- package/lib/lowcode/engine/meta/iframe.props.default.json +2 -10
- package/lib/lowcode/engine/meta/image.props.default.json +7 -15
- package/lib/lowcode/engine/meta/imex.props.default.json +3 -11
- package/lib/lowcode/engine/meta/jsx.props.default.json +1 -10
- package/lib/lowcode/engine/meta/layout.props.default.json +4 -12
- package/lib/lowcode/engine/meta/link.props.default.json +5 -13
- package/lib/lowcode/engine/meta/modal.props.default.json +11 -0
- package/lib/lowcode/engine/meta/section.props.default.json +8 -16
- package/lib/lowcode/engine/meta/split.props.default.json +4 -12
- package/lib/lowcode/engine/meta/table.props.default.json +9 -29
- package/lib/lowcode/engine/meta/tabs.props.default.json +9 -17
- package/lib/lowcode/engine/meta/text.props.default.json +3 -11
- package/lib/lowcode/engine/meta/tree.props.default.json +8 -16
- package/lib/lowcode/engine/provider/ContextProvider.js +41 -46
- package/lib/lowcode/engine/provider/EventBusProvider.js +2 -2
- package/lib/lowcode/engine/tools/dataProcess.js +8 -86
- package/lib/lowcode/engine/tools/helper.js +0 -70
- package/lib/lowcode/engine/tools/lcid.js +22 -0
- package/lib/lowcode/index.js +1 -5
- package/lib/lowcode/painter/Design.js +84 -39
- package/lib/lowcode/painter/I18n.js +2 -203
- package/lib/lowcode/painter/Outline.js +53 -62
- package/lib/lowcode/painter/Panel.js +1 -238
- package/lib/lowcode/painter/Ribbon.js +64 -63
- package/lib/lowcode/painter/components/PanelItem.js +11 -84
- package/lib/lowcode/painter/components/RuleInput.js +7 -9
- package/lib/lowcode/painter/index.js +3 -35
- package/lib/lowcode/painter/panel-section/LayoutRatio.js +48 -56
- package/lib/lowcode/painter/panel-section/Radio.js +65 -0
- package/lib/lowcode/painter/style/design.less +5 -116
- package/lib/lowcode/painter/style/index.less +1 -0
- package/lib/lowcode/painter/style/layout-ratio.less +1 -1
- package/lib/lowcode/painter/style/outline.less +0 -2
- package/lib/lowcode/painter/style/panel-item.less +12 -45
- package/lib/lowcode/painter/style/panel.less +0 -124
- package/lib/lowcode/painter/style/ribbon.less +0 -1
- package/lib/lowcode/view/Canvas.js +75 -84
- package/lib/lowcode/view/Page.js +27 -9
- package/lib/lowcode/view/index.js +6 -5
- package/lib/lowcode/view/lc-components/Box/index.js +6 -23
- package/lib/lowcode/view/lc-components/Button/index.js +8 -76
- package/lib/lowcode/view/lc-components/Dialog/index.js +11 -20
- package/lib/lowcode/view/lc-components/Dialog/index.less +1 -1
- package/lib/lowcode/view/lc-components/Drawer/index.js +9 -22
- package/lib/lowcode/view/lc-components/Layout/index.js +8 -41
- package/lib/lowcode/view/lc-components/Table/index.js +8 -228
- package/lib/lowcode/view/lc-components/Wrapper.js +21 -30
- package/lib/lowcode/view/style/page.less +1 -0
- package/lib/services.js +25 -7
- package/lib/upload/Form/gridForm.js +5 -4
- package/lib/upload/FormItem/index.js +4 -3
- package/lib/utils/form.js +38 -3
- package/lib/utils/grid.js +11 -10
- package/package.json +6 -15
- package/es/lowcode/engine/factory/panel-item-factory/DynamicStrategy.js +0 -60
- package/es/lowcode/engine/factory/panel-item-factory/GroupStrategy.js +0 -32
- package/es/lowcode/engine/factory/panel-item-factory/NumberStrategy.js +0 -32
- package/es/lowcode/engine/factory/panel-item-factory/SegmentedStrategy.js +0 -32
- package/es/lowcode/engine/factory/panel-item-factory/SelectStrategy.js +0 -53
- package/es/lowcode/engine/factory/panel-item-factory/Strategy.js +0 -21
- package/es/lowcode/engine/factory/panel-item-factory/StringStrategy.js +0 -51
- package/es/lowcode/engine/factory/panel-item-factory/SwitchStrategy.js +0 -42
- package/es/lowcode/engine/factory/panel-item-factory/index.js +0 -44
- package/es/lowcode/engine/meta/box.props.default.json +0 -12
- package/es/lowcode/engine/meta/box.props.json +0 -42
- package/es/lowcode/engine/meta/dialog.props.default.json +0 -19
- package/es/lowcode/engine/meta/js-editor/auto-complete.json +0 -29
- package/es/lowcode/engine/meta/table.props.json +0 -236
- package/es/lowcode/engine/tools/usePromiseState.js +0 -24
- package/es/lowcode/painter/DesignOperator.js +0 -271
- package/es/lowcode/painter/DesignToolbar.js +0 -91
- package/es/lowcode/painter/components/Collapse.js +0 -90
- package/es/lowcode/painter/components/ColorInput.js +0 -125
- package/es/lowcode/painter/components/ListEditor.js +0 -89
- package/es/lowcode/painter/components/NumberInput.js +0 -148
- package/es/lowcode/painter/components/PopConfirm.js +0 -23
- package/es/lowcode/painter/components/PopForm.js +0 -71
- package/es/lowcode/painter/components/SortBox.js +0 -92
- package/es/lowcode/painter/components/actions-editor/ActionEditor.js +0 -147
- package/es/lowcode/painter/components/actions-editor/index.js +0 -170
- package/es/lowcode/painter/components/code-editor/BaseEditor.js +0 -96
- package/es/lowcode/painter/components/code-editor/CssEditor.js +0 -41
- package/es/lowcode/painter/components/code-editor/FullScreenEditor.js +0 -87
- package/es/lowcode/painter/components/code-editor/JSEditor.js +0 -106
- package/es/lowcode/painter/components/code-editor/index.js +0 -2
- package/es/lowcode/painter/panel-section/ButtonType.js +0 -39
- package/es/lowcode/painter/panel-section/DataSetSelector.js +0 -61
- package/es/lowcode/painter/panel-section/Icon.js +0 -48
- package/es/lowcode/painter/panel-section/IconSelector.js +0 -134
- package/es/lowcode/painter/panel-section/StylePanel/BackGround.js +0 -61
- package/es/lowcode/painter/panel-section/StylePanel/Border.js +0 -150
- package/es/lowcode/painter/panel-section/StylePanel/BorderRadius.js +0 -87
- package/es/lowcode/painter/panel-section/StylePanel/BorderRadiusSelector.js +0 -66
- package/es/lowcode/painter/panel-section/StylePanel/BorderSelector.js +0 -66
- package/es/lowcode/painter/panel-section/StylePanel/Display.js +0 -296
- package/es/lowcode/painter/panel-section/StylePanel/DisplaySvg.js +0 -543
- package/es/lowcode/painter/panel-section/StylePanel/Font.js +0 -162
- package/es/lowcode/painter/panel-section/StylePanel/FontEditor.js +0 -386
- package/es/lowcode/painter/panel-section/StylePanel/GapSelector.js +0 -78
- package/es/lowcode/painter/panel-section/StylePanel/HighLightPanel.js +0 -23
- package/es/lowcode/painter/panel-section/StylePanel/HighLigthtSpan.js +0 -20
- package/es/lowcode/painter/panel-section/StylePanel/HightLightSvg.js +0 -23
- package/es/lowcode/painter/panel-section/StylePanel/MainPanel.js +0 -96
- package/es/lowcode/painter/panel-section/StylePanel/Margin.js +0 -60
- package/es/lowcode/painter/panel-section/StylePanel/Opacity.js +0 -50
- package/es/lowcode/painter/panel-section/StylePanel/Padding.js +0 -61
- package/es/lowcode/painter/panel-section/StylePanel/Pointer.js +0 -41
- package/es/lowcode/painter/panel-section/StylePanel/Shadow.js +0 -216
- package/es/lowcode/painter/panel-section/StylePanel/Size.js +0 -53
- package/es/lowcode/painter/panel-section/StylePanel/StyleContext.js +0 -148
- package/es/lowcode/painter/panel-section/StylePanel/StyleRow.js +0 -16
- package/es/lowcode/painter/panel-section/StylePanel/WidthHeight.js +0 -51
- package/es/lowcode/painter/panel-section/StylePanel/index.js +0 -29
- package/es/lowcode/painter/panel-section/TabItems.js +0 -207
- package/es/lowcode/painter/panel-section/TableActions.js +0 -19
- package/es/lowcode/painter/panel-section/TableZebra.js +0 -14
- package/es/lowcode/painter/panel-section/WidthHeight.js +0 -39
- package/es/lowcode/painter/services/I18n.js +0 -85
- package/es/lowcode/painter/style/actions-editor.less +0 -16
- package/es/lowcode/painter/style/border-editor.less +0 -36
- package/es/lowcode/painter/style/border-radius-selector.less +0 -43
- package/es/lowcode/painter/style/border-selector.less +0 -40
- package/es/lowcode/painter/style/button-type.less +0 -5
- package/es/lowcode/painter/style/collapse.less +0 -22
- package/es/lowcode/painter/style/color-input.less +0 -19
- package/es/lowcode/painter/style/display.less +0 -17
- package/es/lowcode/painter/style/font-editor.less +0 -9
- package/es/lowcode/painter/style/fullscreen-editor.less +0 -17
- package/es/lowcode/painter/style/icon-selector.less +0 -22
- package/es/lowcode/painter/style/icon.less +0 -11
- package/es/lowcode/painter/style/list-editor.less +0 -59
- package/es/lowcode/painter/style/number-input.less +0 -17
- package/es/lowcode/painter/style/pop-confirm.less +0 -10
- package/es/lowcode/painter/style/pop-form.less +0 -20
- package/es/lowcode/painter/style/style-panel.less +0 -37
- package/es/lowcode/painter/style/tabitems.less +0 -90
- package/es/lowcode/view/lc-components/Box/FunctionDesign.js +0 -20
- package/es/lowcode/view/lc-components/Box/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Box/index.less +0 -15
- package/es/lowcode/view/lc-components/Box/meta.json +0 -42
- package/es/lowcode/view/lc-components/Button/FunctionDesign.js +0 -21
- package/es/lowcode/view/lc-components/Button/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Button/meta.json +0 -127
- package/es/lowcode/view/lc-components/Button/style.less +0 -3
- package/es/lowcode/view/lc-components/CardList/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/CardList/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Dialog/FunctionDesign.js +0 -54
- package/es/lowcode/view/lc-components/Dialog/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Dialog/meta.json +0 -121
- package/es/lowcode/view/lc-components/Drawer/FunctionDesign.js +0 -20
- package/es/lowcode/view/lc-components/Drawer/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Drawer/index.less +0 -7
- package/es/lowcode/view/lc-components/Drawer/meta.json +0 -144
- package/es/lowcode/view/lc-components/Form/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Form/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Form/meta.json +0 -117
- package/es/lowcode/view/lc-components/Iframe/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Iframe/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Iframe/meta.json +0 -32
- package/es/lowcode/view/lc-components/ImEx/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/ImEx/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/ImEx/meta.json +0 -82
- package/es/lowcode/view/lc-components/Image/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Image/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Image/meta.json +0 -114
- package/es/lowcode/view/lc-components/JSX/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/JSX/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/JSX/meta.json +0 -25
- package/es/lowcode/view/lc-components/Layout/FunctionDesign.js +0 -75
- package/es/lowcode/view/lc-components/Layout/FunctionLive.js +0 -15
- package/es/lowcode/view/lc-components/Layout/index.less +0 -5
- package/es/lowcode/view/lc-components/Layout/meta.json +0 -108
- package/es/lowcode/view/lc-components/Link/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Link/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Link/meta.json +0 -112
- package/es/lowcode/view/lc-components/Section/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Section/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Section/meta.json +0 -108
- package/es/lowcode/view/lc-components/Split/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Split/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Split/meta.json +0 -72
- package/es/lowcode/view/lc-components/Table/FunctionDesign.js +0 -18
- package/es/lowcode/view/lc-components/Table/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Table/meta.json +0 -225
- package/es/lowcode/view/lc-components/Tabs/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Tabs/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Tabs/meta.json +0 -141
- package/es/lowcode/view/lc-components/Text/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Text/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Text/meta.json +0 -66
- package/es/lowcode/view/lc-components/Tree/FunctionDesign.js +0 -9
- package/es/lowcode/view/lc-components/Tree/FunctionLive.js +0 -9
- package/es/lowcode/view/lc-components/Tree/meta.json +0 -157
- package/lib/lowcode/engine/factory/panel-item-factory/DynamicStrategy.js +0 -73
- package/lib/lowcode/engine/factory/panel-item-factory/GroupStrategy.js +0 -38
- package/lib/lowcode/engine/factory/panel-item-factory/NumberStrategy.js +0 -38
- package/lib/lowcode/engine/factory/panel-item-factory/SegmentedStrategy.js +0 -38
- package/lib/lowcode/engine/factory/panel-item-factory/SelectStrategy.js +0 -59
- package/lib/lowcode/engine/factory/panel-item-factory/Strategy.js +0 -27
- package/lib/lowcode/engine/factory/panel-item-factory/StringStrategy.js +0 -57
- package/lib/lowcode/engine/factory/panel-item-factory/SwitchStrategy.js +0 -48
- package/lib/lowcode/engine/factory/panel-item-factory/index.js +0 -50
- package/lib/lowcode/engine/meta/box.props.default.json +0 -12
- package/lib/lowcode/engine/meta/box.props.json +0 -42
- package/lib/lowcode/engine/meta/dialog.props.default.json +0 -19
- package/lib/lowcode/engine/meta/js-editor/auto-complete.json +0 -29
- package/lib/lowcode/engine/meta/table.props.json +0 -236
- package/lib/lowcode/engine/tools/usePromiseState.js +0 -31
- package/lib/lowcode/painter/DesignOperator.js +0 -278
- package/lib/lowcode/painter/DesignToolbar.js +0 -99
- package/lib/lowcode/painter/components/Collapse.js +0 -97
- package/lib/lowcode/painter/components/ColorInput.js +0 -132
- package/lib/lowcode/painter/components/ListEditor.js +0 -95
- package/lib/lowcode/painter/components/NumberInput.js +0 -155
- package/lib/lowcode/painter/components/PopConfirm.js +0 -29
- package/lib/lowcode/painter/components/PopForm.js +0 -77
- package/lib/lowcode/painter/components/SortBox.js +0 -99
- package/lib/lowcode/painter/components/actions-editor/ActionEditor.js +0 -155
- package/lib/lowcode/painter/components/actions-editor/index.js +0 -178
- package/lib/lowcode/painter/components/code-editor/BaseEditor.js +0 -103
- package/lib/lowcode/painter/components/code-editor/CssEditor.js +0 -48
- package/lib/lowcode/painter/components/code-editor/FullScreenEditor.js +0 -94
- package/lib/lowcode/painter/components/code-editor/JSEditor.js +0 -117
- package/lib/lowcode/painter/components/code-editor/index.js +0 -20
- package/lib/lowcode/painter/panel-section/ButtonType.js +0 -46
- package/lib/lowcode/painter/panel-section/DataSetSelector.js +0 -69
- package/lib/lowcode/painter/panel-section/Icon.js +0 -54
- package/lib/lowcode/painter/panel-section/IconSelector.js +0 -141
- package/lib/lowcode/painter/panel-section/StylePanel/BackGround.js +0 -68
- package/lib/lowcode/painter/panel-section/StylePanel/Border.js +0 -158
- package/lib/lowcode/painter/panel-section/StylePanel/BorderRadius.js +0 -95
- package/lib/lowcode/painter/panel-section/StylePanel/BorderRadiusSelector.js +0 -73
- package/lib/lowcode/painter/panel-section/StylePanel/BorderSelector.js +0 -73
- package/lib/lowcode/painter/panel-section/StylePanel/Display.js +0 -303
- package/lib/lowcode/painter/panel-section/StylePanel/DisplaySvg.js +0 -550
- package/lib/lowcode/painter/panel-section/StylePanel/Font.js +0 -170
- package/lib/lowcode/painter/panel-section/StylePanel/FontEditor.js +0 -392
- package/lib/lowcode/painter/panel-section/StylePanel/GapSelector.js +0 -85
- package/lib/lowcode/painter/panel-section/StylePanel/HighLightPanel.js +0 -29
- package/lib/lowcode/painter/panel-section/StylePanel/HighLigthtSpan.js +0 -26
- package/lib/lowcode/painter/panel-section/StylePanel/HightLightSvg.js +0 -29
- package/lib/lowcode/painter/panel-section/StylePanel/MainPanel.js +0 -103
- package/lib/lowcode/painter/panel-section/StylePanel/Margin.js +0 -67
- package/lib/lowcode/painter/panel-section/StylePanel/Opacity.js +0 -57
- package/lib/lowcode/painter/panel-section/StylePanel/Padding.js +0 -68
- package/lib/lowcode/painter/panel-section/StylePanel/Pointer.js +0 -48
- package/lib/lowcode/painter/panel-section/StylePanel/Shadow.js +0 -224
- package/lib/lowcode/painter/panel-section/StylePanel/Size.js +0 -59
- package/lib/lowcode/painter/panel-section/StylePanel/StyleContext.js +0 -159
- package/lib/lowcode/painter/panel-section/StylePanel/StyleRow.js +0 -22
- package/lib/lowcode/painter/panel-section/StylePanel/WidthHeight.js +0 -58
- package/lib/lowcode/painter/panel-section/StylePanel/index.js +0 -35
- package/lib/lowcode/painter/panel-section/TabItems.js +0 -215
- package/lib/lowcode/painter/panel-section/TableActions.js +0 -26
- package/lib/lowcode/painter/panel-section/TableZebra.js +0 -21
- package/lib/lowcode/painter/panel-section/WidthHeight.js +0 -46
- package/lib/lowcode/painter/services/I18n.js +0 -95
- package/lib/lowcode/painter/style/actions-editor.less +0 -16
- package/lib/lowcode/painter/style/border-editor.less +0 -36
- package/lib/lowcode/painter/style/border-radius-selector.less +0 -43
- package/lib/lowcode/painter/style/border-selector.less +0 -40
- package/lib/lowcode/painter/style/button-type.less +0 -5
- package/lib/lowcode/painter/style/collapse.less +0 -22
- package/lib/lowcode/painter/style/color-input.less +0 -19
- package/lib/lowcode/painter/style/display.less +0 -17
- package/lib/lowcode/painter/style/font-editor.less +0 -9
- package/lib/lowcode/painter/style/fullscreen-editor.less +0 -17
- package/lib/lowcode/painter/style/icon-selector.less +0 -22
- package/lib/lowcode/painter/style/icon.less +0 -11
- package/lib/lowcode/painter/style/list-editor.less +0 -59
- package/lib/lowcode/painter/style/number-input.less +0 -17
- package/lib/lowcode/painter/style/pop-confirm.less +0 -10
- package/lib/lowcode/painter/style/pop-form.less +0 -20
- package/lib/lowcode/painter/style/style-panel.less +0 -37
- package/lib/lowcode/painter/style/tabitems.less +0 -90
- package/lib/lowcode/view/lc-components/Box/FunctionDesign.js +0 -27
- package/lib/lowcode/view/lc-components/Box/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Box/index.less +0 -15
- package/lib/lowcode/view/lc-components/Box/meta.json +0 -42
- package/lib/lowcode/view/lc-components/Button/FunctionDesign.js +0 -28
- package/lib/lowcode/view/lc-components/Button/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Button/meta.json +0 -127
- package/lib/lowcode/view/lc-components/Button/style.less +0 -3
- package/lib/lowcode/view/lc-components/CardList/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/CardList/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Dialog/FunctionDesign.js +0 -62
- package/lib/lowcode/view/lc-components/Dialog/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Dialog/meta.json +0 -121
- package/lib/lowcode/view/lc-components/Drawer/FunctionDesign.js +0 -27
- package/lib/lowcode/view/lc-components/Drawer/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Drawer/index.less +0 -7
- package/lib/lowcode/view/lc-components/Drawer/meta.json +0 -144
- package/lib/lowcode/view/lc-components/Form/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Form/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Form/meta.json +0 -117
- package/lib/lowcode/view/lc-components/Iframe/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Iframe/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Iframe/meta.json +0 -32
- package/lib/lowcode/view/lc-components/ImEx/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/ImEx/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/ImEx/meta.json +0 -82
- package/lib/lowcode/view/lc-components/Image/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Image/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Image/meta.json +0 -114
- package/lib/lowcode/view/lc-components/JSX/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/JSX/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/JSX/meta.json +0 -25
- package/lib/lowcode/view/lc-components/Layout/FunctionDesign.js +0 -82
- package/lib/lowcode/view/lc-components/Layout/FunctionLive.js +0 -22
- package/lib/lowcode/view/lc-components/Layout/index.less +0 -5
- package/lib/lowcode/view/lc-components/Layout/meta.json +0 -108
- package/lib/lowcode/view/lc-components/Link/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Link/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Link/meta.json +0 -112
- package/lib/lowcode/view/lc-components/Section/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Section/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Section/meta.json +0 -108
- package/lib/lowcode/view/lc-components/Split/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Split/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Split/meta.json +0 -72
- package/lib/lowcode/view/lc-components/Table/FunctionDesign.js +0 -25
- package/lib/lowcode/view/lc-components/Table/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Table/meta.json +0 -225
- package/lib/lowcode/view/lc-components/Tabs/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Tabs/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Tabs/meta.json +0 -141
- package/lib/lowcode/view/lc-components/Text/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Text/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Text/meta.json +0 -66
- package/lib/lowcode/view/lc-components/Tree/FunctionDesign.js +0 -16
- package/lib/lowcode/view/lc-components/Tree/FunctionLive.js +0 -16
- package/lib/lowcode/view/lc-components/Tree/meta.json +0 -157
|
@@ -1,25 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
4
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
5
5
|
Object.defineProperty(exports, "__esModule", {
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.default = void 0;
|
|
9
|
-
var
|
|
9
|
+
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
|
-
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
12
11
|
var _ahooks = require("ahooks");
|
|
13
12
|
var _Wrapper = _interopRequireDefault(require("../Wrapper"));
|
|
14
|
-
var
|
|
15
|
-
var _layoutPropsDefault = _interopRequireDefault(require("../../../engine/meta/layout.props.default.json"));
|
|
13
|
+
var _excluded = ["id", "children"];
|
|
16
14
|
var LCLayout = function LCLayout(_ref) {
|
|
17
15
|
var id = _ref.id,
|
|
18
16
|
children = _ref.children,
|
|
19
|
-
|
|
20
|
-
columnSpacing = _ref.columnSpacing,
|
|
21
|
-
lineSpacing = _ref.lineSpacing,
|
|
22
|
-
style = _ref.style;
|
|
17
|
+
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
23
18
|
var ref = (0, _react.useRef)();
|
|
24
19
|
var getTargetDom = (0, _ahooks.useMemoizedFn)(function () {
|
|
25
20
|
return ref.current;
|
|
@@ -29,37 +24,9 @@ var LCLayout = function LCLayout(_ref) {
|
|
|
29
24
|
getTargetDom: getTargetDom
|
|
30
25
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
31
26
|
ref: ref,
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
}, children));
|
|
37
|
-
};
|
|
38
|
-
LCLayout.propTypes = {
|
|
39
|
-
/**
|
|
40
|
-
* @name 唯一标识
|
|
41
|
-
* @type string
|
|
42
|
-
* @disabled true
|
|
43
|
-
*/
|
|
44
|
-
id: _propTypes.default.string.isRequired,
|
|
45
|
-
/**
|
|
46
|
-
* @name 列比例
|
|
47
|
-
* @type string
|
|
48
|
-
* @default 12:3:9
|
|
49
|
-
*/
|
|
50
|
-
columnRatio: _propTypes.default.string,
|
|
51
|
-
/**
|
|
52
|
-
* @name 列间距
|
|
53
|
-
* @type number
|
|
54
|
-
* @default 16
|
|
55
|
-
*/
|
|
56
|
-
columnSpacing: _propTypes.default.number,
|
|
57
|
-
/**
|
|
58
|
-
* @name 行间距
|
|
59
|
-
* @type number
|
|
60
|
-
* @default 8
|
|
61
|
-
*/
|
|
62
|
-
lineSpacing: _propTypes.default.number
|
|
27
|
+
style: {
|
|
28
|
+
padding: 8
|
|
29
|
+
}
|
|
30
|
+
}, "LCLayout-", id, children));
|
|
63
31
|
};
|
|
64
|
-
LCLayout.defaultProps = (0, _objectSpread2.default)({}, _layoutPropsDefault.default);
|
|
65
32
|
var _default = exports.default = LCLayout;
|
|
@@ -6,246 +6,26 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
value: true
|
|
7
7
|
});
|
|
8
8
|
exports.default = void 0;
|
|
9
|
-
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
11
9
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
12
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
13
|
-
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
14
11
|
var _ahooks = require("ahooks");
|
|
15
|
-
var _LdGrid = _interopRequireDefault(require("../../../../components/LdGrid"));
|
|
16
|
-
var _classnames = _interopRequireDefault(require("classnames"));
|
|
17
12
|
var _Wrapper = _interopRequireDefault(require("../Wrapper"));
|
|
18
|
-
var
|
|
19
|
-
var _tablePropsDefault = _interopRequireDefault(require("../../../engine/meta/table.props.default.json"));
|
|
20
|
-
var _excluded = ["context", "id", "className", "dataset", "width", "height", "bordered", "zebra", "autoLoad", "readOnly", "suppressActions", "actionsColumnWidth", "actions", "pagination", "pageSize", "showSizeChanger", "showQuickJumper", "hideOnSinglePage", "paginationSimple", "suppressPreset"];
|
|
13
|
+
var _excluded = ["id"];
|
|
21
14
|
var LCTable = function LCTable(_ref) {
|
|
22
|
-
var
|
|
23
|
-
id = _ref.id,
|
|
24
|
-
className = _ref.className,
|
|
25
|
-
dataset = _ref.dataset,
|
|
26
|
-
width = _ref.width,
|
|
27
|
-
height = _ref.height,
|
|
28
|
-
bordered = _ref.bordered,
|
|
29
|
-
zebra = _ref.zebra,
|
|
30
|
-
autoLoad = _ref.autoLoad,
|
|
31
|
-
readOnly = _ref.readOnly,
|
|
32
|
-
suppressActions = _ref.suppressActions,
|
|
33
|
-
actionsColumnWidth = _ref.actionsColumnWidth,
|
|
34
|
-
actions = _ref.actions,
|
|
35
|
-
pagination = _ref.pagination,
|
|
36
|
-
pageSize = _ref.pageSize,
|
|
37
|
-
showSizeChanger = _ref.showSizeChanger,
|
|
38
|
-
showQuickJumper = _ref.showQuickJumper,
|
|
39
|
-
hideOnSinglePage = _ref.hideOnSinglePage,
|
|
40
|
-
paginationSimple = _ref.paginationSimple,
|
|
41
|
-
suppressPreset = _ref.suppressPreset,
|
|
15
|
+
var id = _ref.id,
|
|
42
16
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
43
17
|
var ref = (0, _react.useRef)();
|
|
44
|
-
var latestZebra = (0, _ahooks.useLatest)(zebra);
|
|
45
|
-
var _pagination = (0, _ahooks.useCreation)(function () {
|
|
46
|
-
return {
|
|
47
|
-
isFlow: !pagination,
|
|
48
|
-
pagination: pagination ? {
|
|
49
|
-
pageSize: pageSize,
|
|
50
|
-
pageSizeOptions: ["".concat(pageSize), "".concat(pageSize * 2), "".concat(pageSize * 3)],
|
|
51
|
-
showSizeChanger: showSizeChanger,
|
|
52
|
-
showQuickJumper: showQuickJumper,
|
|
53
|
-
hideOnSinglePage: hideOnSinglePage,
|
|
54
|
-
simple: paginationSimple
|
|
55
|
-
} : null
|
|
56
|
-
};
|
|
57
|
-
}, [pagination, pageSize, showSizeChanger, showQuickJumper, hideOnSinglePage, paginationSimple]);
|
|
58
|
-
var _actionsColumn = (0, _ahooks.useCreation)(function () {
|
|
59
|
-
return {
|
|
60
|
-
actionsColumn: suppressActions ? null : {
|
|
61
|
-
width: actionsColumnWidth,
|
|
62
|
-
maxCount: actions.max,
|
|
63
|
-
type: actions.type,
|
|
64
|
-
getActions: function getActions() {
|
|
65
|
-
return actions.todoList.map(function (_action) {
|
|
66
|
-
return {
|
|
67
|
-
title: _action.name,
|
|
68
|
-
action: function action(d) {
|
|
69
|
-
console.log('doAction', d, _action);
|
|
70
|
-
},
|
|
71
|
-
resource: _action.serial,
|
|
72
|
-
style: _action.riskLevel === 'default' ? null : {
|
|
73
|
-
color: {
|
|
74
|
-
danger: '#ff7875',
|
|
75
|
-
destroy: '#820014'
|
|
76
|
-
}[_action.riskLevel]
|
|
77
|
-
}
|
|
78
|
-
};
|
|
79
|
-
});
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
};
|
|
83
|
-
}, [suppressActions, actionsColumnWidth, actions]);
|
|
84
|
-
(0, _ahooks.useUpdateEffect)(function () {
|
|
85
|
-
var itemsToUpdate = [];
|
|
86
|
-
ref.current.gridApi.api.forEachNode(function (rowNode) {
|
|
87
|
-
if (rowNode.rowIndex % 2 === 0) itemsToUpdate.push(rowNode.data);
|
|
88
|
-
});
|
|
89
|
-
ref.current.gridApi.api.updateRowData({
|
|
90
|
-
update: itemsToUpdate
|
|
91
|
-
});
|
|
92
|
-
}, [zebra]);
|
|
93
18
|
var getTargetDom = (0, _ahooks.useMemoizedFn)(function () {
|
|
94
|
-
return ref.current
|
|
19
|
+
return ref.current;
|
|
95
20
|
});
|
|
96
21
|
return /*#__PURE__*/_react.default.createElement(_Wrapper.default, {
|
|
97
22
|
id: id,
|
|
98
23
|
getTargetDom: getTargetDom
|
|
99
|
-
}, /*#__PURE__*/_react.default.createElement(
|
|
24
|
+
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
100
25
|
ref: ref,
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
className: (0, _classnames.default)((0, _defineProperty2.default)({}, className, !!className)),
|
|
106
|
-
ldId: id,
|
|
107
|
-
dataSetKey: dataset,
|
|
108
|
-
readOnly: readOnly,
|
|
109
|
-
suppressInit: !autoLoad,
|
|
110
|
-
getRowStyle: function getRowStyle(params) {
|
|
111
|
-
return latestZebra.current && params.node.rowIndex % 2 === 0 ? {
|
|
112
|
-
'background-color': latestZebra.current
|
|
113
|
-
} : {
|
|
114
|
-
'background-color': '#fff'
|
|
115
|
-
};
|
|
116
|
-
},
|
|
117
|
-
suppressPreset: suppressPreset
|
|
118
|
-
// operates={resources}
|
|
119
|
-
}, _pagination, _actionsColumn)));
|
|
120
|
-
};
|
|
121
|
-
LCTable.propTypes = {
|
|
122
|
-
/**
|
|
123
|
-
* @name 唯一标识
|
|
124
|
-
* @type string
|
|
125
|
-
* @disabled true
|
|
126
|
-
*/
|
|
127
|
-
id: _propTypes.default.string.isRequired,
|
|
128
|
-
/**
|
|
129
|
-
* @name 数据集
|
|
130
|
-
* @type _DataSetSelector
|
|
131
|
-
*/
|
|
132
|
-
dataset: _propTypes.default.string,
|
|
133
|
-
/**
|
|
134
|
-
* @name 自动加载
|
|
135
|
-
* @desc 首次数据是否自动加载,若存在必须带搜索条件再加载的情况,需要关闭
|
|
136
|
-
* @type switch
|
|
137
|
-
* @default true
|
|
138
|
-
*/
|
|
139
|
-
autoLoad: _propTypes.default.bool,
|
|
140
|
-
/**
|
|
141
|
-
* @name 只读
|
|
142
|
-
* @type switch
|
|
143
|
-
* @default false
|
|
144
|
-
*/
|
|
145
|
-
readOnly: _propTypes.default.bool,
|
|
146
|
-
/**
|
|
147
|
-
* @name 关闭预设
|
|
148
|
-
* @type switch
|
|
149
|
-
* @default false
|
|
150
|
-
*/
|
|
151
|
-
suppressPreset: _propTypes.default.bool,
|
|
152
|
-
/**
|
|
153
|
-
* @name 宽度
|
|
154
|
-
* @type _WidthHeight
|
|
155
|
-
* @default 100%
|
|
156
|
-
* @group styleSetting
|
|
157
|
-
*/
|
|
158
|
-
width: _propTypes.default.string,
|
|
159
|
-
/**
|
|
160
|
-
* @name 高度
|
|
161
|
-
* @type _WidthHeight
|
|
162
|
-
* @default 100%
|
|
163
|
-
* @group styleSetting
|
|
164
|
-
*/
|
|
165
|
-
height: _propTypes.default.string,
|
|
166
|
-
/**
|
|
167
|
-
* @name 边框线
|
|
168
|
-
* @type switch
|
|
169
|
-
* @default false
|
|
170
|
-
* @group styleSetting
|
|
171
|
-
*/
|
|
172
|
-
border: _propTypes.default.bool,
|
|
173
|
-
/**
|
|
174
|
-
* @name 斑马纹
|
|
175
|
-
* @type switch
|
|
176
|
-
* @default false
|
|
177
|
-
* @group styleSetting
|
|
178
|
-
*/
|
|
179
|
-
zebra: _propTypes.default.oneOfType[(_propTypes.default.bool, _propTypes.default.string)],
|
|
180
|
-
/**
|
|
181
|
-
* @name 开启分页
|
|
182
|
-
* @type switch
|
|
183
|
-
* @default true
|
|
184
|
-
* @group paginationSetting
|
|
185
|
-
*/
|
|
186
|
-
pagination: _propTypes.default.bool,
|
|
187
|
-
/**
|
|
188
|
-
* @name 每页条数
|
|
189
|
-
* @type number
|
|
190
|
-
* @default 30
|
|
191
|
-
* @group paginationSetting
|
|
192
|
-
*/
|
|
193
|
-
pageSize: _propTypes.default.number,
|
|
194
|
-
/**
|
|
195
|
-
* @name 分页器
|
|
196
|
-
* @type switch
|
|
197
|
-
* @default true
|
|
198
|
-
* @group paginationSetting
|
|
199
|
-
*/
|
|
200
|
-
showSizeChanger: _propTypes.default.bool,
|
|
201
|
-
/**
|
|
202
|
-
* @name 快速跳转
|
|
203
|
-
* @type switch
|
|
204
|
-
* @default true
|
|
205
|
-
* @group paginationSetting
|
|
206
|
-
*/
|
|
207
|
-
showQuickJumper: _propTypes.default.bool,
|
|
208
|
-
/**
|
|
209
|
-
* @name 单页无分页器
|
|
210
|
-
* @type switch
|
|
211
|
-
* @default false
|
|
212
|
-
* @group paginationSetting
|
|
213
|
-
*/
|
|
214
|
-
hideOnSinglePage: _propTypes.default.bool,
|
|
215
|
-
/**
|
|
216
|
-
* @name 简单模式
|
|
217
|
-
* @type switch
|
|
218
|
-
* @default false
|
|
219
|
-
* @group paginationSetting
|
|
220
|
-
*/
|
|
221
|
-
paginationSimple: _propTypes.default.bool,
|
|
222
|
-
/**
|
|
223
|
-
* @name 隐藏操作列
|
|
224
|
-
* @type switch
|
|
225
|
-
* @default false
|
|
226
|
-
* @groupNext actionsColumn
|
|
227
|
-
*/
|
|
228
|
-
suppressActions: _propTypes.default.bool,
|
|
229
|
-
/**
|
|
230
|
-
* @name 隐藏操作列
|
|
231
|
-
* @type number
|
|
232
|
-
* @default 160
|
|
233
|
-
* @groupNext actionsColumn
|
|
234
|
-
*/
|
|
235
|
-
actionsColumnWidth: _propTypes.default.number,
|
|
236
|
-
/**
|
|
237
|
-
* @name 最大显示数
|
|
238
|
-
* @type number
|
|
239
|
-
* @default 2
|
|
240
|
-
* @groupNext actionsColumn
|
|
241
|
-
*/
|
|
242
|
-
maxActionsCount: _propTypes.default.number,
|
|
243
|
-
/**
|
|
244
|
-
* @name 操作项
|
|
245
|
-
* @type _TableActions
|
|
246
|
-
* @groupNext actionsColumn
|
|
247
|
-
*/
|
|
248
|
-
actions: _propTypes.default.array
|
|
26
|
+
style: {
|
|
27
|
+
padding: 8
|
|
28
|
+
}
|
|
29
|
+
}, "LCTable-", id));
|
|
249
30
|
};
|
|
250
|
-
LCTable.defaultProps = (0, _helper.omitBadProps)(_tablePropsDefault.default, ['actionsColumn']);
|
|
251
31
|
var _default = exports.default = LCTable;
|
|
@@ -7,7 +7,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.default = void 0;
|
|
8
8
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
|
|
9
9
|
var _react = require("react");
|
|
10
|
-
var _ahooks = require("ahooks");
|
|
11
10
|
var _ContextProvider = require("../../engine/provider/ContextProvider");
|
|
12
11
|
var _dataProcess = require("../../engine/tools/dataProcess");
|
|
13
12
|
var _constants = require("../../constants");
|
|
@@ -17,37 +16,29 @@ var LCWrapper = function LCWrapper(_ref) {
|
|
|
17
16
|
getTargetDom = _ref.getTargetDom,
|
|
18
17
|
api = _ref.api;
|
|
19
18
|
var context = (0, _ContextProvider.useLDContext)();
|
|
20
|
-
var
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
},
|
|
26
|
-
getLevelNodes: function getLevelNodes() {
|
|
27
|
-
return (0, _dataProcess.getPathNodesById)(_pageData.current, id);
|
|
28
|
-
}
|
|
29
|
-
};
|
|
30
|
-
}, []);
|
|
19
|
+
var _apiRef = (0, _react.useRef)({
|
|
20
|
+
getSelfAndParentLCData: function getSelfAndParentLCData() {
|
|
21
|
+
return (0, _dataProcess.findNodeAndParent)(id, context.pageData);
|
|
22
|
+
}
|
|
23
|
+
});
|
|
31
24
|
(0, _react.useEffect)(function () {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
return api ? (0, _objectSpread2.default)((0, _objectSpread2.default)({}, _api), api.current) : _api;
|
|
44
|
-
}
|
|
45
|
-
return Reflect.get(target, property, receiver);
|
|
25
|
+
var dom = getTargetDom();
|
|
26
|
+
if (dom) {
|
|
27
|
+
dom.setAttribute('id', id);
|
|
28
|
+
dom.classList.add(_constants.CELL_CLASS_NAME);
|
|
29
|
+
}
|
|
30
|
+
context.register(id, new Proxy({
|
|
31
|
+
dom: dom
|
|
32
|
+
}, {
|
|
33
|
+
get: function get(target, property, receiver) {
|
|
34
|
+
if (property === 'api') {
|
|
35
|
+
return api ? (0, _objectSpread2.default)((0, _objectSpread2.default)({}, _apiRef.current), api.current) : _apiRef.current;
|
|
46
36
|
}
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
37
|
+
return Reflect.get(target, property, receiver);
|
|
38
|
+
}
|
|
39
|
+
}));
|
|
40
|
+
context.$publisher(context.topics.COMPONENT_MOUNT, {
|
|
41
|
+
id: id
|
|
51
42
|
});
|
|
52
43
|
return function () {
|
|
53
44
|
context.unregister(id);
|
package/lib/services.js
CHANGED
|
@@ -6,6 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.readBehaviorCall = readBehaviorCall;
|
|
8
8
|
exports.readModlue = readModlue;
|
|
9
|
+
exports.readUI = readUI;
|
|
9
10
|
var _regeneratorRuntime2 = _interopRequireDefault(require("@babel/runtime/helpers/regeneratorRuntime"));
|
|
10
11
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
11
12
|
var _querystring = require("querystring");
|
|
@@ -28,15 +29,32 @@ function _readModlue() {
|
|
|
28
29
|
}));
|
|
29
30
|
return _readModlue.apply(this, arguments);
|
|
30
31
|
}
|
|
31
|
-
function
|
|
32
|
-
return
|
|
32
|
+
function readUI(_x2) {
|
|
33
|
+
return _readUI.apply(this, arguments);
|
|
33
34
|
}
|
|
34
|
-
function
|
|
35
|
-
|
|
35
|
+
function _readUI() {
|
|
36
|
+
_readUI = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee2(get) {
|
|
36
37
|
return (0, _regeneratorRuntime2.default)().wrap(function _callee2$(_context2) {
|
|
37
38
|
while (1) switch (_context2.prev = _context2.next) {
|
|
38
39
|
case 0:
|
|
39
|
-
return _context2.abrupt("return", (0, _utils.request)("".concat(_ApiConfig.default.LUCKDA_HOST, "/
|
|
40
|
+
return _context2.abrupt("return", (0, _utils.request)("".concat(_ApiConfig.default.LUCKDA_HOST, "/ui/builder/noAuthFetchModuleDataSetUI?").concat((0, _querystring.stringify)(get))));
|
|
41
|
+
case 1:
|
|
42
|
+
case "end":
|
|
43
|
+
return _context2.stop();
|
|
44
|
+
}
|
|
45
|
+
}, _callee2);
|
|
46
|
+
}));
|
|
47
|
+
return _readUI.apply(this, arguments);
|
|
48
|
+
}
|
|
49
|
+
function readBehaviorCall(_x3, _x4) {
|
|
50
|
+
return _readBehaviorCall.apply(this, arguments);
|
|
51
|
+
}
|
|
52
|
+
function _readBehaviorCall() {
|
|
53
|
+
_readBehaviorCall = (0, _asyncToGenerator2.default)( /*#__PURE__*/(0, _regeneratorRuntime2.default)().mark(function _callee3(get, post) {
|
|
54
|
+
return (0, _regeneratorRuntime2.default)().wrap(function _callee3$(_context3) {
|
|
55
|
+
while (1) switch (_context3.prev = _context3.next) {
|
|
56
|
+
case 0:
|
|
57
|
+
return _context3.abrupt("return", (0, _utils.request)("".concat(_ApiConfig.default.LUCKDA_HOST, "/to/behavior/call?").concat((0, _querystring.stringify)(get)), {
|
|
40
58
|
method: 'POST',
|
|
41
59
|
body: post,
|
|
42
60
|
headers: {
|
|
@@ -45,9 +63,9 @@ function _readBehaviorCall() {
|
|
|
45
63
|
}));
|
|
46
64
|
case 1:
|
|
47
65
|
case "end":
|
|
48
|
-
return
|
|
66
|
+
return _context3.stop();
|
|
49
67
|
}
|
|
50
|
-
},
|
|
68
|
+
}, _callee3);
|
|
51
69
|
}));
|
|
52
70
|
return _readBehaviorCall.apply(this, arguments);
|
|
53
71
|
}
|
|
@@ -20,7 +20,7 @@ var _luckDesign = require("luck-design");
|
|
|
20
20
|
var _ApiConfig = _interopRequireDefault(require("@/services/ApiConfig"));
|
|
21
21
|
var _FormList = require("@luck-design-biz/base/FormList");
|
|
22
22
|
var _utils = require("@luck-design-biz/base/utils");
|
|
23
|
-
var _excluded = ["formId", "formRef", "showNote", "operates", "loading", "uploadUrl", "forbiddenTypes", "beforeUpload", "formMode", "onUploadChange", "zipName", "resetActions", "getUrl", "wrapperRef"];
|
|
23
|
+
var _excluded = ["formId", "formRef", "showNote", "operates", "loading", "uploadUrl", "supportTypes", "forbiddenTypes", "beforeUpload", "formMode", "onUploadChange", "zipName", "resetActions", "getUrl", "wrapperRef"];
|
|
24
24
|
var columns = [{
|
|
25
25
|
field: 'name',
|
|
26
26
|
title: '附件名称'
|
|
@@ -63,6 +63,7 @@ var UploadGridForm = function UploadGridForm(_ref) {
|
|
|
63
63
|
operates = _ref$operates === void 0 ? ['read', 'add', 'delete', 'download'] : _ref$operates,
|
|
64
64
|
loading = _ref.loading,
|
|
65
65
|
uploadUrl = _ref.uploadUrl,
|
|
66
|
+
supportTypes = _ref.supportTypes,
|
|
66
67
|
_ref$forbiddenTypes = _ref.forbiddenTypes,
|
|
67
68
|
forbiddenTypes = _ref$forbiddenTypes === void 0 ? [] : _ref$forbiddenTypes,
|
|
68
69
|
_beforeUpload = _ref.beforeUpload,
|
|
@@ -86,8 +87,8 @@ var UploadGridForm = function UploadGridForm(_ref) {
|
|
|
86
87
|
var _getDvaApp$_store$get = (_getDvaApp = (0, _umi.getDvaApp)()) === null || _getDvaApp === void 0 ? void 0 : _getDvaApp._store.getState().user,
|
|
87
88
|
currentUser = _getDvaApp$_store$get.currentUser;
|
|
88
89
|
var supportUploadTypes = (0, _ahooks.useCreation)(function () {
|
|
89
|
-
return (0, _utils.getSupportUploadTypes)(forbiddenTypes);
|
|
90
|
-
}, [forbiddenTypes]);
|
|
90
|
+
return (0, _utils.getSupportUploadTypes)(forbiddenTypes, supportTypes);
|
|
91
|
+
}, [forbiddenTypes, supportTypes]);
|
|
91
92
|
|
|
92
93
|
// 下载
|
|
93
94
|
var downloadFile = function downloadFile(filenames, tag) {
|
|
@@ -385,7 +386,7 @@ var UploadGridForm = function UploadGridForm(_ref) {
|
|
|
385
386
|
return (0, _utils.beforeUpload)({
|
|
386
387
|
file: file,
|
|
387
388
|
fileList: fileList,
|
|
388
|
-
|
|
389
|
+
forbiddenTypes: forbiddenTypes,
|
|
389
390
|
beforeUpload: _beforeUpload
|
|
390
391
|
});
|
|
391
392
|
}
|
|
@@ -12,7 +12,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
12
12
|
var _luckDesign = require("luck-design");
|
|
13
13
|
var _utils = require("@luck-design-biz/base/utils");
|
|
14
14
|
var _ahooks = require("ahooks");
|
|
15
|
-
var _excluded = ["uploadUrl", "moduleCode", "bucket", "tag", "note", "config", "forbiddenTypes", "children", "dataFormat", "listType"];
|
|
15
|
+
var _excluded = ["uploadUrl", "moduleCode", "bucket", "tag", "note", "config", "supportTypes", "forbiddenTypes", "children", "dataFormat", "listType"];
|
|
16
16
|
/**
|
|
17
17
|
* 表单类型富文本上传
|
|
18
18
|
* 是否实体字段: 是
|
|
@@ -41,6 +41,7 @@ function buildComponent(props) {
|
|
|
41
41
|
note = _props$note === void 0 ? '' : _props$note,
|
|
42
42
|
_props$config = props.config,
|
|
43
43
|
config = _props$config === void 0 ? {} : _props$config,
|
|
44
|
+
supportTypes = props.supportTypes,
|
|
44
45
|
forbiddenTypes = props.forbiddenTypes,
|
|
45
46
|
children = props.children,
|
|
46
47
|
dataFormat = props.dataFormat,
|
|
@@ -50,8 +51,8 @@ function buildComponent(props) {
|
|
|
50
51
|
return "".concat(window.appConfig.OSS_HOST_V3, "?moduleCode=").concat(moduleCode, "&behaviorKey=").concat(behaviorKey, "&bucket=").concat(bucket, "&tag=").concat(tag, "¬e=").concat(note);
|
|
51
52
|
};
|
|
52
53
|
var supportUploadTypes = (0, _ahooks.useCreation)(function () {
|
|
53
|
-
return (0, _utils.getSupportUploadTypes)(forbiddenTypes);
|
|
54
|
-
}, [forbiddenTypes]);
|
|
54
|
+
return (0, _utils.getSupportUploadTypes)(forbiddenTypes, supportTypes);
|
|
55
|
+
}, [forbiddenTypes, supportTypes]);
|
|
55
56
|
return /*#__PURE__*/_react.default.createElement(_luckDesign.BasicFormItem, (0, _extends2.default)({
|
|
56
57
|
extra: "".concat((0, _utils.formatMessage)({
|
|
57
58
|
id: 'app.upload.supportUpload',
|
package/lib/utils/form.js
CHANGED
|
@@ -7,6 +7,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
});
|
|
8
8
|
exports.getFormColumn = exports.formItemDataFormat = exports.dataFormat = void 0;
|
|
9
9
|
exports.getFormItem = getFormItem;
|
|
10
|
+
exports.mergeAndSort = void 0;
|
|
11
|
+
var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
|
|
10
12
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
11
13
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
|
|
12
14
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
@@ -30,6 +32,7 @@ var _excluded = ["comName", "property"],
|
|
|
30
32
|
* 根据动态表单配置项生成formItem
|
|
31
33
|
* @param {动态表单配置项} props
|
|
32
34
|
* @param {自定义动态表单配置项} customProps
|
|
35
|
+
* @param {formUi配置项} formUiPreset
|
|
33
36
|
* @returns <BasicForm name='' ... />
|
|
34
37
|
*/
|
|
35
38
|
function getFormItem() {
|
|
@@ -38,9 +41,10 @@ function getFormItem() {
|
|
|
38
41
|
property = _ref.property,
|
|
39
42
|
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
40
43
|
var customProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
44
|
+
var formUiPreset = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
41
45
|
if (!property) return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null);
|
|
42
46
|
if (property === 'sint' || property === 'number') props.opt_decimal = 0;
|
|
43
|
-
var _translator = (0, _form.translator)(props),
|
|
47
|
+
var _translator = (0, _form.translator)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, props), formUiPreset)),
|
|
44
48
|
name = _translator.name,
|
|
45
49
|
translateProps = (0, _objectWithoutProperties2.default)(_translator, _excluded2);
|
|
46
50
|
var _merge = (0, _lodash.merge)(
|
|
@@ -48,6 +52,7 @@ function getFormItem() {
|
|
|
48
52
|
translateProps, (0, _form.formatCustomProps)(customProps)),
|
|
49
53
|
type = _merge.type,
|
|
50
54
|
_props = (0, _objectWithoutProperties2.default)(_merge, _excluded3);
|
|
55
|
+
console.log('getFormItem', translateProps, _props);
|
|
51
56
|
if (customProps.renderBasicFormItem) {
|
|
52
57
|
var com = customProps.renderBasicFormItem(_props);
|
|
53
58
|
var comProps = (0, _lodash.merge)(_props, com.props);
|
|
@@ -197,8 +202,12 @@ var dataFormat = exports.dataFormat = function dataFormat() {
|
|
|
197
202
|
/**
|
|
198
203
|
*
|
|
199
204
|
* @param formType
|
|
205
|
+
* @param comName
|
|
206
|
+
* @param property
|
|
200
207
|
* @param props
|
|
208
|
+
* @param formItemRewrite
|
|
201
209
|
* @param customProps
|
|
210
|
+
* @param gridUiPreset
|
|
202
211
|
* @returns {*&{field: *, editable: (false|{required: *}), renderBasicFormItem: ((function(): (*))|*), title, render: *}}
|
|
203
212
|
*/
|
|
204
213
|
var getFormColumn = exports.getFormColumn = function getFormColumn() {
|
|
@@ -211,9 +220,10 @@ var getFormColumn = exports.getFormColumn = function getFormColumn() {
|
|
|
211
220
|
var _ref5 = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},
|
|
212
221
|
formItemRewrite = _ref5.formItemRewrite,
|
|
213
222
|
customProps = (0, _objectWithoutProperties2.default)(_ref5, _excluded7);
|
|
223
|
+
var gridUiPreset = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
|
|
214
224
|
var formItemType = comName || _form.defaultComName[property];
|
|
215
225
|
if (formItemType === 'radio') formItemType = 'select';
|
|
216
|
-
var _translator2 = (0, _form.translator)(props),
|
|
226
|
+
var _translator2 = (0, _form.translator)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, props), gridUiPreset)),
|
|
217
227
|
name = _translator2.name,
|
|
218
228
|
translateProps = (0, _objectWithoutProperties2.default)(_translator2, _excluded8);
|
|
219
229
|
var _merge2 = (0, _lodash.merge)(
|
|
@@ -224,7 +234,7 @@ var getFormColumn = exports.getFormColumn = function getFormColumn() {
|
|
|
224
234
|
_props = (0, _objectWithoutProperties2.default)(_merge2, _excluded9);
|
|
225
235
|
var columnRender = (0, _grid.getColumnRender)(name, formItemType, _props);
|
|
226
236
|
if (formType !== 'writer') _props.name = name;
|
|
227
|
-
return (0, _objectSpread2.default)((0, _objectSpread2.default)({
|
|
237
|
+
return (0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, _props), {}, {
|
|
228
238
|
title: translateProps.label,
|
|
229
239
|
editable: formType === 'writer' && {
|
|
230
240
|
required: _props.required || ((_props$config = _props.config) === null || _props$config === void 0 ? void 0 : _props$config.required)
|
|
@@ -253,4 +263,29 @@ var getFormColumn = exports.getFormColumn = function getFormColumn() {
|
|
|
253
263
|
},
|
|
254
264
|
field: name
|
|
255
265
|
});
|
|
266
|
+
};
|
|
267
|
+
|
|
268
|
+
/**
|
|
269
|
+
* 合并两个数组,并且数据顺序以arr2为准
|
|
270
|
+
* @param arr1
|
|
271
|
+
* @param arr2
|
|
272
|
+
* @param rowKey
|
|
273
|
+
*/
|
|
274
|
+
var mergeAndSort = exports.mergeAndSort = function mergeAndSort(arr1, arr2, rowKey) {
|
|
275
|
+
// 将a2转换为一个Map,便于快速查找
|
|
276
|
+
var a2Map = new Map(arr2.map(function (item) {
|
|
277
|
+
return [item[rowKey], item];
|
|
278
|
+
}));
|
|
279
|
+
// 创建一个新的数组,按a2的顺序填充元素,同时包含a1中不在a2中的元素
|
|
280
|
+
var mergedArray = arr2.map(function (item) {
|
|
281
|
+
var a1Item = arr1.find(function (a1) {
|
|
282
|
+
return a1[rowKey] === item[rowKey];
|
|
283
|
+
});
|
|
284
|
+
return a1Item ? (0, _objectSpread2.default)((0, _objectSpread2.default)({}, item), a1Item) : item;
|
|
285
|
+
});
|
|
286
|
+
// 将a1中未出现在a2中的元素追加到合并后的数组末尾
|
|
287
|
+
mergedArray.push.apply(mergedArray, (0, _toConsumableArray2.default)(arr1.filter(function (a1Item) {
|
|
288
|
+
return !a2Map.has(a1Item[rowKey]);
|
|
289
|
+
})));
|
|
290
|
+
return mergedArray;
|
|
256
291
|
};
|