@luck-design-biz/luckda 0.0.25-11 → 0.0.25-12

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.
Files changed (434) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +40 -40
  3. package/es/components/LDActions/index.less +68 -68
  4. package/es/components/LdAutoForm/index.js +24 -2
  5. package/es/components/LdFormList/index.js +4 -2
  6. package/es/components/LdGrid/index.js +6 -5
  7. package/es/components/LdGridForm/index.js +5 -1
  8. package/es/components/LdGridForm/index.less +7 -7
  9. package/es/components/LdTree/index.js +27 -5
  10. package/es/components/LdTree/index.less +40 -40
  11. package/es/helper/action.js +6 -6
  12. package/es/helper/form.js +15 -15
  13. package/es/helper/index.less +7 -7
  14. package/es/index.js +0 -1
  15. package/es/lowcode/constants/api-url.js +84 -84
  16. package/es/lowcode/constants/event-topics.js +1 -0
  17. package/es/lowcode/engine/factory/panel-item-factory/StringStrategy.js +1 -1
  18. package/es/lowcode/engine/launcher.js +5 -0
  19. package/es/lowcode/engine/meta/box.props.default.json +1 -1
  20. package/es/lowcode/engine/meta/box.props.json +1 -1
  21. package/es/lowcode/engine/meta/components-list.json +6 -6
  22. package/es/lowcode/engine/meta/fieldcolor.props.json +9 -3
  23. package/es/lowcode/engine/meta/fieldcomplex.props.json +7 -1
  24. package/es/lowcode/engine/meta/fielddatadic.props.default.json +16 -0
  25. package/es/lowcode/engine/meta/fielddatadic.props.json +73 -0
  26. package/es/lowcode/engine/meta/fielddate.props.json +7 -1
  27. package/es/lowcode/engine/meta/fielddict.props.json +7 -1
  28. package/es/lowcode/engine/meta/fieldeditor.props.json +7 -1
  29. package/es/lowcode/engine/meta/fieldgroup.props.json +7 -1
  30. package/es/lowcode/engine/meta/fieldnumber.props.json +8 -2
  31. package/es/lowcode/engine/meta/fieldradio.props.json +9 -3
  32. package/es/lowcode/engine/meta/fieldregion.props.json +9 -3
  33. package/es/lowcode/engine/meta/fieldselect.props.json +9 -3
  34. package/es/lowcode/engine/meta/fieldstring.props.default.json +0 -4
  35. package/es/lowcode/engine/meta/fieldstring.props.json +14 -12
  36. package/es/lowcode/engine/meta/fieldswitch.props.json +8 -2
  37. package/es/lowcode/engine/meta/fieldtextarea.props.json +11 -5
  38. package/es/lowcode/engine/meta/fieldupload.props.json +8 -2
  39. package/es/lowcode/engine/meta/fielduser.props.json +7 -1
  40. package/es/lowcode/engine/meta/fieldyear.props.json +8 -2
  41. package/es/lowcode/engine/meta/form.props.json +22 -2
  42. package/es/lowcode/engine/meta/js-editor/auto-complete.json +17 -17
  43. package/es/lowcode/engine/meta/page.props.json +6 -6
  44. package/es/lowcode/engine/provider/ContextProvider/index.js +34 -34
  45. package/es/lowcode/engine/provider/RemoteSourceProvider.js +30 -8
  46. package/es/lowcode/engine/tools/dataProcess.js +76 -76
  47. package/es/lowcode/engine/tools/helper.js +60 -3
  48. package/es/lowcode/engine/tools/usePageDataStore.js +10 -5
  49. package/es/lowcode/index.js +1 -4
  50. package/es/lowcode/painter/Components.js +2 -2
  51. package/es/lowcode/painter/Design.js +4 -4
  52. package/es/lowcode/painter/DesignOperator.js +1 -1
  53. package/es/lowcode/painter/DesignToolbar.js +7 -4
  54. package/es/lowcode/painter/components/ActionBindModal.js +7 -1
  55. package/es/lowcode/painter/components/Collapse.js +26 -26
  56. package/es/lowcode/painter/components/ColorInput.js +24 -24
  57. package/es/lowcode/painter/components/ListEditor.js +24 -24
  58. package/es/lowcode/painter/components/NumberInput.js +28 -28
  59. package/es/lowcode/painter/components/PanelItem.js +24 -24
  60. package/es/lowcode/painter/components/PopConfirm.js +8 -8
  61. package/es/lowcode/painter/components/PopForm.js +27 -27
  62. package/es/lowcode/painter/components/RuleInput.js +30 -31
  63. package/es/lowcode/painter/components/SortBox.js +22 -22
  64. package/es/lowcode/painter/components/code-editor/BaseEditor.js +32 -32
  65. package/es/lowcode/painter/components/code-editor/CssEditor.js +25 -25
  66. package/es/lowcode/painter/components/code-editor/FullScreenEditor.js +23 -23
  67. package/es/lowcode/painter/components/code-editor/JSEditor.js +44 -34
  68. package/es/lowcode/painter/components/code-editor/JsonEditor.js +25 -25
  69. package/es/lowcode/painter/panel-section/ActionsEditor/index.js +3 -1
  70. package/es/lowcode/painter/panel-section/ComponentSelector.js +36 -0
  71. package/es/lowcode/painter/panel-section/I18nInput.js +2 -1
  72. package/es/lowcode/painter/panel-section/Icon.js +23 -23
  73. package/es/lowcode/painter/panel-section/IconSelector.js +16 -16
  74. package/es/lowcode/painter/panel-section/LayoutRatio.js +21 -21
  75. package/es/lowcode/painter/panel-section/SplitDisplay.js +3 -2
  76. package/es/lowcode/painter/panel-section/StylePanel/BackGround.js +2 -2
  77. package/es/lowcode/painter/panel-section/StylePanel/Border.js +2 -2
  78. package/es/lowcode/painter/panel-section/StylePanel/BorderRadius.js +2 -2
  79. package/es/lowcode/painter/panel-section/StylePanel/BorderRadiusSelector.js +2 -2
  80. package/es/lowcode/painter/panel-section/StylePanel/BorderSelector.js +2 -2
  81. package/es/lowcode/painter/panel-section/StylePanel/Display.js +2 -2
  82. package/es/lowcode/painter/panel-section/StylePanel/Font.js +2 -2
  83. package/es/lowcode/painter/panel-section/StylePanel/FontEditor.js +2 -2
  84. package/es/lowcode/painter/panel-section/StylePanel/GapSelector.js +2 -2
  85. package/es/lowcode/painter/panel-section/StylePanel/HighLightPanel.js +2 -2
  86. package/es/lowcode/painter/panel-section/StylePanel/HighLigthtSpan.js +2 -2
  87. package/es/lowcode/painter/panel-section/StylePanel/HightLightSvg.js +2 -2
  88. package/es/lowcode/painter/panel-section/StylePanel/MainPanel.js +2 -2
  89. package/es/lowcode/painter/panel-section/StylePanel/Margin.js +2 -2
  90. package/es/lowcode/painter/panel-section/StylePanel/Opacity.js +2 -2
  91. package/es/lowcode/painter/panel-section/StylePanel/Padding.js +2 -2
  92. package/es/lowcode/painter/panel-section/StylePanel/Pointer.js +2 -2
  93. package/es/lowcode/painter/panel-section/StylePanel/Shadow.js +2 -2
  94. package/es/lowcode/painter/panel-section/StylePanel/Size.js +2 -2
  95. package/es/lowcode/painter/panel-section/StylePanel/StyleContext.js +2 -2
  96. package/es/lowcode/painter/panel-section/StylePanel/StyleRow.js +2 -2
  97. package/es/lowcode/painter/panel-section/StylePanel/WidthHeight.js +2 -2
  98. package/es/lowcode/painter/panel-section/StylePanel/index.js +15 -15
  99. package/es/lowcode/painter/panel-section/TreeRootEditor.js +10 -2
  100. package/es/lowcode/painter/style/action-bind-modal.less +102 -102
  101. package/es/lowcode/painter/style/actions-editor.less +15 -15
  102. package/es/lowcode/painter/style/border-editor.less +36 -36
  103. package/es/lowcode/painter/style/border-radius-selector.less +42 -42
  104. package/es/lowcode/painter/style/border-selector.less +39 -39
  105. package/es/lowcode/painter/style/button-type.less +5 -5
  106. package/es/lowcode/painter/style/collapse.less +28 -28
  107. package/es/lowcode/painter/style/color-input.less +19 -19
  108. package/es/lowcode/painter/style/components.less +91 -91
  109. package/es/lowcode/painter/style/design.less +158 -155
  110. package/es/lowcode/painter/style/display.less +17 -17
  111. package/es/lowcode/painter/style/dragdrop.less +10 -10
  112. package/es/lowcode/painter/style/fields-setting.less +25 -25
  113. package/es/lowcode/painter/style/font-editor.less +9 -9
  114. package/es/lowcode/painter/style/fullscreen-editor.less +17 -17
  115. package/es/lowcode/painter/style/icon-selector.less +22 -22
  116. package/es/lowcode/painter/style/icon.less +10 -10
  117. package/es/lowcode/painter/style/impexp.less +7 -7
  118. package/es/lowcode/painter/style/index.less +6 -6
  119. package/es/lowcode/painter/style/layout-ratio.less +51 -51
  120. package/es/lowcode/painter/style/list-editor.less +95 -95
  121. package/es/lowcode/painter/style/number-input.less +17 -17
  122. package/es/lowcode/painter/style/outline.less +28 -28
  123. package/es/lowcode/painter/style/page-layout-display.less +27 -27
  124. package/es/lowcode/painter/style/panel-attrs.less +43 -43
  125. package/es/lowcode/painter/style/panel-item.less +54 -54
  126. package/es/lowcode/painter/style/panel.less +98 -98
  127. package/es/lowcode/painter/style/pop-confirm.less +17 -17
  128. package/es/lowcode/painter/style/pop-form.less +19 -19
  129. package/es/lowcode/painter/style/radio.less +24 -24
  130. package/es/lowcode/painter/style/ribbon.less +5 -5
  131. package/es/lowcode/painter/style/rule-input.less +12 -12
  132. package/es/lowcode/painter/style/split-display.less +18 -18
  133. package/es/lowcode/painter/style/style-panel.less +37 -37
  134. package/es/lowcode/painter/style/tabitems.less +90 -90
  135. package/es/lowcode/painter/style/treedragdrop.less +19 -19
  136. package/es/lowcode/view/Canvas.js +20 -6
  137. package/es/lowcode/view/Page.js +3 -4
  138. package/es/lowcode/view/lc-components/Box/FunctionDesign.js +7 -2
  139. package/es/lowcode/view/lc-components/Box/index.js +4 -4
  140. package/es/lowcode/view/lc-components/Box/index.less +14 -14
  141. package/es/lowcode/view/lc-components/Box/meta.json +40 -40
  142. package/es/lowcode/view/lc-components/Button/index.js +33 -33
  143. package/es/lowcode/view/lc-components/Button/meta.json +127 -127
  144. package/es/lowcode/view/lc-components/Button/style.less +2 -2
  145. package/es/lowcode/view/lc-components/CardList/meta.json +153 -153
  146. package/es/lowcode/view/lc-components/Dialog/index.js +16 -13
  147. package/es/lowcode/view/lc-components/Dialog/index.less +3 -3
  148. package/es/lowcode/view/lc-components/Dialog/meta.json +150 -150
  149. package/es/lowcode/view/lc-components/Drawer/index.js +15 -12
  150. package/es/lowcode/view/lc-components/Drawer/index.less +9 -9
  151. package/es/lowcode/view/lc-components/Drawer/meta.json +131 -131
  152. package/es/lowcode/view/lc-components/FieldColor/meta.json +69 -63
  153. package/es/lowcode/view/lc-components/FieldComplex/meta.json +45 -39
  154. package/es/lowcode/view/lc-components/FieldDate/meta.json +51 -45
  155. package/es/lowcode/view/lc-components/FieldDict/meta.json +50 -44
  156. package/es/lowcode/view/lc-components/FieldEditor/meta.json +50 -44
  157. package/es/lowcode/view/lc-components/FieldGroup/meta.json +79 -73
  158. package/es/lowcode/view/lc-components/FieldNumber/meta.json +54 -48
  159. package/es/lowcode/view/lc-components/FieldRadio/meta.json +26 -20
  160. package/es/lowcode/view/lc-components/FieldRegion/meta.json +32 -26
  161. package/es/lowcode/view/lc-components/FieldSelect/meta.json +64 -58
  162. package/es/lowcode/view/lc-components/FieldString/meta.json +64 -62
  163. package/es/lowcode/view/lc-components/FieldSwitch/meta.json +37 -31
  164. package/es/lowcode/view/lc-components/FieldTextarea/meta.json +55 -49
  165. package/es/lowcode/view/lc-components/FieldUpload/meta.json +77 -71
  166. package/es/lowcode/view/lc-components/FieldUser/meta.json +88 -82
  167. package/es/lowcode/view/lc-components/FieldYear/meta.json +41 -35
  168. package/es/lowcode/view/lc-components/Form/index.js +116 -23
  169. package/es/lowcode/view/lc-components/Form/index.less +4 -4
  170. package/es/lowcode/view/lc-components/Form/meta.json +616 -605
  171. package/es/lowcode/view/lc-components/Iframe/meta.json +32 -32
  172. package/es/lowcode/view/lc-components/ImEx/index.js +29 -29
  173. package/es/lowcode/view/lc-components/ImEx/index.less +7 -7
  174. package/es/lowcode/view/lc-components/ImEx/meta.json +113 -113
  175. package/es/lowcode/view/lc-components/Image/meta.json +114 -114
  176. package/es/{components/LdRuntimeCom/index.js → lowcode/view/lc-components/JSX/RuntimeComp.js} +12 -15
  177. package/es/lowcode/view/lc-components/JSX/index.js +5 -6
  178. package/es/lowcode/view/lc-components/JSX/meta.json +28 -28
  179. package/es/lowcode/view/lc-components/Layout/index.js +19 -17
  180. package/es/lowcode/view/lc-components/Layout/index.less +5 -5
  181. package/es/lowcode/view/lc-components/Layout/meta.json +107 -107
  182. package/es/lowcode/view/lc-components/Link/index.js +3 -0
  183. package/es/lowcode/view/lc-components/Link/meta.json +112 -112
  184. package/es/lowcode/view/lc-components/Page/meta.json +49 -49
  185. package/es/lowcode/view/lc-components/PageContent/index.js +3 -1
  186. package/es/lowcode/view/lc-components/PageContent/meta.json +9 -9
  187. package/es/lowcode/view/lc-components/PageFooter/index.js +3 -0
  188. package/es/lowcode/view/lc-components/PageFooter/meta.json +9 -9
  189. package/es/lowcode/view/lc-components/PageHeader/index.js +3 -0
  190. package/es/lowcode/view/lc-components/PageHeader/meta.json +9 -9
  191. package/es/lowcode/view/lc-components/PageLayout/index.js +3 -0
  192. package/es/lowcode/view/lc-components/PageLayout/meta.json +47 -47
  193. package/es/lowcode/view/lc-components/Section/index.js +6 -3
  194. package/es/lowcode/view/lc-components/Section/index.less +7 -7
  195. package/es/lowcode/view/lc-components/Section/meta.json +107 -107
  196. package/es/lowcode/view/lc-components/Split/index.js +3 -0
  197. package/es/lowcode/view/lc-components/Split/meta.json +53 -53
  198. package/es/lowcode/view/lc-components/Table/index.js +160 -167
  199. package/es/lowcode/view/lc-components/Table/meta.json +405 -405
  200. package/es/lowcode/view/lc-components/Tabs/index.js +25 -25
  201. package/es/lowcode/view/lc-components/Tabs/meta.json +113 -113
  202. package/es/lowcode/view/lc-components/Text/index.js +3 -0
  203. package/es/lowcode/view/lc-components/Text/meta.json +66 -66
  204. package/es/lowcode/view/lc-components/Tree/index.js +96 -96
  205. package/es/lowcode/view/lc-components/Tree/index.less +4 -4
  206. package/es/lowcode/view/lc-components/Tree/meta.json +363 -363
  207. package/es/lowcode/view/lc-components/Wrapper.js +1 -0
  208. package/es/lowcode/view/style/canvas.less +5 -5
  209. package/es/lowcode/view/style/loading.less +84 -84
  210. package/es/lowcode/view/style/page.less +7 -7
  211. package/es/upload/FilesWall/index.js +13 -13
  212. package/es/upload/FilesWall/index.less +74 -74
  213. package/es/upload/Form/index.less +7 -7
  214. package/es/upload/FormItem/index.js +15 -15
  215. package/es/utils/form.js +21 -21
  216. package/es/utils/grid.js +1 -1
  217. package/lib/components/LDActions/index.less +68 -68
  218. package/lib/components/LdAutoForm/index.js +23 -1
  219. package/lib/components/LdFormList/index.js +4 -2
  220. package/lib/components/LdGrid/index.js +6 -5
  221. package/lib/components/LdGridForm/index.js +5 -1
  222. package/lib/components/LdGridForm/index.less +7 -7
  223. package/lib/components/LdTree/index.js +25 -3
  224. package/lib/components/LdTree/index.less +40 -40
  225. package/lib/helper/action.js +6 -6
  226. package/lib/helper/form.js +15 -15
  227. package/lib/helper/index.less +7 -7
  228. package/lib/index.js +1 -9
  229. package/lib/lowcode/constants/api-url.js +84 -84
  230. package/lib/lowcode/constants/event-topics.js +2 -1
  231. package/lib/lowcode/engine/factory/panel-item-factory/StringStrategy.js +1 -1
  232. package/lib/lowcode/engine/launcher.js +11 -0
  233. package/lib/lowcode/engine/meta/box.props.default.json +1 -1
  234. package/lib/lowcode/engine/meta/box.props.json +1 -1
  235. package/lib/lowcode/engine/meta/components-list.json +6 -6
  236. package/lib/lowcode/engine/meta/fieldcolor.props.json +9 -3
  237. package/lib/lowcode/engine/meta/fieldcomplex.props.json +7 -1
  238. package/lib/lowcode/engine/meta/fielddatadic.props.default.json +16 -0
  239. package/lib/lowcode/engine/meta/fielddatadic.props.json +73 -0
  240. package/lib/lowcode/engine/meta/fielddate.props.json +7 -1
  241. package/lib/lowcode/engine/meta/fielddict.props.json +7 -1
  242. package/lib/lowcode/engine/meta/fieldeditor.props.json +7 -1
  243. package/lib/lowcode/engine/meta/fieldgroup.props.json +7 -1
  244. package/lib/lowcode/engine/meta/fieldnumber.props.json +8 -2
  245. package/lib/lowcode/engine/meta/fieldradio.props.json +9 -3
  246. package/lib/lowcode/engine/meta/fieldregion.props.json +9 -3
  247. package/lib/lowcode/engine/meta/fieldselect.props.json +9 -3
  248. package/lib/lowcode/engine/meta/fieldstring.props.default.json +0 -4
  249. package/lib/lowcode/engine/meta/fieldstring.props.json +14 -12
  250. package/lib/lowcode/engine/meta/fieldswitch.props.json +8 -2
  251. package/lib/lowcode/engine/meta/fieldtextarea.props.json +11 -5
  252. package/lib/lowcode/engine/meta/fieldupload.props.json +8 -2
  253. package/lib/lowcode/engine/meta/fielduser.props.json +7 -1
  254. package/lib/lowcode/engine/meta/fieldyear.props.json +8 -2
  255. package/lib/lowcode/engine/meta/form.props.json +22 -2
  256. package/lib/lowcode/engine/meta/js-editor/auto-complete.json +17 -17
  257. package/lib/lowcode/engine/meta/page.props.json +6 -6
  258. package/lib/lowcode/engine/provider/ContextProvider/index.js +34 -34
  259. package/lib/lowcode/engine/provider/RemoteSourceProvider.js +30 -8
  260. package/lib/lowcode/engine/tools/dataProcess.js +76 -76
  261. package/lib/lowcode/engine/tools/helper.js +61 -2
  262. package/lib/lowcode/engine/tools/usePageDataStore.js +9 -4
  263. package/lib/lowcode/index.js +1 -5
  264. package/lib/lowcode/painter/Components.js +2 -2
  265. package/lib/lowcode/painter/Design.js +4 -4
  266. package/lib/lowcode/painter/DesignOperator.js +1 -1
  267. package/lib/lowcode/painter/DesignToolbar.js +7 -4
  268. package/lib/lowcode/painter/components/ActionBindModal.js +6 -0
  269. package/lib/lowcode/painter/components/Collapse.js +26 -26
  270. package/lib/lowcode/painter/components/ColorInput.js +24 -24
  271. package/lib/lowcode/painter/components/ListEditor.js +24 -24
  272. package/lib/lowcode/painter/components/NumberInput.js +28 -28
  273. package/lib/lowcode/painter/components/PanelItem.js +24 -24
  274. package/lib/lowcode/painter/components/PopConfirm.js +8 -8
  275. package/lib/lowcode/painter/components/PopForm.js +27 -27
  276. package/lib/lowcode/painter/components/RuleInput.js +30 -31
  277. package/lib/lowcode/painter/components/SortBox.js +22 -22
  278. package/lib/lowcode/painter/components/code-editor/BaseEditor.js +32 -32
  279. package/lib/lowcode/painter/components/code-editor/CssEditor.js +25 -25
  280. package/lib/lowcode/painter/components/code-editor/FullScreenEditor.js +23 -23
  281. package/lib/lowcode/painter/components/code-editor/JSEditor.js +44 -34
  282. package/lib/lowcode/painter/components/code-editor/JsonEditor.js +25 -25
  283. package/lib/lowcode/painter/panel-section/ActionsEditor/index.js +3 -1
  284. package/lib/lowcode/painter/panel-section/ComponentSelector.js +43 -0
  285. package/lib/lowcode/painter/panel-section/I18nInput.js +2 -1
  286. package/lib/lowcode/painter/panel-section/Icon.js +23 -23
  287. package/lib/lowcode/painter/panel-section/IconSelector.js +16 -16
  288. package/lib/lowcode/painter/panel-section/LayoutRatio.js +21 -21
  289. package/lib/lowcode/painter/panel-section/SplitDisplay.js +3 -2
  290. package/lib/lowcode/painter/panel-section/StylePanel/BackGround.js +2 -2
  291. package/lib/lowcode/painter/panel-section/StylePanel/Border.js +2 -2
  292. package/lib/lowcode/painter/panel-section/StylePanel/BorderRadius.js +2 -2
  293. package/lib/lowcode/painter/panel-section/StylePanel/BorderRadiusSelector.js +2 -2
  294. package/lib/lowcode/painter/panel-section/StylePanel/BorderSelector.js +2 -2
  295. package/lib/lowcode/painter/panel-section/StylePanel/Display.js +2 -2
  296. package/lib/lowcode/painter/panel-section/StylePanel/Font.js +2 -2
  297. package/lib/lowcode/painter/panel-section/StylePanel/FontEditor.js +2 -2
  298. package/lib/lowcode/painter/panel-section/StylePanel/GapSelector.js +2 -2
  299. package/lib/lowcode/painter/panel-section/StylePanel/HighLightPanel.js +2 -2
  300. package/lib/lowcode/painter/panel-section/StylePanel/HighLigthtSpan.js +2 -2
  301. package/lib/lowcode/painter/panel-section/StylePanel/HightLightSvg.js +2 -2
  302. package/lib/lowcode/painter/panel-section/StylePanel/MainPanel.js +2 -2
  303. package/lib/lowcode/painter/panel-section/StylePanel/Margin.js +2 -2
  304. package/lib/lowcode/painter/panel-section/StylePanel/Opacity.js +2 -2
  305. package/lib/lowcode/painter/panel-section/StylePanel/Padding.js +2 -2
  306. package/lib/lowcode/painter/panel-section/StylePanel/Pointer.js +2 -2
  307. package/lib/lowcode/painter/panel-section/StylePanel/Shadow.js +2 -2
  308. package/lib/lowcode/painter/panel-section/StylePanel/Size.js +2 -2
  309. package/lib/lowcode/painter/panel-section/StylePanel/StyleContext.js +2 -2
  310. package/lib/lowcode/painter/panel-section/StylePanel/StyleRow.js +2 -2
  311. package/lib/lowcode/painter/panel-section/StylePanel/WidthHeight.js +2 -2
  312. package/lib/lowcode/painter/panel-section/StylePanel/index.js +15 -15
  313. package/lib/lowcode/painter/panel-section/TreeRootEditor.js +10 -2
  314. package/lib/lowcode/painter/style/action-bind-modal.less +102 -102
  315. package/lib/lowcode/painter/style/actions-editor.less +15 -15
  316. package/lib/lowcode/painter/style/border-editor.less +36 -36
  317. package/lib/lowcode/painter/style/border-radius-selector.less +42 -42
  318. package/lib/lowcode/painter/style/border-selector.less +39 -39
  319. package/lib/lowcode/painter/style/button-type.less +5 -5
  320. package/lib/lowcode/painter/style/collapse.less +28 -28
  321. package/lib/lowcode/painter/style/color-input.less +19 -19
  322. package/lib/lowcode/painter/style/components.less +91 -91
  323. package/lib/lowcode/painter/style/design.less +158 -155
  324. package/lib/lowcode/painter/style/display.less +17 -17
  325. package/lib/lowcode/painter/style/dragdrop.less +10 -10
  326. package/lib/lowcode/painter/style/fields-setting.less +25 -25
  327. package/lib/lowcode/painter/style/font-editor.less +9 -9
  328. package/lib/lowcode/painter/style/fullscreen-editor.less +17 -17
  329. package/lib/lowcode/painter/style/icon-selector.less +22 -22
  330. package/lib/lowcode/painter/style/icon.less +10 -10
  331. package/lib/lowcode/painter/style/impexp.less +7 -7
  332. package/lib/lowcode/painter/style/index.less +6 -6
  333. package/lib/lowcode/painter/style/layout-ratio.less +51 -51
  334. package/lib/lowcode/painter/style/list-editor.less +95 -95
  335. package/lib/lowcode/painter/style/number-input.less +17 -17
  336. package/lib/lowcode/painter/style/outline.less +28 -28
  337. package/lib/lowcode/painter/style/page-layout-display.less +27 -27
  338. package/lib/lowcode/painter/style/panel-attrs.less +43 -43
  339. package/lib/lowcode/painter/style/panel-item.less +54 -54
  340. package/lib/lowcode/painter/style/panel.less +98 -98
  341. package/lib/lowcode/painter/style/pop-confirm.less +17 -17
  342. package/lib/lowcode/painter/style/pop-form.less +19 -19
  343. package/lib/lowcode/painter/style/radio.less +24 -24
  344. package/lib/lowcode/painter/style/ribbon.less +5 -5
  345. package/lib/lowcode/painter/style/rule-input.less +12 -12
  346. package/lib/lowcode/painter/style/split-display.less +18 -18
  347. package/lib/lowcode/painter/style/style-panel.less +37 -37
  348. package/lib/lowcode/painter/style/tabitems.less +90 -90
  349. package/lib/lowcode/painter/style/treedragdrop.less +19 -19
  350. package/lib/lowcode/view/Canvas.js +20 -5
  351. package/lib/lowcode/view/Page.js +3 -4
  352. package/lib/lowcode/view/lc-components/Box/FunctionDesign.js +7 -2
  353. package/lib/lowcode/view/lc-components/Box/index.js +4 -4
  354. package/lib/lowcode/view/lc-components/Box/index.less +14 -14
  355. package/lib/lowcode/view/lc-components/Box/meta.json +40 -40
  356. package/lib/lowcode/view/lc-components/Button/index.js +33 -33
  357. package/lib/lowcode/view/lc-components/Button/meta.json +127 -127
  358. package/lib/lowcode/view/lc-components/Button/style.less +2 -2
  359. package/lib/lowcode/view/lc-components/CardList/meta.json +153 -153
  360. package/lib/lowcode/view/lc-components/Dialog/index.js +16 -13
  361. package/lib/lowcode/view/lc-components/Dialog/index.less +3 -3
  362. package/lib/lowcode/view/lc-components/Dialog/meta.json +150 -150
  363. package/lib/lowcode/view/lc-components/Drawer/index.js +15 -12
  364. package/lib/lowcode/view/lc-components/Drawer/index.less +9 -9
  365. package/lib/lowcode/view/lc-components/Drawer/meta.json +131 -131
  366. package/lib/lowcode/view/lc-components/FieldColor/meta.json +69 -63
  367. package/lib/lowcode/view/lc-components/FieldComplex/meta.json +45 -39
  368. package/lib/lowcode/view/lc-components/FieldDate/meta.json +51 -45
  369. package/lib/lowcode/view/lc-components/FieldDict/meta.json +50 -44
  370. package/lib/lowcode/view/lc-components/FieldEditor/meta.json +50 -44
  371. package/lib/lowcode/view/lc-components/FieldGroup/meta.json +79 -73
  372. package/lib/lowcode/view/lc-components/FieldNumber/meta.json +54 -48
  373. package/lib/lowcode/view/lc-components/FieldRadio/meta.json +26 -20
  374. package/lib/lowcode/view/lc-components/FieldRegion/meta.json +32 -26
  375. package/lib/lowcode/view/lc-components/FieldSelect/meta.json +64 -58
  376. package/lib/lowcode/view/lc-components/FieldString/meta.json +64 -62
  377. package/lib/lowcode/view/lc-components/FieldSwitch/meta.json +37 -31
  378. package/lib/lowcode/view/lc-components/FieldTextarea/meta.json +55 -49
  379. package/lib/lowcode/view/lc-components/FieldUpload/meta.json +77 -71
  380. package/lib/lowcode/view/lc-components/FieldUser/meta.json +88 -82
  381. package/lib/lowcode/view/lc-components/FieldYear/meta.json +41 -35
  382. package/lib/lowcode/view/lc-components/Form/index.js +115 -22
  383. package/lib/lowcode/view/lc-components/Form/index.less +4 -4
  384. package/lib/lowcode/view/lc-components/Form/meta.json +616 -605
  385. package/lib/lowcode/view/lc-components/Iframe/meta.json +32 -32
  386. package/lib/lowcode/view/lc-components/ImEx/index.js +29 -29
  387. package/lib/lowcode/view/lc-components/ImEx/index.less +7 -7
  388. package/lib/lowcode/view/lc-components/ImEx/meta.json +113 -113
  389. package/lib/lowcode/view/lc-components/Image/meta.json +114 -114
  390. package/lib/{components/LdRuntimeCom/index.js → lowcode/view/lc-components/JSX/RuntimeComp.js} +13 -16
  391. package/lib/lowcode/view/lc-components/JSX/index.js +5 -6
  392. package/lib/lowcode/view/lc-components/JSX/meta.json +28 -28
  393. package/lib/lowcode/view/lc-components/Layout/index.js +19 -17
  394. package/lib/lowcode/view/lc-components/Layout/index.less +5 -5
  395. package/lib/lowcode/view/lc-components/Layout/meta.json +107 -107
  396. package/lib/lowcode/view/lc-components/Link/index.js +3 -0
  397. package/lib/lowcode/view/lc-components/Link/meta.json +112 -112
  398. package/lib/lowcode/view/lc-components/Page/meta.json +49 -49
  399. package/lib/lowcode/view/lc-components/PageContent/index.js +2 -0
  400. package/lib/lowcode/view/lc-components/PageContent/meta.json +9 -9
  401. package/lib/lowcode/view/lc-components/PageFooter/index.js +3 -0
  402. package/lib/lowcode/view/lc-components/PageFooter/meta.json +9 -9
  403. package/lib/lowcode/view/lc-components/PageHeader/index.js +3 -0
  404. package/lib/lowcode/view/lc-components/PageHeader/meta.json +9 -9
  405. package/lib/lowcode/view/lc-components/PageLayout/index.js +3 -0
  406. package/lib/lowcode/view/lc-components/PageLayout/meta.json +47 -47
  407. package/lib/lowcode/view/lc-components/Section/index.js +6 -3
  408. package/lib/lowcode/view/lc-components/Section/index.less +7 -7
  409. package/lib/lowcode/view/lc-components/Section/meta.json +107 -107
  410. package/lib/lowcode/view/lc-components/Split/index.js +3 -0
  411. package/lib/lowcode/view/lc-components/Split/meta.json +53 -53
  412. package/lib/lowcode/view/lc-components/Table/index.js +160 -167
  413. package/lib/lowcode/view/lc-components/Table/meta.json +405 -405
  414. package/lib/lowcode/view/lc-components/Tabs/index.js +25 -25
  415. package/lib/lowcode/view/lc-components/Tabs/meta.json +113 -113
  416. package/lib/lowcode/view/lc-components/Text/index.js +3 -0
  417. package/lib/lowcode/view/lc-components/Text/meta.json +66 -66
  418. package/lib/lowcode/view/lc-components/Tree/index.js +96 -96
  419. package/lib/lowcode/view/lc-components/Tree/index.less +4 -4
  420. package/lib/lowcode/view/lc-components/Tree/meta.json +363 -363
  421. package/lib/lowcode/view/lc-components/Wrapper.js +1 -0
  422. package/lib/lowcode/view/style/canvas.less +5 -5
  423. package/lib/lowcode/view/style/loading.less +84 -84
  424. package/lib/lowcode/view/style/page.less +7 -7
  425. package/lib/upload/FilesWall/index.js +13 -13
  426. package/lib/upload/FilesWall/index.less +74 -74
  427. package/lib/upload/Form/index.less +7 -7
  428. package/lib/upload/FormItem/index.js +15 -15
  429. package/lib/utils/form.js +21 -21
  430. package/lib/utils/grid.js +1 -1
  431. package/lowcode.js +1 -1
  432. package/package.json +3 -5
  433. package/upload.js +1 -1
  434. package/utils.js +1 -1
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2020 UmiJS
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2020 UmiJS
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,40 +1,40 @@
1
- # 微服务 3.0 纯净版
2
-
3
- luck-react-pure 是一个基于 qiankun 框架搭建的极简微服务框架,作为微服务业务子系统的开发基座。旨在为业务子系统提供简单、轻量的解决方案。该框架去除了冗余的功能,专注于提供基本的功能支持,使开发者能够更快速地搭建和开发业务子系统。
4
-
5
- ## 启动
6
-
7
- 安装 `node_modules`:
8
-
9
- ```bash
10
- pnpm install
11
- ```
12
-
13
- ## 开始项目
14
-
15
- ```bash
16
- pnpm start
17
- ```
18
-
19
- ## 代码校验
20
-
21
- 本框架提供了代码校验方案,校验不通过禁止提交代码,当提交代码时将会校验以下内容:
22
-
23
- ### 代码规范
24
-
25
- 根据 eslint 校验规范。
26
-
27
- ### commit message 校验
28
-
29
- commit message 格式:
30
-
31
- ```bash
32
- 💥 feat(模块): 添加了个很棒的功能
33
- 🐛 fix(模块): 修复了一些 bug
34
- 📝 docs(模块): 更新了一下文档
35
- 💄 UI(模块): 修改了一下样式
36
- 🎨 chore(模块): 对脚手架做了些更改
37
- 🚨 refactor(模块): 重构(即不是新增功能,也不是修改bug的代码变动)
38
- 🐞 test(模块): 增加、修改测试用例
39
- 🌟 release(3.0.1):url
40
- ```
1
+ # 微服务 3.0 纯净版
2
+
3
+ luck-react-pure 是一个基于 qiankun 框架搭建的极简微服务框架,作为微服务业务子系统的开发基座。旨在为业务子系统提供简单、轻量的解决方案。该框架去除了冗余的功能,专注于提供基本的功能支持,使开发者能够更快速地搭建和开发业务子系统。
4
+
5
+ ## 启动
6
+
7
+ 安装 `node_modules`:
8
+
9
+ ```bash
10
+ pnpm install
11
+ ```
12
+
13
+ ## 开始项目
14
+
15
+ ```bash
16
+ pnpm start
17
+ ```
18
+
19
+ ## 代码校验
20
+
21
+ 本框架提供了代码校验方案,校验不通过禁止提交代码,当提交代码时将会校验以下内容:
22
+
23
+ ### 代码规范
24
+
25
+ 根据 eslint 校验规范。
26
+
27
+ ### commit message 校验
28
+
29
+ commit message 格式:
30
+
31
+ ```bash
32
+ 💥 feat(模块): 添加了个很棒的功能
33
+ 🐛 fix(模块): 修复了一些 bug
34
+ 📝 docs(模块): 更新了一下文档
35
+ 💄 UI(模块): 修改了一下样式
36
+ 🎨 chore(模块): 对脚手架做了些更改
37
+ 🚨 refactor(模块): 重构(即不是新增功能,也不是修改bug的代码变动)
38
+ 🐞 test(模块): 增加、修改测试用例
39
+ 🌟 release(3.0.1):url
40
+ ```
@@ -1,68 +1,68 @@
1
- @spanDefault: #262626;
2
- @spanPrimary: var(--ant-primary-color);
3
- @spanDanger: #ff4d4f;
4
- @spanDestroy: #820014;
5
-
6
- .ldActions {
7
-
8
- button:not(:last-child) {
9
- margin-right: 4px;
10
- }
11
- button:not(:first-child) {
12
- margin-left: 4px;
13
- }
14
- span {
15
- cursor: pointer;
16
- }
17
-
18
- button.default {
19
- background-color: white;
20
- }
21
- span.default {
22
- color: @spanDefault;
23
- }
24
-
25
- button.primary {
26
- background-color: var(--ant-primary-color);
27
- border-color: var(--ant-primary-color);
28
- color: white;
29
- }
30
- span.primary {
31
- color: @spanPrimary;
32
- }
33
-
34
- button.danger {
35
- background-color: #ff4d4f;
36
- border-color: #ff4d4f;
37
- color: white;
38
- }
39
- span.danger {
40
- color: @spanDanger;
41
- }
42
-
43
- button.destroy {
44
- background-color: #820014;
45
- border-color: #820014;
46
- color: white;
47
- }
48
- span.destroy {
49
- color: @spanDestroy;
50
- }
51
-
52
- span.disabled {
53
- color: #bfbfbf;
54
- cursor: not-allowed;
55
- }
56
- }
57
- span.default.menuItem {
58
- color: @spanDefault;
59
- }
60
- span.primary.menuItem {
61
- color: @spanPrimary;
62
- }
63
- span.danger.menuItem {
64
- color: @spanDanger;
65
- }
66
- span.destroy.menuItem {
67
- color: @spanDestroy;
68
- }
1
+ @spanDefault: #262626;
2
+ @spanPrimary: var(--ant-primary-color);
3
+ @spanDanger: #ff4d4f;
4
+ @spanDestroy: #820014;
5
+
6
+ .ldActions {
7
+
8
+ button:not(:last-child) {
9
+ margin-right: 4px;
10
+ }
11
+ button:not(:first-child) {
12
+ margin-left: 4px;
13
+ }
14
+ span {
15
+ cursor: pointer;
16
+ }
17
+
18
+ button.default {
19
+ background-color: white;
20
+ }
21
+ span.default {
22
+ color: @spanDefault;
23
+ }
24
+
25
+ button.primary {
26
+ background-color: var(--ant-primary-color);
27
+ border-color: var(--ant-primary-color);
28
+ color: white;
29
+ }
30
+ span.primary {
31
+ color: @spanPrimary;
32
+ }
33
+
34
+ button.danger {
35
+ background-color: #ff4d4f;
36
+ border-color: #ff4d4f;
37
+ color: white;
38
+ }
39
+ span.danger {
40
+ color: @spanDanger;
41
+ }
42
+
43
+ button.destroy {
44
+ background-color: #820014;
45
+ border-color: #820014;
46
+ color: white;
47
+ }
48
+ span.destroy {
49
+ color: @spanDestroy;
50
+ }
51
+
52
+ span.disabled {
53
+ color: #bfbfbf;
54
+ cursor: not-allowed;
55
+ }
56
+ }
57
+ span.default.menuItem {
58
+ color: @spanDefault;
59
+ }
60
+ span.primary.menuItem {
61
+ color: @spanPrimary;
62
+ }
63
+ span.danger.menuItem {
64
+ color: @spanDanger;
65
+ }
66
+ span.destroy.menuItem {
67
+ color: @spanDestroy;
68
+ }
@@ -4,12 +4,24 @@ import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
4
4
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
5
5
  var _excluded = ["columns", "resources", "actions", "doAction", "ldId", "dataSetKey", "filedsRewrite", "mainFormLdId", "mainDataSetKey", "onValueChange", "onQuery", "onAdd", "onUpdate", "moduleCode", "defaultDataSourceFormat", "ticketData", "relationKey", "fields", "setVerifyRules"];
6
6
  import React, { createRef, useContext } from 'react';
7
- import { reduce, keyBy, isEmpty, pick, union, omit } from 'lodash';
7
+ import { reduce, keyBy, isEmpty, pick, union, omit, forEach, debounce } from 'lodash';
8
8
  import { BasicDivider } from 'luck-design';
9
9
  import { AutoForm } from '@luck-design-biz/base/FormList';
10
10
  import ldBuilder from "../../helper/ldBuilder";
11
11
  import { getFormItem, formItemDataFormat, dataFormat, behaviorCall } from "../../utils";
12
12
  import { LuckDaContext } from "../Builder";
13
+ var didMount = false;
14
+ var debounceFunc = debounce(function (fields, changedValues, allValues, props) {
15
+ forEach(changedValues, function (val, key) {
16
+ var _field$events;
17
+ var field = fields.find(function (f) {
18
+ return f.field === key;
19
+ });
20
+ if (field !== null && field !== void 0 && (_field$events = field.events) !== null && _field$events !== void 0 && _field$events.onValueChange) {
21
+ field.events.onValueChange(val, key, allValues, props);
22
+ }
23
+ });
24
+ }, 300);
13
25
  var buildLdAutoForm = function buildLdAutoForm(_ref) {
14
26
  var _ref$columns = _ref.columns,
15
27
  columns = _ref$columns === void 0 ? [] : _ref$columns,
@@ -130,6 +142,9 @@ var buildLdAutoForm = function buildLdAutoForm(_ref) {
130
142
  });
131
143
  };
132
144
  return /*#__PURE__*/React.createElement(AutoForm, _extends({}, props, {
145
+ onDataLoaded: function onDataLoaded() {
146
+ didMount = true;
147
+ },
133
148
  onQuery: _objectSpread(_objectSpread({
134
149
  api: behaviorCall,
135
150
  get: function get(formData) {
@@ -149,7 +164,14 @@ var buildLdAutoForm = function buildLdAutoForm(_ref) {
149
164
  })
150
165
  // onAdd={onOperate(onAdd, 'add')}
151
166
  ,
152
- onUpdate: onOperate(onUpdate, 'update')
167
+ onUpdate: onOperate(onUpdate, 'update'),
168
+ formOption: {
169
+ onValuesChange: function onValuesChange(props, changedValues, allValues) {
170
+ if (didMount) {
171
+ debounceFunc(fields, changedValues, allValues, props);
172
+ }
173
+ }
174
+ }
153
175
  }, formConfig), basicItems);
154
176
  };
155
177
  export default ldBuilder(buildLdAutoForm);
@@ -6,7 +6,7 @@ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
6
6
  import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
7
7
  import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
8
8
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
9
- var _excluded = ["namespace", "formState", "formMode", "formOperates", "loading", "wrapperRef", "readOnly", "mainFormLdId", "renderFormList", "renderAffixLeft", "renderAffixRight", "beforeSubmit", "showSaveBtn", "saveBtnTitle", "affixLayout", "onValueChange", "afterSubmit", "renderFormExtra", "bpmButtonProps", "setVerifyRules"],
9
+ var _excluded = ["namespace", "formState", "formMode", "formOperates", "loading", "wrapperRef", "readOnly", "mainFormLdId", "renderFormList", "renderAffixLeft", "renderAffixRight", "beforeSubmit", "showSaveBtn", "saveBtnTitle", "affixLayout", "getContainer", "onValueChange", "afterSubmit", "renderFormExtra", "bpmButtonProps", "setVerifyRules"],
10
10
  _excluded2 = ["dataSets", "doAction", "resources"],
11
11
  _excluded3 = ["id", "header", "title", "readOnly", "extraConfig", "renderTopLeft", "serial"],
12
12
  _excluded4 = ["ldId", "initData", "overModel"];
@@ -46,6 +46,7 @@ var LdFormList = function LdFormList(_ref) {
46
46
  showSaveBtn = _ref.showSaveBtn,
47
47
  saveBtnTitle = _ref.saveBtnTitle,
48
48
  affixLayout = _ref.affixLayout,
49
+ getContainer = _ref.getContainer,
49
50
  _ref$onValueChange = _ref.onValueChange,
50
51
  onValueChange = _ref$onValueChange === void 0 ? function () {} : _ref$onValueChange,
51
52
  afterSubmit = _ref.afterSubmit,
@@ -270,7 +271,8 @@ var LdFormList = function LdFormList(_ref) {
270
271
  renderLeft: renderAffixLeft,
271
272
  renderRight: isCustomRenderAffixRight ? renderAffixRightCustom : renderAffixRight,
272
273
  title: saveBtnTitle,
273
- layout: affixLayout || defaultLayout
274
+ layout: affixLayout || defaultLayout,
275
+ getContainer: getContainer
274
276
  }), sortBy([].concat(_toConsumableArray(formList), _toConsumableArray(formExtra)), function (o) {
275
277
  var _o$props;
276
278
  return o.order || ((_o$props = o.props) === null || _o$props === void 0 ? void 0 : _o$props.order);
@@ -96,10 +96,10 @@ var LdGrid = function LdGrid(_ref) {
96
96
  });
97
97
  }, [batchOperations]);
98
98
 
99
- /**
100
- * 优先级
101
- * columnsReset 重置columns,不受模块管理限制,写什么展示什么
102
- * columnsRewrite 覆盖模块管理配置,是否展示以模块管理配置为主,自己可以用hide来隐藏某字段
99
+ /**
100
+ * 优先级
101
+ * columnsReset 重置columns,不受模块管理限制,写什么展示什么
102
+ * columnsRewrite 覆盖模块管理配置,是否展示以模块管理配置为主,自己可以用hide来隐藏某字段
103
103
  */
104
104
  var _columns = useCreation(function () {
105
105
  if (columnsReset) {
@@ -190,10 +190,11 @@ var LdIndex = function LdIndex(_ref2) {
190
190
  var _getDvaApp2, _getDvaApp3;
191
191
  (_getDvaApp2 = getDvaApp()) === null || _getDvaApp2 === void 0 || _getDvaApp2.unmodel(namespace);
192
192
  if (!((_getDvaApp3 = getDvaApp()) !== null && _getDvaApp3 !== void 0 && _getDvaApp3._store.getState()[namespace])) {
193
- var _getDvaApp4;
193
+ var _getDvaApp4, _props$pagination;
194
194
  (_getDvaApp4 = getDvaApp()) === null || _getDvaApp4 === void 0 || _getDvaApp4.model(createModel(namespace, _objectSpread(_objectSpread({
195
195
  behaviorKey: isTreeGrid ? 'readTree' : 'readGrid'
196
196
  }, overModel), {}, {
197
+ pageSize: overModel.pageSize || ((_props$pagination = props.pagination) === null || _props$pagination === void 0 ? void 0 : _props$pagination.pageSize) || props.pageSize,
197
198
  isFlow: isTreeGrid || !!props.isFlow,
198
199
  moduleCode: moduleCode,
199
200
  dataSetKey: props.dataSetKey,
@@ -142,7 +142,11 @@ var buildLdGridForm = function buildLdGridForm(_ref) {
142
142
  var _submitData = data.map(function (item) {
143
143
  return behaviorKey === 'add' ? _objectSpread(_objectSpread({}, dataFormat(gridColumns, item)), {}, _defineProperty({}, window.appConfig.constraintKeys.PRIMARY, null)) : dataFormat(gridColumns, item);
144
144
  });
145
- if (_onOperate !== null && _onOperate !== void 0 && _onOperate.post) return _onOperate.post(_submitData); // 以预设为主
145
+ if (_onOperate !== null && _onOperate !== void 0 && _onOperate.post) return _onOperate.post({
146
+ values: data,
147
+ submitData: _submitData,
148
+ behaviorKey: behaviorKey
149
+ }); // 以预设为主
146
150
  return _defineProperty({}, dataSetKey, _defineProperty({}, "".concat(behaviorKey, "List"), _submitData));
147
151
  }
148
152
  });
@@ -1,7 +1,7 @@
1
- .ldGridForm {
2
- :global {
3
- .ag-layout-auto-height {
4
- height: 100% !important;
5
- }
6
- }
7
- }
1
+ .ldGridForm {
2
+ :global {
3
+ .ag-layout-auto-height {
4
+ height: 100% !important;
5
+ }
6
+ }
7
+ }
@@ -1,19 +1,19 @@
1
- import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
2
1
  import _extends from "@babel/runtime/helpers/esm/extends";
3
2
  import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
3
+ import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
4
4
  import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
5
5
  import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
6
6
  import _objectWithoutProperties from "@babel/runtime/helpers/esm/objectWithoutProperties";
7
7
  var _excluded = ["columns", "resources", "actions", "doAction", "wrapperRef", "ldId", "dataSetKey", "defaultParmas", "moduleCode", "readOnly", "title", "rowKey", "treeNodeTitle", "unselectableNodes", "rightMenus", "defaultExpandDeep", "draggable", "onDrop", "className", "treeClassName", "rootAdd", "suppressInit", "afterQuery", "afterInit", "isTree", "service", "dataToTreeFormat", "boxRef", "doubleClickExpand", "onNodeDoubleClick", "width", "height", "treeNodeCheckable", "treeNodeDisableCheckbox", "treeNodeDisable", "treeNodeIcon", "asyncLoad", "parentKey", "onMount", "onUnmount", "onDataSetChange", "onTreeNodeRender", "onlyRoot"],
8
8
  _excluded2 = ["onClick"];
9
9
  import React, { useState, useRef, useImperativeHandle, forwardRef, useLayoutEffect } from 'react';
10
- import { isFunction, isNumber, transform, includes, remove, cloneDeep, isNil } from 'lodash';
10
+ import { isFunction, isNumber, transform, includes, remove, cloneDeep, isNil, differenceBy } from 'lodash';
11
11
  import { useRequest, useMemoizedFn, useCreation } from 'ahooks';
12
12
  import PropTypes from 'prop-types';
13
13
  import classNames from 'classnames';
14
14
  import { Icon, Popover } from 'luck-design/antd';
15
15
  import { LuckTree } from 'luck-design';
16
- import { formatMessage, dataToTree, dragTreeData } from '@luck-design-biz/base/utils';
16
+ import { formatMessage, dataToTree, dragTreeData, flattenTree } from '@luck-design-biz/base/utils';
17
17
  import { TreeBox } from '@luck-design-biz/base';
18
18
  import ldBuilder from "../../helper/ldBuilder";
19
19
  import { behaviorCall } from "../../utils";
@@ -127,9 +127,32 @@ var LdTree = function LdTree(_ref) {
127
127
  var _params = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
128
128
  run(_objectSpread(_objectSpread(_objectSpread({}, params[0]), _params), defaultParams[0]));
129
129
  });
130
+ var handleUpdateTree = function handleUpdateTree(type, nodes) {
131
+ var data = [];
132
+ var flattenData = flattenTree(dataSource);
133
+ switch (type) {
134
+ case 'delete':
135
+ data = differenceBy(flattenData, nodes, window.appConfig.constraintKeys.PRIMARY);
136
+ break;
137
+ case 'add':
138
+ data = [].concat(_toConsumableArray(flattenData), _toConsumableArray(nodes));
139
+ break;
140
+ default:
141
+ data = flattenData.map(function (i) {
142
+ var findNode = nodes.find(function (n) {
143
+ return n[PRIMARY] === i[PRIMARY];
144
+ });
145
+ if (findNode) return _objectSpread(_objectSpread({}, i), findNode);
146
+ return i;
147
+ });
148
+ }
149
+ var treeData = dataToTreeFormat ? dataToTreeFormat(data) : dataToTree(data, null, window.appConfig.constraintKeys.PRIMARY, window.appConfig.constraintKeys.PARENT);
150
+ setDataSource(treeData);
151
+ };
130
152
  useImperativeHandle(wrapperRef, function () {
131
153
  return _objectSpread(_objectSpread({}, treeRef.current), {}, {
132
- onLdQuery: onLdQuery
154
+ onLdQuery: onLdQuery,
155
+ updateTree: handleUpdateTree
133
156
  });
134
157
  });
135
158
  useLayoutEffect(function () {
@@ -246,7 +269,6 @@ var LdTree = function LdTree(_ref) {
246
269
  }, [readOnly, rootAdd, resources]);
247
270
  var onLoadData = useMemoizedFn(function (treeNode) {
248
271
  return new Promise(function (resolve) {
249
- console.log('treeNode.props.children', treeNode.props.children);
250
272
  if (treeNode.props.isLeaf) {
251
273
  resolve();
252
274
  return;
@@ -1,41 +1,41 @@
1
- .tree {
2
- .nodeTitle {
3
- display: flex;
4
- align-items: center;
5
- width: 100%;
6
- user-select: none;
7
-
8
- div {
9
- flex: 1;
10
- overflow-x: hidden;
11
- white-space: nowrap;
12
- text-overflow: ellipsis;
13
- }
14
-
15
- div.nodeTitleDisabled {
16
- color: var(--luck-text-color-disabled);
17
- }
18
-
19
- div.nodeTitleDisabled:hover {
20
- cursor: not-allowed;
21
- }
22
- }
23
-
24
- :global {
25
- .ant-tree-title {
26
- width: 100%;
27
- }
28
- }
29
- }
30
-
31
- .classTreeOperates {
32
- :global(.ant-popover-inner-content) {
33
- padding: 0;
34
- }
35
-
36
- .rightMenu {
37
- display: block;
38
- padding: 4px 8px;
39
- color: var(--luck-text-color-);
40
- }
1
+ .tree {
2
+ .nodeTitle {
3
+ display: flex;
4
+ align-items: center;
5
+ width: 100%;
6
+ user-select: none;
7
+
8
+ div {
9
+ flex: 1;
10
+ overflow-x: hidden;
11
+ white-space: nowrap;
12
+ text-overflow: ellipsis;
13
+ }
14
+
15
+ div.nodeTitleDisabled {
16
+ color: var(--luck-text-color-disabled);
17
+ }
18
+
19
+ div.nodeTitleDisabled:hover {
20
+ cursor: not-allowed;
21
+ }
22
+ }
23
+
24
+ :global {
25
+ .ant-tree-title {
26
+ width: 100%;
27
+ }
28
+ }
29
+ }
30
+
31
+ .classTreeOperates {
32
+ :global(.ant-popover-inner-content) {
33
+ padding: 0;
34
+ }
35
+
36
+ .rightMenu {
37
+ display: block;
38
+ padding: 4px 8px;
39
+ color: var(--luck-text-color-);
40
+ }
41
41
  }
@@ -7,12 +7,12 @@ import { transform, isArray, startsWith, keyBy } from 'lodash';
7
7
  import { dataFormat, behaviorCall } from "../utils";
8
8
  import { defaultComName } from "./form";
9
9
 
10
- /**
11
- * 提交行为
12
- * @param action 行为
13
- * @param data 数据
14
- * @param parmas 附件设置
15
- * @param moduleData 当前模块信息
10
+ /**
11
+ * 提交行为
12
+ * @param action 行为
13
+ * @param data 数据
14
+ * @param parmas 附件设置
15
+ * @param moduleData 当前模块信息
16
16
  */
17
17
  export var doAction = function doAction(action) {
18
18
  var data = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
package/es/helper/form.js CHANGED
@@ -29,11 +29,11 @@ export var defaultComName = {
29
29
  complex: 'complex'
30
30
  };
31
31
 
32
- /**
33
- * 动态表单配置项转译
34
- * @param {key string} keyStr
35
- * @param {label string} labelStr
36
- * @returns [{key,label}]
32
+ /**
33
+ * 动态表单配置项转译
34
+ * @param {key string} keyStr
35
+ * @param {label string} labelStr
36
+ * @returns [{key,label}]
37
37
  */
38
38
  export var splitStrToObj = function splitStrToObj(keyStr, labelStr) {
39
39
  var keys = keyStr && keyStr.length > 0 ? keyStr.split(',') : undefined;
@@ -50,11 +50,11 @@ export var splitStrToObj = function splitStrToObj(keyStr, labelStr) {
50
50
  return undefined;
51
51
  };
52
52
 
53
- /**
54
- * 动态表单配置项转译
55
- * @param {动态表单配置项} props
56
- * @param {自定义动态表单配置项} customProps
57
- * @returns {name: '',...}
53
+ /**
54
+ * 动态表单配置项转译
55
+ * @param {动态表单配置项} props
56
+ * @param {自定义动态表单配置项} customProps
57
+ * @returns {name: '',...}
58
58
  */
59
59
  export function translator() {
60
60
  var _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
@@ -121,10 +121,10 @@ export function translator() {
121
121
  return _props;
122
122
  }
123
123
 
124
- /**
125
- * 删除自动移操作中的不可覆盖字段
126
- * @param props
127
- * @returns {{multiple}|*}
124
+ /**
125
+ * 删除自动移操作中的不可覆盖字段
126
+ * @param props
127
+ * @returns {{multiple}|*}
128
128
  */
129
129
  export function formatCustomProps(comType, props) {
130
130
  var _props2, _props3;
@@ -138,7 +138,7 @@ export function formatCustomProps(comType, props) {
138
138
  var propsSetting = ((_props_config$comType = props_config[comType]) === null || _props_config$comType === void 0 ? void 0 : _props_config$comType.propsSetting) || [];
139
139
  var propsEvents = ((_props_config$comType2 = props_config[comType]) === null || _props_config$comType2 === void 0 ? void 0 : _props_config$comType2.propsEvents) || [];
140
140
  props = _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, props), pick(setting, propsSetting)), pick(setting.events, propsEvents)), {}, {
141
- config: _objectSpread(_objectSpread(_objectSpread({}, props.config || {}), omit(setting, [].concat(_toConsumableArray(propsSetting), ['events']))), omit(setting.events, propsEvents))
141
+ config: _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, props.config || {}), setting.config || {}), omit(setting, [].concat(_toConsumableArray(propsSetting), ['events']))), omit(setting.events, propsEvents))
142
142
  });
143
143
  }
144
144
  return props;
@@ -1,7 +1,7 @@
1
- .ldLabs{
2
- :global{
3
- .ant-tabs-bar{
4
- margin: 0 0 4px 0;
5
- }
6
- }
7
- }
1
+ .ldLabs{
2
+ :global{
3
+ .ant-tabs-bar{
4
+ margin: 0 0 4px 0;
5
+ }
6
+ }
7
+ }
package/es/index.js CHANGED
@@ -7,5 +7,4 @@ export { default as buildLdGridForm } from "./components/LdGridForm";
7
7
  export { default as LdInfoPanel } from "./components/LdInfoPanel";
8
8
  export { default as LdCard } from "./components/LdCard";
9
9
  export { default as LDActions } from "./components/LDActions";
10
- export { default as LdRuntimeCom } from "./components/LdRuntimeCom";
11
10
  export * from "./components/LdCom";