@luck-design-biz/luckda 0.0.25-1 → 0.0.25-11
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/ComplexItem/index.js +92 -0
- package/es/{lowcode/painter/services/toolbar.js → components/ComplexItem/service.js} +7 -11
- package/es/components/LDActions/index.js +8 -10
- package/es/components/LDActions/index.less +7 -4
- package/es/components/LdAutoForm/index.js +34 -11
- package/es/components/LdFormList/index.js +39 -23
- package/es/components/LdGrid/index.js +21 -7
- package/es/components/LdGridForm/index.js +32 -11
- package/es/components/LdTree/index.js +33 -15
- package/es/helper/FromItems.js +177 -94
- package/es/helper/form.js +55 -14
- package/es/helper/props_config.js +17 -0
- package/es/locales/zh-CN.js +26 -11
- package/es/lowcode/constants/api-url.js +354 -104
- package/es/lowcode/constants/event-topics.js +2 -0
- package/es/lowcode/constants/index.js +4 -2
- package/es/lowcode/engine/factory/panel-item-factory/SelectStrategy.js +5 -2
- package/es/lowcode/engine/factory/panel-item-factory/StringStrategy.js +1 -1
- package/es/lowcode/engine/factory/panel-item-factory/SwitchStrategy.js +5 -2
- package/es/lowcode/engine/meta/box.props.default.json +1 -1
- package/es/lowcode/engine/meta/box.props.json +4 -4
- package/es/lowcode/engine/meta/button.props.json +4 -4
- package/es/lowcode/engine/meta/cardlist.props.json +14 -4
- package/es/lowcode/engine/meta/components-list.json +109 -1
- package/es/lowcode/engine/meta/dialog.props.default.json +11 -5
- package/es/lowcode/engine/meta/dialog.props.json +80 -43
- package/es/lowcode/engine/meta/drawer.props.json +9 -21
- package/es/lowcode/engine/meta/fieldcolor.props.default.json +14 -0
- package/es/lowcode/engine/meta/fieldcolor.props.json +63 -0
- package/es/lowcode/engine/meta/fieldcomplex.props.default.json +13 -0
- package/es/lowcode/engine/meta/fieldcomplex.props.json +39 -0
- package/es/lowcode/engine/meta/fielddate.props.default.json +12 -0
- package/es/lowcode/engine/meta/fielddate.props.json +47 -0
- package/es/lowcode/engine/meta/fielddict.props.default.json +14 -0
- package/es/lowcode/engine/meta/fielddict.props.json +44 -0
- package/es/lowcode/engine/meta/fieldeditor.props.default.json +13 -0
- package/es/lowcode/engine/meta/fieldeditor.props.json +44 -0
- package/es/lowcode/engine/meta/fieldgroup.props.default.json +15 -0
- package/es/lowcode/engine/meta/fieldgroup.props.json +73 -0
- package/es/lowcode/engine/meta/fieldnumber.props.default.json +14 -0
- package/es/lowcode/engine/meta/fieldnumber.props.json +48 -0
- package/es/lowcode/engine/meta/fieldradio.props.default.json +12 -0
- package/es/lowcode/engine/meta/fieldradio.props.json +20 -0
- package/es/lowcode/engine/meta/fieldregion.props.default.json +12 -0
- package/es/lowcode/engine/meta/fieldregion.props.json +26 -0
- package/es/lowcode/engine/meta/fieldselect.props.default.json +14 -0
- package/es/lowcode/engine/meta/fieldselect.props.json +58 -0
- package/es/lowcode/engine/meta/fieldstring.props.default.json +16 -0
- package/es/lowcode/engine/meta/fieldstring.props.json +62 -0
- package/es/lowcode/engine/meta/fieldswitch.props.default.json +12 -0
- package/es/lowcode/engine/meta/fieldswitch.props.json +31 -0
- package/es/lowcode/engine/meta/fieldtextarea.props.default.json +13 -0
- package/es/lowcode/engine/meta/fieldtextarea.props.json +49 -0
- package/es/lowcode/engine/meta/fieldupload.props.default.json +15 -0
- package/es/lowcode/engine/meta/fieldupload.props.json +71 -0
- package/es/lowcode/engine/meta/fielduser.props.default.json +16 -0
- package/es/lowcode/engine/meta/fielduser.props.json +82 -0
- package/es/lowcode/engine/meta/fieldyear.props.default.json +12 -0
- package/es/lowcode/engine/meta/fieldyear.props.json +37 -0
- package/es/lowcode/engine/meta/form.props.default.json +4 -5
- package/es/lowcode/engine/meta/form.props.json +44 -35
- package/es/lowcode/engine/meta/image.props.json +2 -2
- package/es/lowcode/engine/meta/imex.props.default.json +8 -1
- package/es/lowcode/engine/meta/imex.props.json +54 -22
- package/es/lowcode/engine/meta/js-editor/auto-complete.json +53 -3
- package/es/lowcode/engine/meta/layout.props.json +2 -2
- package/es/lowcode/engine/meta/link.props.json +1 -1
- package/es/lowcode/engine/meta/page.props.json +2 -2
- package/es/lowcode/engine/meta/pagelayout.props.default.json +14 -0
- package/es/lowcode/engine/meta/pagelayout.props.json +47 -0
- package/es/lowcode/engine/meta/section.props.default.json +4 -6
- package/es/lowcode/engine/meta/section.props.json +52 -49
- package/es/lowcode/engine/meta/split.props.default.json +1 -1
- package/es/lowcode/engine/meta/split.props.json +4 -4
- package/es/lowcode/engine/meta/table.props.json +19 -13
- package/es/lowcode/engine/meta/tabs.props.json +3 -3
- package/es/lowcode/engine/meta/text.props.json +2 -2
- package/es/lowcode/engine/meta/tree.props.default.json +2 -0
- package/es/lowcode/engine/meta/tree.props.json +71 -8
- package/es/lowcode/engine/provider/ContextProvider/index.js +21 -35
- package/es/lowcode/engine/provider/RemoteSourceProvider.js +89 -37
- package/es/lowcode/engine/tools/dataProcess.js +4 -0
- package/es/lowcode/engine/tools/diff.js +60 -0
- package/es/lowcode/engine/tools/helper.js +47 -26
- package/es/lowcode/engine/tools/useCanvasRender.js +8 -9
- package/es/lowcode/engine/tools/usePageDataStore.js +331 -0
- package/es/lowcode/engine/tools/usePromiseState.js +8 -10
- package/es/lowcode/engine/tools/useTodo.js +20 -10
- package/es/lowcode/painter/Design.js +41 -6
- package/es/lowcode/painter/DesignOperator.js +112 -88
- package/es/lowcode/painter/DesignToolbar.js +280 -36
- package/es/lowcode/painter/Outline.js +12 -10
- package/es/lowcode/painter/Panel.js +84 -46
- package/es/lowcode/painter/components/ActionBindModal.js +38 -27
- package/es/lowcode/painter/components/AdvancePanel.js +37 -21
- package/es/lowcode/painter/components/AttrsPanel.js +45 -34
- package/es/lowcode/painter/components/DragDrop/DragDropContext.js +1 -1
- package/es/lowcode/painter/components/DragDrop/DragDropWrapper.js +5 -2
- package/es/lowcode/painter/components/FieldSelector.js +26 -13
- package/es/lowcode/painter/components/ListEditor.js +8 -2
- package/es/lowcode/painter/components/code-editor/BaseEditor.js +3 -2
- package/es/lowcode/painter/components/code-editor/JSEditor.js +5 -9
- package/es/lowcode/painter/components/field-setting/BatchSetting.js +13 -3
- package/es/lowcode/painter/components/field-setting/CheckFrontRules.js +108 -0
- package/es/lowcode/painter/components/field-setting/CheckRules.js +1 -26
- package/es/lowcode/painter/components/field-setting/FieldRulesModal.js +33 -13
- package/es/lowcode/painter/components/field-setting/SettingUI.js +182 -31
- package/es/lowcode/painter/components/field-setting/index.js +40 -61
- package/es/lowcode/painter/components/field-setting/meta/frontRules.js +53 -0
- package/es/lowcode/painter/index.js +1 -28
- package/es/lowcode/painter/panel-section/ActionsColumnWidth.js +25 -0
- package/es/lowcode/painter/panel-section/BlockEditor/index.js +7 -4
- package/es/lowcode/painter/panel-section/BlocksEditor/BlockEditorItem.js +4 -3
- package/es/lowcode/painter/panel-section/BlocksEditor/index.js +55 -28
- package/es/lowcode/painter/panel-section/ButtonType.js +4 -2
- package/es/lowcode/painter/panel-section/DataSetSelector.js +30 -7
- package/es/lowcode/painter/panel-section/FieldsSetting.js +124 -55
- package/es/lowcode/painter/panel-section/I18nInput.js +20 -0
- package/es/lowcode/painter/panel-section/ImpExp.js +99 -14
- package/es/lowcode/painter/panel-section/ImpExpAlone.js +108 -0
- package/es/lowcode/painter/panel-section/PageLayoutDisplay.js +95 -0
- package/es/lowcode/painter/panel-section/SerialsSelector.js +4 -2
- package/es/lowcode/painter/panel-section/SplitDisplay.js +25 -110
- package/es/lowcode/painter/panel-section/StylePanel/StyleContext.js +1 -1
- package/es/lowcode/painter/panel-section/StylePanel/index.js +10 -4
- package/es/lowcode/painter/panel-section/TableTopFilter.js +23 -13
- package/es/lowcode/painter/panel-section/TreeRootEditor.js +2 -2
- package/es/lowcode/painter/style/action-bind-modal.less +3 -3
- package/es/lowcode/painter/style/design.less +11 -4
- package/es/lowcode/painter/style/list-editor.less +36 -0
- package/es/lowcode/painter/style/page-layout-display.less +28 -0
- package/es/lowcode/painter/style/panel-item.less +1 -1
- package/es/lowcode/painter/style/split-display.less +0 -9
- package/es/lowcode/preview/index.js +20 -5
- package/es/lowcode/view/Canvas.js +6 -7
- package/es/lowcode/view/Page.js +5 -6
- package/es/lowcode/view/lc-components/Box/FunctionDesign.js +3 -2
- package/es/lowcode/view/lc-components/Box/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Box/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Box/meta.json +4 -4
- package/es/lowcode/view/lc-components/Button/index.js +2 -6
- package/es/lowcode/view/lc-components/Button/meta.json +4 -4
- package/es/lowcode/view/lc-components/CardList/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/CardList/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/CardList/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/CardList/meta.json +14 -4
- package/es/lowcode/view/lc-components/Dialog/FunctionDesign.js +3 -12
- package/es/lowcode/view/lc-components/Dialog/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Dialog/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Dialog/index.js +119 -19
- package/es/lowcode/view/lc-components/Dialog/meta.json +73 -43
- package/es/lowcode/view/lc-components/Drawer/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/Drawer/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Drawer/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Drawer/meta.json +9 -21
- package/es/lowcode/view/lc-components/FieldColor/meta.json +63 -0
- package/es/lowcode/view/lc-components/FieldComplex/meta.json +39 -0
- package/es/lowcode/view/lc-components/FieldDate/meta.json +45 -0
- package/es/lowcode/view/lc-components/FieldDict/meta.json +44 -0
- package/es/lowcode/view/lc-components/FieldEditor/meta.json +44 -0
- package/es/lowcode/view/lc-components/FieldGroup/meta.json +73 -0
- package/es/lowcode/view/lc-components/FieldNumber/meta.json +48 -0
- package/es/lowcode/view/lc-components/FieldRadio/meta.json +20 -0
- package/es/lowcode/view/lc-components/FieldRegion/meta.json +26 -0
- package/es/lowcode/view/lc-components/FieldSelect/meta.json +58 -0
- package/es/lowcode/view/lc-components/FieldString/meta.json +62 -0
- package/es/lowcode/view/lc-components/FieldSwitch/meta.json +31 -0
- package/es/lowcode/view/lc-components/FieldTextarea/meta.json +49 -0
- package/es/lowcode/view/lc-components/FieldUpload/meta.json +71 -0
- package/es/lowcode/view/lc-components/FieldUser/meta.json +82 -0
- package/es/lowcode/view/lc-components/FieldYear/meta.json +35 -0
- package/es/lowcode/view/lc-components/Form/FunctionDesign.js +61 -9
- package/es/lowcode/view/lc-components/Form/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Form/FunctionPreview.js +9 -1
- package/es/lowcode/view/lc-components/Form/index.js +401 -66
- package/es/lowcode/view/lc-components/Form/meta.json +44 -35
- package/es/lowcode/view/lc-components/Iframe/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/Iframe/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Iframe/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/ImEx/FunctionDesign.js +9 -3
- package/es/lowcode/view/lc-components/ImEx/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/ImEx/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/ImEx/index.js +470 -11
- package/es/lowcode/view/lc-components/ImEx/index.less +7 -0
- package/es/lowcode/view/lc-components/ImEx/meta.json +55 -23
- package/es/lowcode/view/lc-components/Image/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/Image/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Image/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Image/meta.json +2 -2
- package/es/lowcode/view/lc-components/JSX/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/JSX/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/JSX/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Layout/FunctionDesign.js +13 -21
- package/es/lowcode/view/lc-components/Layout/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Layout/meta.json +2 -2
- package/es/lowcode/view/lc-components/Link/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/Link/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Link/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Link/meta.json +1 -1
- package/es/lowcode/view/lc-components/Page/meta.json +2 -2
- package/es/lowcode/view/lc-components/PageContent/index.js +8 -9
- package/es/lowcode/view/lc-components/PageFooter/index.js +2 -5
- package/es/lowcode/view/lc-components/PageHeader/index.js +5 -6
- package/es/lowcode/view/lc-components/PageLayout/FunctionDesign.js +63 -0
- package/es/lowcode/view/lc-components/PageLayout/FunctionLive.js +10 -0
- package/es/lowcode/view/lc-components/PageLayout/FunctionPreview.js +10 -0
- package/es/lowcode/view/lc-components/PageLayout/index.js +32 -0
- package/es/lowcode/view/lc-components/PageLayout/meta.json +47 -0
- package/es/lowcode/view/lc-components/PageModal/index.js +12 -15
- package/es/lowcode/view/lc-components/Section/FunctionDesign.js +25 -2
- package/es/lowcode/view/lc-components/Section/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Section/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Section/index.js +114 -24
- package/es/lowcode/view/lc-components/Section/index.less +7 -0
- package/es/lowcode/view/lc-components/Section/meta.json +48 -49
- package/es/lowcode/view/lc-components/Split/FunctionDesign.js +19 -22
- package/es/lowcode/view/lc-components/Split/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Split/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Split/index.js +7 -11
- package/es/lowcode/view/lc-components/Split/meta.json +4 -4
- package/es/lowcode/view/lc-components/Table/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Table/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Table/components/TopFilter.js +78 -57
- package/es/lowcode/view/lc-components/Table/components/TopImex.js +420 -0
- package/es/lowcode/view/lc-components/Table/index.js +294 -47
- package/es/lowcode/view/lc-components/Table/meta.json +19 -13
- package/es/lowcode/view/lc-components/Tabs/FunctionDesign.js +11 -20
- package/es/lowcode/view/lc-components/Tabs/index.js +27 -12
- package/es/lowcode/view/lc-components/Tabs/meta.json +3 -3
- package/es/lowcode/view/lc-components/Text/FunctionDesign.js +1 -0
- package/es/lowcode/view/lc-components/Text/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Text/FunctionPreview.js +1 -0
- package/es/lowcode/view/lc-components/Text/meta.json +2 -2
- package/es/lowcode/view/lc-components/Tree/FunctionDesign.js +2 -3
- package/es/lowcode/view/lc-components/Tree/FunctionLive.js +1 -0
- package/es/lowcode/view/lc-components/Tree/index.js +103 -29
- package/es/lowcode/view/lc-components/Tree/meta.json +71 -9
- package/es/lowcode/view/lc-components/Wrapper.js +10 -12
- package/es/services.js +0 -24
- package/es/upload/FilesWall/file.png +0 -0
- package/es/upload/FilesWall/index.js +422 -0
- package/es/upload/FilesWall/index.less +74 -0
- package/es/upload/Form/gridForm.js +10 -5
- package/es/upload/Form/index.js +2 -1
- package/es/upload/FormItem/index.js +8 -9
- package/es/upload/index.js +2 -1
- package/es/utils/action.js +2 -2
- package/es/utils/form.js +16 -3
- package/es/utils/grid.js +8 -5
- package/lib/components/ComplexItem/index.js +100 -0
- package/lib/{lowcode/painter/services/toolbar.js → components/ComplexItem/service.js} +8 -12
- package/lib/components/LDActions/index.js +7 -9
- package/lib/components/LDActions/index.less +7 -4
- package/lib/components/LdAutoForm/index.js +33 -10
- package/lib/components/LdFormList/index.js +38 -22
- package/lib/components/LdGrid/index.js +21 -7
- package/lib/components/LdGridForm/index.js +30 -9
- package/lib/components/LdTree/index.js +33 -15
- package/lib/helper/FromItems.js +175 -92
- package/lib/helper/form.js +53 -13
- package/lib/helper/props_config.js +23 -0
- package/lib/locales/zh-CN.js +26 -11
- package/lib/lowcode/constants/api-url.js +355 -104
- package/lib/lowcode/constants/event-topics.js +3 -1
- package/lib/lowcode/constants/index.js +5 -3
- package/lib/lowcode/engine/factory/panel-item-factory/SelectStrategy.js +7 -4
- package/lib/lowcode/engine/factory/panel-item-factory/StringStrategy.js +3 -2
- package/lib/lowcode/engine/factory/panel-item-factory/SwitchStrategy.js +6 -3
- package/lib/lowcode/engine/meta/box.props.default.json +1 -1
- package/lib/lowcode/engine/meta/box.props.json +4 -4
- package/lib/lowcode/engine/meta/button.props.json +4 -4
- package/lib/lowcode/engine/meta/cardlist.props.json +14 -4
- package/lib/lowcode/engine/meta/components-list.json +109 -1
- package/lib/lowcode/engine/meta/dialog.props.default.json +11 -5
- package/lib/lowcode/engine/meta/dialog.props.json +80 -43
- package/lib/lowcode/engine/meta/drawer.props.json +9 -21
- package/lib/lowcode/engine/meta/fieldcolor.props.default.json +14 -0
- package/lib/lowcode/engine/meta/fieldcolor.props.json +63 -0
- package/lib/lowcode/engine/meta/fieldcomplex.props.default.json +13 -0
- package/lib/lowcode/engine/meta/fieldcomplex.props.json +39 -0
- package/lib/lowcode/engine/meta/fielddate.props.default.json +12 -0
- package/lib/lowcode/engine/meta/fielddate.props.json +47 -0
- package/lib/lowcode/engine/meta/fielddict.props.default.json +14 -0
- package/lib/lowcode/engine/meta/fielddict.props.json +44 -0
- package/lib/lowcode/engine/meta/fieldeditor.props.default.json +13 -0
- package/lib/lowcode/engine/meta/fieldeditor.props.json +44 -0
- package/lib/lowcode/engine/meta/fieldgroup.props.default.json +15 -0
- package/lib/lowcode/engine/meta/fieldgroup.props.json +73 -0
- package/lib/lowcode/engine/meta/fieldnumber.props.default.json +14 -0
- package/lib/lowcode/engine/meta/fieldnumber.props.json +48 -0
- package/lib/lowcode/engine/meta/fieldradio.props.default.json +12 -0
- package/lib/lowcode/engine/meta/fieldradio.props.json +20 -0
- package/lib/lowcode/engine/meta/fieldregion.props.default.json +12 -0
- package/lib/lowcode/engine/meta/fieldregion.props.json +26 -0
- package/lib/lowcode/engine/meta/fieldselect.props.default.json +14 -0
- package/lib/lowcode/engine/meta/fieldselect.props.json +58 -0
- package/lib/lowcode/engine/meta/fieldstring.props.default.json +16 -0
- package/lib/lowcode/engine/meta/fieldstring.props.json +62 -0
- package/lib/lowcode/engine/meta/fieldswitch.props.default.json +12 -0
- package/lib/lowcode/engine/meta/fieldswitch.props.json +31 -0
- package/lib/lowcode/engine/meta/fieldtextarea.props.default.json +13 -0
- package/lib/lowcode/engine/meta/fieldtextarea.props.json +49 -0
- package/lib/lowcode/engine/meta/fieldupload.props.default.json +15 -0
- package/lib/lowcode/engine/meta/fieldupload.props.json +71 -0
- package/lib/lowcode/engine/meta/fielduser.props.default.json +16 -0
- package/lib/lowcode/engine/meta/fielduser.props.json +82 -0
- package/lib/lowcode/engine/meta/fieldyear.props.default.json +12 -0
- package/lib/lowcode/engine/meta/fieldyear.props.json +37 -0
- package/lib/lowcode/engine/meta/form.props.default.json +4 -5
- package/lib/lowcode/engine/meta/form.props.json +44 -35
- package/lib/lowcode/engine/meta/image.props.json +2 -2
- package/lib/lowcode/engine/meta/imex.props.default.json +8 -1
- package/lib/lowcode/engine/meta/imex.props.json +54 -22
- package/lib/lowcode/engine/meta/js-editor/auto-complete.json +53 -3
- package/lib/lowcode/engine/meta/layout.props.json +2 -2
- package/lib/lowcode/engine/meta/link.props.json +1 -1
- package/lib/lowcode/engine/meta/page.props.json +2 -2
- package/lib/lowcode/engine/meta/pagelayout.props.default.json +14 -0
- package/lib/lowcode/engine/meta/pagelayout.props.json +47 -0
- package/lib/lowcode/engine/meta/section.props.default.json +4 -6
- package/lib/lowcode/engine/meta/section.props.json +52 -49
- package/lib/lowcode/engine/meta/split.props.default.json +1 -1
- package/lib/lowcode/engine/meta/split.props.json +4 -4
- package/lib/lowcode/engine/meta/table.props.json +19 -13
- package/lib/lowcode/engine/meta/tabs.props.json +3 -3
- package/lib/lowcode/engine/meta/text.props.json +2 -2
- package/lib/lowcode/engine/meta/tree.props.default.json +2 -0
- package/lib/lowcode/engine/meta/tree.props.json +71 -8
- package/lib/lowcode/engine/provider/ContextProvider/index.js +37 -35
- package/lib/lowcode/engine/provider/RemoteSourceProvider.js +86 -34
- package/lib/lowcode/engine/tools/dataProcess.js +4 -0
- package/lib/lowcode/engine/tools/diff.js +67 -0
- package/lib/lowcode/engine/tools/helper.js +48 -25
- package/lib/lowcode/engine/tools/useCanvasRender.js +6 -7
- package/lib/lowcode/engine/tools/usePageDataStore.js +338 -0
- package/lib/lowcode/engine/tools/usePromiseState.js +6 -8
- package/lib/lowcode/engine/tools/useTodo.js +19 -9
- package/lib/lowcode/painter/Design.js +39 -4
- package/lib/lowcode/painter/DesignOperator.js +109 -85
- package/lib/lowcode/painter/DesignToolbar.js +277 -33
- package/lib/lowcode/painter/Outline.js +10 -8
- package/lib/lowcode/painter/Panel.js +82 -44
- package/lib/lowcode/painter/components/ActionBindModal.js +36 -25
- package/lib/lowcode/painter/components/AdvancePanel.js +36 -20
- package/lib/lowcode/painter/components/AttrsPanel.js +44 -33
- package/lib/lowcode/painter/components/DragDrop/DragDropContext.js +1 -1
- package/lib/lowcode/painter/components/DragDrop/DragDropWrapper.js +5 -2
- package/lib/lowcode/painter/components/FieldSelector.js +26 -13
- package/lib/lowcode/painter/components/ListEditor.js +8 -2
- package/lib/lowcode/painter/components/code-editor/BaseEditor.js +3 -2
- package/lib/lowcode/painter/components/code-editor/JSEditor.js +5 -9
- package/lib/lowcode/painter/components/field-setting/BatchSetting.js +13 -3
- package/lib/lowcode/painter/components/field-setting/CheckFrontRules.js +116 -0
- package/lib/lowcode/painter/components/field-setting/CheckRules.js +1 -26
- package/lib/lowcode/painter/components/field-setting/FieldRulesModal.js +34 -13
- package/lib/lowcode/painter/components/field-setting/SettingUI.js +179 -28
- package/lib/lowcode/painter/components/field-setting/index.js +40 -61
- package/lib/lowcode/painter/components/field-setting/meta/frontRules.js +59 -0
- package/lib/lowcode/painter/index.js +1 -30
- package/lib/lowcode/painter/panel-section/ActionsColumnWidth.js +32 -0
- package/lib/lowcode/painter/panel-section/BlockEditor/index.js +7 -4
- package/lib/lowcode/painter/panel-section/BlocksEditor/BlockEditorItem.js +4 -3
- package/lib/lowcode/painter/panel-section/BlocksEditor/index.js +53 -25
- package/lib/lowcode/painter/panel-section/ButtonType.js +4 -2
- package/lib/lowcode/painter/panel-section/DataSetSelector.js +30 -7
- package/lib/lowcode/painter/panel-section/FieldsSetting.js +121 -52
- package/lib/lowcode/painter/panel-section/I18nInput.js +27 -0
- package/lib/lowcode/painter/panel-section/ImpExp.js +99 -13
- package/lib/lowcode/painter/panel-section/ImpExpAlone.js +114 -0
- package/lib/lowcode/painter/panel-section/PageLayoutDisplay.js +103 -0
- package/lib/lowcode/painter/panel-section/SerialsSelector.js +4 -2
- package/lib/lowcode/painter/panel-section/SplitDisplay.js +24 -109
- package/lib/lowcode/painter/panel-section/StylePanel/StyleContext.js +5 -4
- package/lib/lowcode/painter/panel-section/StylePanel/index.js +10 -4
- package/lib/lowcode/painter/panel-section/TableTopFilter.js +22 -12
- package/lib/lowcode/painter/panel-section/TreeRootEditor.js +2 -2
- package/lib/lowcode/painter/style/action-bind-modal.less +3 -3
- package/lib/lowcode/painter/style/design.less +11 -4
- package/lib/lowcode/painter/style/list-editor.less +36 -0
- package/lib/lowcode/painter/style/page-layout-display.less +28 -0
- package/lib/lowcode/painter/style/panel-item.less +1 -1
- package/lib/lowcode/painter/style/split-display.less +0 -9
- package/lib/lowcode/preview/index.js +21 -5
- package/lib/lowcode/view/Canvas.js +5 -6
- package/lib/lowcode/view/Page.js +5 -6
- package/lib/lowcode/view/lc-components/Box/FunctionDesign.js +3 -2
- package/lib/lowcode/view/lc-components/Box/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Box/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Box/meta.json +4 -4
- package/lib/lowcode/view/lc-components/Button/index.js +2 -6
- package/lib/lowcode/view/lc-components/Button/meta.json +4 -4
- package/lib/lowcode/view/lc-components/CardList/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/CardList/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/CardList/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/CardList/meta.json +14 -4
- package/lib/lowcode/view/lc-components/Dialog/FunctionDesign.js +2 -11
- package/lib/lowcode/view/lc-components/Dialog/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Dialog/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Dialog/index.js +119 -19
- package/lib/lowcode/view/lc-components/Dialog/meta.json +73 -43
- package/lib/lowcode/view/lc-components/Drawer/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/Drawer/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Drawer/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Drawer/meta.json +9 -21
- package/lib/lowcode/view/lc-components/FieldColor/meta.json +63 -0
- package/lib/lowcode/view/lc-components/FieldComplex/meta.json +39 -0
- package/lib/lowcode/view/lc-components/FieldDate/meta.json +45 -0
- package/lib/lowcode/view/lc-components/FieldDict/meta.json +44 -0
- package/lib/lowcode/view/lc-components/FieldEditor/meta.json +44 -0
- package/lib/lowcode/view/lc-components/FieldGroup/meta.json +73 -0
- package/lib/lowcode/view/lc-components/FieldNumber/meta.json +48 -0
- package/lib/lowcode/view/lc-components/FieldRadio/meta.json +20 -0
- package/lib/lowcode/view/lc-components/FieldRegion/meta.json +26 -0
- package/lib/lowcode/view/lc-components/FieldSelect/meta.json +58 -0
- package/lib/lowcode/view/lc-components/FieldString/meta.json +62 -0
- package/lib/lowcode/view/lc-components/FieldSwitch/meta.json +31 -0
- package/lib/lowcode/view/lc-components/FieldTextarea/meta.json +49 -0
- package/lib/lowcode/view/lc-components/FieldUpload/meta.json +71 -0
- package/lib/lowcode/view/lc-components/FieldUser/meta.json +82 -0
- package/lib/lowcode/view/lc-components/FieldYear/meta.json +35 -0
- package/lib/lowcode/view/lc-components/Form/FunctionDesign.js +58 -7
- package/lib/lowcode/view/lc-components/Form/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Form/FunctionPreview.js +9 -1
- package/lib/lowcode/view/lc-components/Form/index.js +396 -61
- package/lib/lowcode/view/lc-components/Form/meta.json +44 -35
- package/lib/lowcode/view/lc-components/Iframe/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/Iframe/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Iframe/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/ImEx/FunctionDesign.js +9 -3
- package/lib/lowcode/view/lc-components/ImEx/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/ImEx/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/ImEx/index.js +468 -9
- package/lib/lowcode/view/lc-components/ImEx/index.less +7 -0
- package/lib/lowcode/view/lc-components/ImEx/meta.json +55 -23
- package/lib/lowcode/view/lc-components/Image/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/Image/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Image/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Image/meta.json +2 -2
- package/lib/lowcode/view/lc-components/JSX/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/JSX/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/JSX/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Layout/FunctionDesign.js +11 -19
- package/lib/lowcode/view/lc-components/Layout/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Layout/meta.json +2 -2
- package/lib/lowcode/view/lc-components/Link/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/Link/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Link/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Link/meta.json +1 -1
- package/lib/lowcode/view/lc-components/Page/meta.json +2 -2
- package/lib/lowcode/view/lc-components/PageContent/index.js +7 -8
- package/lib/lowcode/view/lc-components/PageFooter/index.js +2 -5
- package/lib/lowcode/view/lc-components/PageHeader/index.js +4 -5
- package/lib/lowcode/view/lc-components/PageLayout/FunctionDesign.js +71 -0
- package/lib/lowcode/view/lc-components/PageLayout/FunctionLive.js +17 -0
- package/lib/lowcode/view/lc-components/PageLayout/FunctionPreview.js +17 -0
- package/lib/lowcode/view/lc-components/PageLayout/index.js +40 -0
- package/lib/lowcode/view/lc-components/PageLayout/meta.json +47 -0
- package/lib/lowcode/view/lc-components/PageModal/index.js +11 -14
- package/lib/lowcode/view/lc-components/Section/FunctionDesign.js +25 -2
- package/lib/lowcode/view/lc-components/Section/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Section/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Section/index.js +113 -23
- package/lib/lowcode/view/lc-components/Section/index.less +7 -0
- package/lib/lowcode/view/lc-components/Section/meta.json +48 -49
- package/lib/lowcode/view/lc-components/Split/FunctionDesign.js +18 -21
- package/lib/lowcode/view/lc-components/Split/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Split/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Split/index.js +4 -8
- package/lib/lowcode/view/lc-components/Split/meta.json +4 -4
- package/lib/lowcode/view/lc-components/Table/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Table/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Table/components/TopFilter.js +75 -55
- package/lib/lowcode/view/lc-components/Table/components/TopImex.js +428 -0
- package/lib/lowcode/view/lc-components/Table/index.js +292 -45
- package/lib/lowcode/view/lc-components/Table/meta.json +19 -13
- package/lib/lowcode/view/lc-components/Tabs/FunctionDesign.js +9 -18
- package/lib/lowcode/view/lc-components/Tabs/index.js +26 -11
- package/lib/lowcode/view/lc-components/Tabs/meta.json +3 -3
- package/lib/lowcode/view/lc-components/Text/FunctionDesign.js +2 -1
- package/lib/lowcode/view/lc-components/Text/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Text/FunctionPreview.js +2 -1
- package/lib/lowcode/view/lc-components/Text/meta.json +2 -2
- package/lib/lowcode/view/lc-components/Tree/FunctionDesign.js +2 -3
- package/lib/lowcode/view/lc-components/Tree/FunctionLive.js +2 -1
- package/lib/lowcode/view/lc-components/Tree/index.js +100 -26
- package/lib/lowcode/view/lc-components/Tree/meta.json +71 -9
- package/lib/lowcode/view/lc-components/Wrapper.js +11 -12
- package/lib/services.js +0 -25
- package/lib/upload/FilesWall/file.png +0 -0
- package/lib/upload/FilesWall/index.js +429 -0
- package/lib/upload/FilesWall/index.less +74 -0
- package/lib/upload/Form/gridForm.js +10 -5
- package/lib/upload/Form/index.js +2 -1
- package/lib/upload/FormItem/index.js +8 -9
- package/lib/upload/index.js +8 -1
- package/lib/utils/action.js +2 -2
- package/lib/utils/form.js +16 -3
- package/lib/utils/grid.js +8 -5
- package/package.json +175 -171
- package/es/lowcode/engine/meta/local/local.zh-cn.js +0 -97
- package/lib/lowcode/engine/meta/local/local.zh-cn.js +0 -103
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
3
3
|
import React, { useReducer, useState } from 'react';
|
|
4
|
-
import { useSetState, useMemoizedFn } from 'ahooks';
|
|
4
|
+
import { useSetState, useMemoizedFn, useDebounceFn } from 'ahooks';
|
|
5
5
|
import { Tooltip, Radio, Input, Icon } from 'luck-design/antd';
|
|
6
6
|
import { isString, isArray, isNil } from 'lodash';
|
|
7
7
|
import { formatMessage, suid } from '@luck-design-biz/base/utils';
|
|
8
|
+
import { useContext } from "../../engine/provider/ContextProvider";
|
|
8
9
|
import { SortBox, SortItem } from "../components/SortBox";
|
|
9
10
|
import { ListEditor, ListEditorItem } from "../components/ListEditor";
|
|
10
11
|
import PopConfirm from "../components/PopConfirm";
|
|
@@ -19,7 +20,9 @@ var _RADIO_STYLE_ = {
|
|
|
19
20
|
};
|
|
20
21
|
var TableTopFilter = function TableTopFilter(_ref) {
|
|
21
22
|
var defaultValue = _ref.defaultValue,
|
|
22
|
-
_onChange = _ref.onChange
|
|
23
|
+
_onChange = _ref.onChange,
|
|
24
|
+
nodeId = _ref.nodeId;
|
|
25
|
+
var ctx = useContext();
|
|
23
26
|
var _useState = useState(function () {
|
|
24
27
|
if (isNil(defaultValue)) return 'nil';
|
|
25
28
|
if (isString(defaultValue)) return 'customApi';
|
|
@@ -41,6 +44,17 @@ var TableTopFilter = function TableTopFilter(_ref) {
|
|
|
41
44
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
42
45
|
apiUrl = _useState4[0],
|
|
43
46
|
setApiUrl = _useState4[1];
|
|
47
|
+
var _useDebounceFn = useDebounceFn(function (val) {
|
|
48
|
+
setDict({
|
|
49
|
+
key: val
|
|
50
|
+
});
|
|
51
|
+
if (dict !== null && dict !== void 0 && dict.field) _onChange(_objectSpread(_objectSpread({}, dict), {}, {
|
|
52
|
+
key: val
|
|
53
|
+
}));
|
|
54
|
+
}, {
|
|
55
|
+
wait: 400
|
|
56
|
+
}),
|
|
57
|
+
handleDictChange = _useDebounceFn.run;
|
|
44
58
|
var handleAdd = useMemoizedFn(function () {
|
|
45
59
|
var id = suid();
|
|
46
60
|
dispatch({
|
|
@@ -48,7 +62,7 @@ var TableTopFilter = function TableTopFilter(_ref) {
|
|
|
48
62
|
payload: {
|
|
49
63
|
id: id,
|
|
50
64
|
value: id,
|
|
51
|
-
field:
|
|
65
|
+
field: void 0,
|
|
52
66
|
label: "\u8FC7\u6EE4\u9879".concat(options.length + 1)
|
|
53
67
|
},
|
|
54
68
|
callback: function callback(newOptions) {
|
|
@@ -137,9 +151,10 @@ var TableTopFilter = function TableTopFilter(_ref) {
|
|
|
137
151
|
id: "".concat(_I18N_PREFIX_, ".field"),
|
|
138
152
|
label: '字段'
|
|
139
153
|
})), /*#__PURE__*/React.createElement(PopFormItemRight, null, /*#__PURE__*/React.createElement(FieldSelector, {
|
|
154
|
+
dsid: ctx.componentMap.get(nodeId).api.getSelfData().props.dataset.uid,
|
|
140
155
|
defaultValue: opt.field,
|
|
141
156
|
style: {
|
|
142
|
-
width: '
|
|
157
|
+
width: '100%'
|
|
143
158
|
},
|
|
144
159
|
placeholder: formatMessage({
|
|
145
160
|
id: "".concat(_I18N_PREFIX_, ".field.placeholder"),
|
|
@@ -203,7 +218,7 @@ var TableTopFilter = function TableTopFilter(_ref) {
|
|
|
203
218
|
}
|
|
204
219
|
}, /*#__PURE__*/React.createElement(Input, {
|
|
205
220
|
size: "small",
|
|
206
|
-
|
|
221
|
+
defaultValue: dict === null || dict === void 0 ? void 0 : dict.key,
|
|
207
222
|
style: {
|
|
208
223
|
width: '50%'
|
|
209
224
|
},
|
|
@@ -212,15 +227,10 @@ var TableTopFilter = function TableTopFilter(_ref) {
|
|
|
212
227
|
label: '请输入字典key'
|
|
213
228
|
}),
|
|
214
229
|
onChange: function onChange(e) {
|
|
215
|
-
|
|
216
|
-
setDict({
|
|
217
|
-
key: key
|
|
218
|
-
});
|
|
219
|
-
if (dict !== null && dict !== void 0 && dict.field) _onChange(_objectSpread(_objectSpread({}, dict), {}, {
|
|
220
|
-
key: key
|
|
221
|
-
}));
|
|
230
|
+
return handleDictChange(e.target.value);
|
|
222
231
|
}
|
|
223
232
|
}), /*#__PURE__*/React.createElement(FieldSelector, {
|
|
233
|
+
dsid: ctx.componentMap.get(nodeId).api.getSelfData().props.dataset.uid,
|
|
224
234
|
style: {
|
|
225
235
|
width: '50%'
|
|
226
236
|
},
|
|
@@ -278,7 +288,7 @@ var TableTopFilter = function TableTopFilter(_ref) {
|
|
|
278
288
|
size: "small",
|
|
279
289
|
value: apiUrl,
|
|
280
290
|
placeholder: formatMessage({
|
|
281
|
-
id: "".concat(_I18N_PREFIX_, ".
|
|
291
|
+
id: "".concat(_I18N_PREFIX_, ".customApi.placeholder"),
|
|
282
292
|
label: '请输入接口地址'
|
|
283
293
|
}),
|
|
284
294
|
style: {
|
|
@@ -55,8 +55,8 @@ var TreeRootEditor = function TreeRootEditor(_ref) {
|
|
|
55
55
|
}
|
|
56
56
|
}))), /*#__PURE__*/React.createElement(Tooltip, {
|
|
57
57
|
title: formatMessage({
|
|
58
|
-
id: 'luckda.lowcode.painter.
|
|
59
|
-
label: '
|
|
58
|
+
id: 'luckda.lowcode.painter.bind',
|
|
59
|
+
label: '绑定动作'
|
|
60
60
|
})
|
|
61
61
|
}, /*#__PURE__*/React.createElement(Icon, {
|
|
62
62
|
type: "paper-clip",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
.lc-painter-panel-action-bind-modal {
|
|
2
2
|
&-body {
|
|
3
3
|
width: 100%;
|
|
4
|
-
height:
|
|
4
|
+
height: 660px;
|
|
5
5
|
display: flex;
|
|
6
6
|
font-size: 12px;
|
|
7
7
|
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
.selector-box {
|
|
12
12
|
width: 100%;
|
|
13
|
-
height:
|
|
13
|
+
height: 620px;
|
|
14
14
|
border: 1px solid #e8e8e8;
|
|
15
15
|
border-radius: 6px;
|
|
16
16
|
display: flex;
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
|
|
69
69
|
.code-box {
|
|
70
70
|
width: 100%;
|
|
71
|
-
height:
|
|
71
|
+
height: 620px;
|
|
72
72
|
border: 1px solid #e8e8e8;
|
|
73
73
|
border-radius: 6px;
|
|
74
74
|
overflow: hidden;
|
|
@@ -63,6 +63,11 @@
|
|
|
63
63
|
color: #8c8c8c;
|
|
64
64
|
background: #f1f2f3;
|
|
65
65
|
}
|
|
66
|
+
|
|
67
|
+
.toolbar-item.disabled {
|
|
68
|
+
color: #d9d9d9;
|
|
69
|
+
cursor: not-allowed;
|
|
70
|
+
}
|
|
66
71
|
}
|
|
67
72
|
|
|
68
73
|
&-workspace {
|
|
@@ -77,9 +82,11 @@
|
|
|
77
82
|
|
|
78
83
|
&-simulator {
|
|
79
84
|
min-height: 100%;
|
|
80
|
-
height: auto;
|
|
81
85
|
:global {
|
|
82
|
-
.ant-form-item,
|
|
86
|
+
.ant-form-item,
|
|
87
|
+
.ant-collapse-header,
|
|
88
|
+
.resizer,
|
|
89
|
+
.ant-tree-node-content-wrapper {
|
|
83
90
|
pointer-events: none;
|
|
84
91
|
}
|
|
85
92
|
.luck-grid-table {
|
|
@@ -96,7 +103,7 @@
|
|
|
96
103
|
background-color: color-mix(in sRGB, var(--ant-primary-color), transparent 95%);
|
|
97
104
|
.box();
|
|
98
105
|
|
|
99
|
-
&-name{
|
|
106
|
+
&-name {
|
|
100
107
|
position: absolute;
|
|
101
108
|
color: var(--ant-primary-color);
|
|
102
109
|
font-size: 12px;
|
|
@@ -119,7 +126,7 @@
|
|
|
119
126
|
.selector-item();
|
|
120
127
|
}
|
|
121
128
|
|
|
122
|
-
:
|
|
129
|
+
:global {
|
|
123
130
|
.instance-node-selector {
|
|
124
131
|
padding: 0 6px;
|
|
125
132
|
margin-right: 3px;
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
width: 100%;
|
|
8
8
|
.list-item {
|
|
9
9
|
height: 28px;
|
|
10
|
+
position: relative;
|
|
10
11
|
background: #fff;
|
|
11
12
|
border: 1px solid #e5e6e8;
|
|
12
13
|
border-radius: 6px;
|
|
@@ -37,6 +38,41 @@
|
|
|
37
38
|
cursor: pointer;
|
|
38
39
|
}
|
|
39
40
|
}
|
|
41
|
+
|
|
42
|
+
.list-item-bottom-line {
|
|
43
|
+
width: 100%;
|
|
44
|
+
height: 8px;
|
|
45
|
+
border-bottom: solid 1px var(--ant-primary-color);
|
|
46
|
+
position: absolute;
|
|
47
|
+
left: 0;
|
|
48
|
+
bottom: -6px;
|
|
49
|
+
padding-top: 4px;
|
|
50
|
+
display: none;
|
|
51
|
+
align-items: center;
|
|
52
|
+
justify-content: center;
|
|
53
|
+
cursor: pointer;
|
|
54
|
+
z-index: 10;
|
|
55
|
+
}
|
|
56
|
+
.list-item-bottom-line::after {
|
|
57
|
+
content: "+";
|
|
58
|
+
height: 12px;
|
|
59
|
+
margin-top: 4px;
|
|
60
|
+
color: var(--ant-primary-color);
|
|
61
|
+
border: solid 1px var(--ant-primary-color);
|
|
62
|
+
border-radius: 10px;
|
|
63
|
+
font-weight: bold;
|
|
64
|
+
font-size: 14px;
|
|
65
|
+
background-color: white;
|
|
66
|
+
padding: 0 8px;
|
|
67
|
+
display: flex;
|
|
68
|
+
align-items: center;
|
|
69
|
+
justify-content: center;
|
|
70
|
+
}
|
|
71
|
+
&:hover {
|
|
72
|
+
.list-item-bottom-line {
|
|
73
|
+
display: flex;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
40
76
|
}
|
|
41
77
|
}
|
|
42
78
|
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
.lc-painter-panel-section-pagelayoutdisplay {
|
|
2
|
+
.display-type-box {
|
|
3
|
+
display: grid;
|
|
4
|
+
grid-template-columns: repeat(3, 1fr);
|
|
5
|
+
grid-column-gap: 4px;
|
|
6
|
+
|
|
7
|
+
.display-type-item {
|
|
8
|
+
border: 1px solid rgba(0, 0, 0, 0.2);
|
|
9
|
+
border-radius: 4px;
|
|
10
|
+
padding: 3px;
|
|
11
|
+
height: 42px;
|
|
12
|
+
display: flex;
|
|
13
|
+
|
|
14
|
+
&:hover {
|
|
15
|
+
cursor: pointer;
|
|
16
|
+
border-color: var(--ant-primary-color);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
&.active {
|
|
20
|
+
border-color: var(--ant-primary-color);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.item-block {
|
|
24
|
+
background-color: rgb(192, 194, 196);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -11,15 +11,6 @@
|
|
|
11
11
|
height: 42px;
|
|
12
12
|
display: flex;
|
|
13
13
|
|
|
14
|
-
&:hover {
|
|
15
|
-
cursor: pointer;
|
|
16
|
-
border-color: var(--ant-primary-color);
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
&.active {
|
|
20
|
-
border-color: var(--ant-primary-color);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
14
|
.item-block {
|
|
24
15
|
background-color: rgb(192, 194, 196);
|
|
25
16
|
}
|
|
@@ -1,14 +1,29 @@
|
|
|
1
|
-
import
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
2
|
+
import React, { useState } from 'react';
|
|
3
|
+
import { useUpdateEffect } from 'ahooks';
|
|
2
4
|
import EventBusProvider from "../engine/provider/EventBusProvider";
|
|
3
5
|
import ContextProvider from "../engine/provider/ContextProvider";
|
|
4
6
|
import Page from "../view/Page";
|
|
5
7
|
import { RUNTIME } from "../constants/index";
|
|
6
8
|
var Preview = function Preview(_ref) {
|
|
7
|
-
var code = _ref.code
|
|
8
|
-
|
|
9
|
+
var code = _ref.code,
|
|
10
|
+
userId = _ref.userId,
|
|
11
|
+
debug = _ref.debug;
|
|
12
|
+
var _useState = useState(userId),
|
|
13
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
14
|
+
currentKey = _useState2[0],
|
|
15
|
+
setCurrentKey = _useState2[1];
|
|
16
|
+
useUpdateEffect(function () {
|
|
17
|
+
setCurrentKey(void 0);
|
|
18
|
+
setTimeout(function () {
|
|
19
|
+
setCurrentKey(userId);
|
|
20
|
+
});
|
|
21
|
+
}, [userId]);
|
|
22
|
+
return code && currentKey ? /*#__PURE__*/React.createElement(EventBusProvider, {
|
|
9
23
|
runtime: RUNTIME.PREVIEW
|
|
10
24
|
}, /*#__PURE__*/React.createElement(ContextProvider, {
|
|
11
|
-
code: code
|
|
12
|
-
|
|
25
|
+
code: code,
|
|
26
|
+
debug: debug
|
|
27
|
+
}, /*#__PURE__*/React.createElement(Page, null))) : null;
|
|
13
28
|
};
|
|
14
29
|
export default Preview;
|
|
@@ -3,7 +3,7 @@ import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import styled from 'styled-components';
|
|
5
5
|
import classNames from 'classnames';
|
|
6
|
-
import {
|
|
6
|
+
import { useGet } from "../engine/provider/ContextProvider";
|
|
7
7
|
import PageHeader from "./lc-components/PageHeader";
|
|
8
8
|
import PageContent from "./lc-components/PageContent";
|
|
9
9
|
import PageFooter from "./lc-components/PageFooter";
|
|
@@ -18,12 +18,11 @@ var PageRoot = styled.div.withConfig({
|
|
|
18
18
|
});
|
|
19
19
|
var Canvas = function Canvas(_ref) {
|
|
20
20
|
var className = _ref.className;
|
|
21
|
-
var
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
enableFooter = _usePageData2$[2];
|
|
21
|
+
var _useGet = useGet(['props.css', 'props.enableHeader', 'props.enableFooter']),
|
|
22
|
+
_useGet2 = _slicedToArray(_useGet, 3),
|
|
23
|
+
pagerootCss = _useGet2[0],
|
|
24
|
+
enableHeader = _useGet2[1],
|
|
25
|
+
enableFooter = _useGet2[2];
|
|
27
26
|
return /*#__PURE__*/React.createElement(PageRoot, {
|
|
28
27
|
id: "page-canvas",
|
|
29
28
|
className: classNames(styles['lc-view-canvas'], _defineProperty({}, className, !!className)),
|
package/es/lowcode/view/Page.js
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
|
-
var _excluded = ["className"];
|
|
4
|
+
var _excluded = ["className", "children"];
|
|
5
5
|
import React, { useRef, forwardRef } from 'react';
|
|
6
6
|
import { useMemoizedFn } from 'ahooks';
|
|
7
7
|
import classNames from 'classnames';
|
|
8
|
-
import { isNil } from 'lodash';
|
|
9
8
|
import styled from 'styled-components';
|
|
10
9
|
import { useRemoteSource } from "../engine/provider/ContextProvider";
|
|
11
10
|
import Loading from "./Loading";
|
|
@@ -19,12 +18,12 @@ var Masker = styled.div.withConfig({
|
|
|
19
18
|
})(["position:absolute;top:0;left:0;width:100%;height:100%;z-index:2400;background:rgba(0,0,0,0.45);cursor:none;"]);
|
|
20
19
|
var LCPage = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
21
20
|
var className = _ref2.className,
|
|
21
|
+
children = _ref2.children,
|
|
22
22
|
props = _objectWithoutProperties(_ref2, _excluded);
|
|
23
23
|
var _ref = useRef(null);
|
|
24
24
|
var _rootRef = ref || _ref;
|
|
25
25
|
var _useRemoteSource = useRemoteSource(),
|
|
26
|
-
loading = _useRemoteSource.loading
|
|
27
|
-
pageData = _useRemoteSource.pageData;
|
|
26
|
+
loading = _useRemoteSource.loading;
|
|
28
27
|
var getTargetDom = useMemoizedFn(function () {
|
|
29
28
|
return _rootRef.current;
|
|
30
29
|
});
|
|
@@ -33,7 +32,7 @@ var LCPage = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
33
32
|
getTargetDom: getTargetDom
|
|
34
33
|
}, /*#__PURE__*/React.createElement("div", _extends({
|
|
35
34
|
ref: _rootRef,
|
|
36
|
-
className: classNames(styles['lc-view-page'], _defineProperty(_defineProperty({}, styles.isloading, loading), className, !!className))
|
|
37
|
-
}, props),
|
|
35
|
+
className: classNames(styles['lc-view-page'], 'affixWrap', _defineProperty(_defineProperty({}, styles.isloading, loading), className, !!className))
|
|
36
|
+
}, props), children, /*#__PURE__*/React.createElement(Canvas, null), loading ? /*#__PURE__*/React.createElement(Masker, null, /*#__PURE__*/React.createElement(Loading, null)) : null));
|
|
38
37
|
});
|
|
39
38
|
export default LCPage;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
4
|
-
var _excluded = ["children"];
|
|
4
|
+
var _excluded = ["children", "className"];
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { useCreation } from 'ahooks';
|
|
7
7
|
import classNames from 'classnames';
|
|
@@ -9,12 +9,13 @@ import Index from "./index";
|
|
|
9
9
|
import styles from "./index.less";
|
|
10
10
|
var FunctionDesign = function FunctionDesign(_ref) {
|
|
11
11
|
var children = _ref.children,
|
|
12
|
+
className = _ref.className,
|
|
12
13
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
13
14
|
var isEmpty = useCreation(function () {
|
|
14
15
|
return !children || React.Children.count(children) === 0;
|
|
15
16
|
}, [children]);
|
|
16
17
|
return /*#__PURE__*/React.createElement(Index, _extends({
|
|
17
|
-
className: classNames(styles['lc-component-box-design'], _defineProperty({}, styles.placeholder, isEmpty))
|
|
18
|
+
className: classNames(styles['lc-component-box-design'], _defineProperty(_defineProperty({}, styles.placeholder, isEmpty), "className", !!className))
|
|
18
19
|
}, props), isEmpty ? '点击组件库的组件或拖拽组件到这里' : children);
|
|
19
20
|
};
|
|
20
21
|
export default FunctionDesign;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
2
|
var _excluded = ["children"];
|
|
3
|
+
import React from 'react';
|
|
3
4
|
import Index from "./index";
|
|
4
5
|
var FunctionPreview = function FunctionPreview(_ref) {
|
|
5
6
|
var children = _ref.children,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"component": "Box",
|
|
3
|
-
"name": "
|
|
3
|
+
"name": "盒子",
|
|
4
4
|
"desc": "盒子是一个用于包裹其他组件的包装器,是一个单纯的容器组件,可以对其设置样式达到想要的效果。",
|
|
5
5
|
"icon": "icon-box",
|
|
6
6
|
"group": "container",
|
|
@@ -21,19 +21,19 @@
|
|
|
21
21
|
"key": "onMount",
|
|
22
22
|
"name": "组件首次渲染时",
|
|
23
23
|
"desc": "在组件首次渲染时,执行方法",
|
|
24
|
-
"func": "(params)
|
|
24
|
+
"func": "function onMount(params) {\n\t\n}"
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
"key": "onUnmount",
|
|
28
28
|
"name": "组件卸载时",
|
|
29
29
|
"desc": "在组件卸载时,执行方法。",
|
|
30
|
-
"func": "(params)
|
|
30
|
+
"func": "function onUnmount(params) {\n\t\n}"
|
|
31
31
|
},
|
|
32
32
|
{
|
|
33
33
|
"key": "onClick",
|
|
34
34
|
"name": "点击事件",
|
|
35
35
|
"desc": "点击文本时,执行方法",
|
|
36
|
-
"func": "(e)
|
|
36
|
+
"func": "function onClick(e) {\n\t\n}"
|
|
37
37
|
}
|
|
38
38
|
]
|
|
39
39
|
}
|
|
@@ -33,14 +33,10 @@ var LCButton = function LCButton(_ref) {
|
|
|
33
33
|
var ref = useRef();
|
|
34
34
|
var ctx = useContext();
|
|
35
35
|
useMount(function () {
|
|
36
|
-
ctx.doAction(advance.events.onMount
|
|
37
|
-
instance: ref.current
|
|
38
|
-
});
|
|
36
|
+
ctx.doAction(advance.events.onMount);
|
|
39
37
|
});
|
|
40
38
|
useUnmount(function () {
|
|
41
|
-
ctx.doAction(advance.events.onUnmount
|
|
42
|
-
instance: ref.current
|
|
43
|
-
});
|
|
39
|
+
ctx.doAction(advance.events.onUnmount);
|
|
44
40
|
});
|
|
45
41
|
var handleClick = useMemoizedFn(function (e) {
|
|
46
42
|
if (onClick) {
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
{
|
|
17
17
|
"key": "title",
|
|
18
18
|
"name": "标题",
|
|
19
|
-
"type": "
|
|
19
|
+
"type": "_I18nInput",
|
|
20
20
|
"repositioning": true,
|
|
21
21
|
"default": "按钮"
|
|
22
22
|
},
|
|
@@ -108,19 +108,19 @@
|
|
|
108
108
|
"key": "onMount",
|
|
109
109
|
"name": "组件首次渲染时",
|
|
110
110
|
"desc": "在组件首次渲染时,执行方法",
|
|
111
|
-
"func": "(
|
|
111
|
+
"func": "function onMount() {\n\t\n}"
|
|
112
112
|
},
|
|
113
113
|
{
|
|
114
114
|
"key": "onUnmount",
|
|
115
115
|
"name": "组件卸载时",
|
|
116
116
|
"desc": "在组件卸载时,执行方法。",
|
|
117
|
-
"func": "(
|
|
117
|
+
"func": "function onUnmount() {\n\t\n}"
|
|
118
118
|
},
|
|
119
119
|
{
|
|
120
120
|
"key": "onClick",
|
|
121
121
|
"name": "点击事件",
|
|
122
122
|
"desc": "点击文本时,执行方法",
|
|
123
|
-
"func": "(e)
|
|
123
|
+
"func": "function onClick(e) {\n\t\n}"
|
|
124
124
|
}
|
|
125
125
|
]
|
|
126
126
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
2
|
var _excluded = ["children"];
|
|
3
|
+
import React from 'react';
|
|
3
4
|
import Index from "./index";
|
|
4
5
|
var FunctionPreview = function FunctionPreview(_ref) {
|
|
5
6
|
var children = _ref.children,
|
|
@@ -15,9 +15,19 @@
|
|
|
15
15
|
},
|
|
16
16
|
{
|
|
17
17
|
"key": "dataset",
|
|
18
|
-
"name": "
|
|
19
|
-
"
|
|
20
|
-
"
|
|
18
|
+
"name": "数据集",
|
|
19
|
+
"type": "_DataSetSelector",
|
|
20
|
+
"component": "table",
|
|
21
|
+
"next": {
|
|
22
|
+
"name": "字段配置",
|
|
23
|
+
"props": [
|
|
24
|
+
{
|
|
25
|
+
"key": "fields",
|
|
26
|
+
"name": "#字段配置器",
|
|
27
|
+
"type": "_FieldsSetting"
|
|
28
|
+
}
|
|
29
|
+
]
|
|
30
|
+
}
|
|
21
31
|
},
|
|
22
32
|
{
|
|
23
33
|
"key": "autoLoad",
|
|
@@ -57,7 +67,7 @@
|
|
|
57
67
|
"key": "actionTitle",
|
|
58
68
|
"name": "操作列标题",
|
|
59
69
|
"desc": "操作列的标题",
|
|
60
|
-
"type": "
|
|
70
|
+
"type": "_I18nInput",
|
|
61
71
|
"default": "操作列"
|
|
62
72
|
},
|
|
63
73
|
{
|
|
@@ -1,16 +1,13 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
3
3
|
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
4
|
-
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
5
4
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
6
5
|
var _excluded = ["id", "children", "className"];
|
|
7
6
|
import React from 'react';
|
|
8
7
|
import { useCreation } from 'ahooks';
|
|
9
|
-
import { cloneDeep } from 'lodash';
|
|
10
8
|
import Index from "./index";
|
|
11
9
|
import { suid } from '@luck-design-biz/base/utils';
|
|
12
|
-
import { useContext,
|
|
13
|
-
import { add } from "../../../engine/tools/dataProcess";
|
|
10
|
+
import { useContext, addNode } from "../../../engine/provider/ContextProvider";
|
|
14
11
|
import classNames from 'classnames';
|
|
15
12
|
import styles from "./index.less";
|
|
16
13
|
import boxDefaultMeta from "../../../engine/meta/box.props.default.json";
|
|
@@ -20,20 +17,14 @@ var FunctionDesign = function FunctionDesign(_ref) {
|
|
|
20
17
|
className = _ref.className,
|
|
21
18
|
props = _objectWithoutProperties(_ref, _excluded);
|
|
22
19
|
var ctx = useContext();
|
|
23
|
-
var _usePageData = usePageData(),
|
|
24
|
-
_usePageData2 = _slicedToArray(_usePageData, 2),
|
|
25
|
-
setPageData = _usePageData2[1].setPageData;
|
|
26
20
|
useCreation(function () {
|
|
27
21
|
if (children !== null && children !== void 0 && children.length) return;
|
|
28
22
|
ctx.$subscriber(ctx.topics.COMPONENT_APPEND).once(function (_ref2) {
|
|
29
|
-
var compId = _ref2.id
|
|
30
|
-
pageData = _ref2.pageData;
|
|
23
|
+
var compId = _ref2.id;
|
|
31
24
|
if (compId !== id) return;
|
|
32
|
-
|
|
33
|
-
add(cloneData, id, "box_".concat(suid()), _objectSpread(_objectSpread({}, boxDefaultMeta), {}, {
|
|
25
|
+
addNode(id, "box_".concat(suid()), _objectSpread(_objectSpread({}, boxDefaultMeta), {}, {
|
|
34
26
|
buildIn: true
|
|
35
27
|
}));
|
|
36
|
-
setPageData(cloneData);
|
|
37
28
|
}).watch();
|
|
38
29
|
}, []);
|
|
39
30
|
return /*#__PURE__*/React.createElement(Index, _extends({
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
|
|
2
2
|
var _excluded = ["children"];
|
|
3
|
+
import React from 'react';
|
|
3
4
|
import Index from "./index";
|
|
4
5
|
var FunctionPreview = function FunctionPreview(_ref) {
|
|
5
6
|
var children = _ref.children,
|