cnhis-design-vue 3.1.40-beta.12 → 3.1.40-beta.15

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 (404) hide show
  1. package/es/_virtual/plugin-vue_export-helper.js +1 -9
  2. package/es/components/annotation-edit/index.js +1 -10
  3. package/es/components/annotation-edit/src/AnnotationEdit.js +1 -164
  4. package/es/components/big-table/index.js +1 -15
  5. package/es/components/big-table/src/BigTable.vue.js +1 -6
  6. package/es/components/big-table/src/BigTable.vue2.js +1 -2498
  7. package/es/components/big-table/src/bigTableEmits.js +1 -53
  8. package/es/components/big-table/src/bigTableProps.js +1 -120
  9. package/es/components/big-table/src/bigTableState.js +1 -62
  10. package/es/components/big-table/src/components/NoData.vue.js +1 -74
  11. package/es/components/big-table/src/components/edit-form/edit-date.js +1 -214
  12. package/es/components/big-table/src/components/edit-form/edit-input.js +1 -95
  13. package/es/components/big-table/src/components/edit-form/edit-select.js +1 -139
  14. package/es/components/big-table/src/components/edit-form/edit-separate.vue.js +1 -103
  15. package/es/components/big-table/src/components/edit-form/edit-time.js +1 -122
  16. package/es/components/big-table/src/components/edit-form/useCommon.js +1 -23
  17. package/es/components/big-table/src/components/input-button.vue.js +1 -39
  18. package/es/components/big-table/src/components/separate.vue.js +1 -30
  19. package/es/components/big-table/src/constants/index.js +1 -3
  20. package/es/components/big-table/src/hooks/index.js +1 -9
  21. package/es/components/big-table/src/hooks/useAnchor.js +1 -49
  22. package/es/components/big-table/src/hooks/useAnnotation.js +1 -21
  23. package/es/components/big-table/src/hooks/useBatchEditing.js +1 -301
  24. package/es/components/big-table/src/hooks/useEdit.js +1 -133
  25. package/es/components/big-table/src/hooks/useEvent.js +1 -95
  26. package/es/components/big-table/src/hooks/useFormat.js +1 -507
  27. package/es/components/big-table/src/hooks/useNestTable.js +1 -86
  28. package/es/components/big-table/src/hooks/useSeparateRow.js +1 -177
  29. package/es/components/big-table/src/hooks/useTableParse.js +1 -142
  30. package/es/components/big-table/src/utils.js +1 -618
  31. package/es/components/bpmn-workflow/index.js +1 -10
  32. package/es/components/bpmn-workflow/src/BpmnWorkflow.vue.js +1 -258
  33. package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/BpmnRenderer.js +1 -1452
  34. package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/CustomPathMap.js +1 -99
  35. package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRenderer.js +1 -114
  36. package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRules.js +1 -40
  37. package/es/components/bpmn-workflow/src/custom/customOtherModule/customViewerRenderer.js +1 -14
  38. package/es/components/bpmn-workflow/src/custom/customOtherModule/zoomScroll.js +1 -10
  39. package/es/components/button-print/index.js +1 -12
  40. package/es/components/button-print/src/ButtonPrint.vue.js +1 -6
  41. package/es/components/button-print/src/ButtonPrint.vue2.js +1 -528
  42. package/es/components/button-print/src/components/EditFormat.vue.js +1 -173
  43. package/es/components/button-print/src/components/IdentityVerification.vue.js +1 -182
  44. package/es/components/button-print/src/components/Preview.vue.js +1 -6
  45. package/es/components/button-print/src/components/Preview.vue2.js +1 -67
  46. package/es/components/button-print/src/utils/browserPrint.d.ts +2 -1
  47. package/es/components/button-print/src/utils/browserPrint.js +1 -43
  48. package/es/components/button-print/src/utils/dialog.js +1 -121
  49. package/es/components/button-print/src/utils/index.js +1 -2
  50. package/es/components/button-print/src/utils/print.d.ts +5 -1
  51. package/es/components/button-print/src/utils/print.js +1 -432
  52. package/es/components/editor/index.js +1 -10
  53. package/es/components/editor/src/Editor.js +1 -77
  54. package/es/components/fabric-chart/index.js +1 -10
  55. package/es/components/fabric-chart/src/FabricChart.vue.js +1 -71
  56. package/es/components/fabric-chart/src/components/PopupMenu.js +1 -118
  57. package/es/components/fabric-chart/src/components/PopupTip.vue.js +1 -34
  58. package/es/components/fabric-chart/src/components/useStyle.js +1 -36
  59. package/es/components/fabric-chart/src/hooks/constant.js +1 -78
  60. package/es/components/fabric-chart/src/hooks/index.js +1 -11
  61. package/es/components/fabric-chart/src/hooks/useBirthProcess.js +1 -642
  62. package/es/components/fabric-chart/src/hooks/useBirthProcessChart.js +1 -153
  63. package/es/components/fabric-chart/src/hooks/useBottom.js +1 -91
  64. package/es/components/fabric-chart/src/hooks/useCenter.js +1 -734
  65. package/es/components/fabric-chart/src/hooks/useCommon.js +1 -32
  66. package/es/components/fabric-chart/src/hooks/useCumputedPoint.js +1 -79
  67. package/es/components/fabric-chart/src/hooks/useDraw.js +1 -182
  68. package/es/components/fabric-chart/src/hooks/useEvent.js +1 -146
  69. package/es/components/fabric-chart/src/hooks/useGrid.js +1 -54
  70. package/es/components/fabric-chart/src/hooks/useLeft.js +1 -331
  71. package/es/components/fabric-chart/src/hooks/useOther.js +1 -95
  72. package/es/components/fabric-chart/src/hooks/useRight.js +1 -22
  73. package/es/components/fabric-chart/src/hooks/useShadow.js +1 -132
  74. package/es/components/fabric-chart/src/hooks/useTemperatureChart.js +1 -341
  75. package/es/components/fabric-chart/src/hooks/useTop.js +1 -154
  76. package/es/components/fabric-chart/src/utils/index.js +1 -15624
  77. package/es/components/fabric-chart/src/utils/utils.js +1 -32
  78. package/es/components/field-set/index.js +1 -10
  79. package/es/components/field-set/src/FieldSet.vue.js +1 -470
  80. package/es/components/form-config/index.js +1 -10
  81. package/es/components/form-config/src/FormConfig.vue.js +1 -124
  82. package/es/components/form-config/src/components/FormConfigCreator.vue.js +1 -100
  83. package/es/components/form-config/src/components/FormConfigDragDisplay.vue.js +1 -45
  84. package/es/components/form-config/src/components/FormConfigEdit.vue.js +1 -97
  85. package/es/components/form-config/src/components/FormConfigMaterialItem.js +1 -28
  86. package/es/components/form-config/src/components/index.js +1 -6
  87. package/es/components/form-config/src/components/renderer/CloseButton.vue.js +1 -45
  88. package/es/components/form-config/src/components/renderer/ComplexNode.vue.js +1 -45
  89. package/es/components/form-config/src/components/renderer/DefaultNode.vue.js +1 -60
  90. package/es/components/form-config/src/components/renderer/index.js +1 -3
  91. package/es/components/form-config/src/constants/index.js +1 -61
  92. package/es/components/form-config/src/hooks/index.js +1 -3
  93. package/es/components/form-config/src/hooks/useConfigurationField.js +1 -90
  94. package/es/components/form-config/src/hooks/useDataNormalize.js +1 -35
  95. package/es/components/form-config/src/hooks/usePresetRenderer.js +1 -36
  96. package/es/components/form-config/src/hooks/useSortalbeConfig.js +1 -42
  97. package/es/components/form-config/src/utils/index.js +1 -26
  98. package/es/components/form-render/index.js +1 -30
  99. package/es/components/form-render/src/FormRender.vue.js +1 -239
  100. package/es/components/form-render/src/FormRenderWrapper.vue.js +1 -49
  101. package/es/components/form-render/src/components/renderer/combination.js +1 -114
  102. package/es/components/form-render/src/components/renderer/complex.js +1 -37
  103. package/es/components/form-render/src/components/renderer/date.js +1 -171
  104. package/es/components/form-render/src/components/renderer/formItem.js +1 -128
  105. package/es/components/form-render/src/components/renderer/index.js +1 -43
  106. package/es/components/form-render/src/components/renderer/input.js +1 -50
  107. package/es/components/form-render/src/components/renderer/inputGroup.js +1 -11
  108. package/es/components/form-render/src/components/renderer/inputNumber.js +1 -55
  109. package/es/components/form-render/src/components/renderer/jsonCombination/hooks/useDeepValidate.js +1 -35
  110. package/es/components/form-render/src/components/renderer/jsonCombination/index.js +1 -175
  111. package/es/components/form-render/src/components/renderer/levelSearchCascader.js +1 -274
  112. package/es/components/form-render/src/components/renderer/lineBar/FormCollapse.vue.js +1 -71
  113. package/es/components/form-render/src/components/renderer/lineBar/index.js +1 -11
  114. package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -111
  115. package/es/components/form-render/src/components/renderer/remoteSearch.js +1 -139
  116. package/es/components/form-render/src/components/renderer/searchCascade.js +1 -244
  117. package/es/components/form-render/src/components/renderer/select.js +1 -176
  118. package/es/components/form-render/src/components/renderer/simpleComponent.js +1 -57
  119. package/es/components/form-render/src/components/renderer/slider.js +1 -38
  120. package/es/components/form-render/src/components/renderer/switch.js +1 -48
  121. package/es/components/form-render/src/components/renderer/textarea.js +1 -36
  122. package/es/components/form-render/src/components/tooltipMessage.vue.js +1 -37
  123. package/es/components/form-render/src/constants/index.js +1 -59
  124. package/es/components/form-render/src/hooks/index.js +1 -15
  125. package/es/components/form-render/src/hooks/useAnchor.js +1 -99
  126. package/es/components/form-render/src/hooks/useAsyncQueue.js +1 -153
  127. package/es/components/form-render/src/hooks/useAutoHidden.js +1 -43
  128. package/es/components/form-render/src/hooks/useBusinessBinding.js +1 -119
  129. package/es/components/form-render/src/hooks/useChangeContext.js +1 -20
  130. package/es/components/form-render/src/hooks/useCommonInjection.js +1 -43
  131. package/es/components/form-render/src/hooks/useCommonLog.js +1 -12
  132. package/es/components/form-render/src/hooks/useComplexOptions.js +1 -225
  133. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -290
  134. package/es/components/form-render/src/hooks/useFieldNormalize.js +1 -65
  135. package/es/components/form-render/src/hooks/useFieldVisitor.js +1 -46
  136. package/es/components/form-render/src/hooks/useFormContext.js +1 -70
  137. package/es/components/form-render/src/hooks/useFormEvent.js +1 -140
  138. package/es/components/form-render/src/hooks/useFormField.js +1 -13
  139. package/es/components/form-render/src/hooks/useFormItemDeps.js +1 -31
  140. package/es/components/form-render/src/hooks/useFormRenderLifeCycle.js +1 -10
  141. package/es/components/form-render/src/hooks/useFormRenderOptions.js +1 -278
  142. package/es/components/form-render/src/hooks/useFormRequest.js +1 -42
  143. package/es/components/form-render/src/hooks/useFormValidator.js +1 -83
  144. package/es/components/form-render/src/hooks/useLowCodeReactions.js +1 -85
  145. package/es/components/form-render/src/hooks/useNuiThemeOverrides.js +1 -18
  146. package/es/components/form-render/src/hooks/usePresetScope.js +1 -22
  147. package/es/components/form-render/src/types/fieldItem.js +1 -1
  148. package/es/components/form-render/src/types/index.js +1 -1
  149. package/es/components/form-render/src/utils/business.js +1 -114
  150. package/es/components/form-render/src/utils/dom.js +1 -38
  151. package/es/components/form-render/src/utils/index.js +1 -241
  152. package/es/components/form-render/src/utils/schema.js +1 -105
  153. package/es/components/grid/index.js +1 -11
  154. package/es/components/grid/src/Grid.js +1 -28
  155. package/es/components/grid/src/hooks.js +1 -168
  156. package/es/components/iho-table/index.js +1 -36
  157. package/es/components/iho-table/src/IhoTable.vue.js +1 -157
  158. package/es/components/iho-table/src/constants/index.js +1 -157
  159. package/es/components/iho-table/src/hooks/export.js +1 -2
  160. package/es/components/iho-table/src/hooks/index.js +1 -2
  161. package/es/components/iho-table/src/hooks/tapHooks/index.js +1 -159
  162. package/es/components/iho-table/src/hooks/tapHooks/useConfigHooks.js +1 -67
  163. package/es/components/iho-table/src/hooks/tapHooks/useDataHooks.js +1 -26
  164. package/es/components/iho-table/src/hooks/tapHooks/useDomInsertHooks.js +1 -27
  165. package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.js +1 -280
  166. package/es/components/iho-table/src/hooks/tapHooks/useExposeHooks.js +1 -26
  167. package/es/components/iho-table/src/hooks/tapHooks/useFieldHooks.js +1 -38
  168. package/es/components/iho-table/src/hooks/tapHooks/useSetupHooks.js +1 -27
  169. package/es/components/iho-table/src/hooks/useColumnConfigAdaptor.js +1 -164
  170. package/es/components/iho-table/src/hooks/useTableContext.js +1 -17
  171. package/es/components/iho-table/src/hooks/useTablePlugin.js +1 -20
  172. package/es/components/iho-table/src/plugins/anchorPlugin/index.js +1 -19
  173. package/es/components/iho-table/src/plugins/anchorPlugin/tableAnchor.js +1 -51
  174. package/es/components/iho-table/src/plugins/anchorPlugin/useAnchor.js +1 -87
  175. package/es/components/iho-table/src/plugins/defaultConfigPlugin/index.js +1 -48
  176. package/es/components/iho-table/src/plugins/filterPlugin/filter.vue.js +1 -230
  177. package/es/components/iho-table/src/plugins/filterPlugin/index.js +1 -240
  178. package/es/components/iho-table/src/plugins/index.js +1 -47
  179. package/es/components/iho-table/src/plugins/keyboardEventPlugin/index.js +1 -30
  180. package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +1 -127
  181. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.js +1 -203
  182. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/index.js +1 -41
  183. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/hooks/useAutoFocus.js +1 -21
  184. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/inputRendererPlugin.js +1 -41
  185. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/numberRendererPlugin.js +1 -79
  186. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +1 -64
  187. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/index.js +1 -46
  188. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/selectUtils.js +1 -16
  189. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue.js +1 -108
  190. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/index.js +1 -163
  191. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/separateUtils.js +1 -42
  192. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin.js +1 -50
  193. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/checkRendererPlugin.js +1 -30
  194. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/colorRendererPlugin.js +1 -48
  195. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/defaultRendererPlugin.js +1 -62
  196. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/labelRendererPlugin.js +1 -52
  197. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/pictureRendererPlugin.js +1 -92
  198. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/seqRendererPlugin.js +1 -59
  199. package/es/components/iho-table/src/plugins/rowClickPlugin/index.js +1 -34
  200. package/es/components/iho-table/src/plugins/rowGroupSettingPlugin/index.js +1 -30
  201. package/es/components/iho-table/src/plugins/rowGroupSettingPlugin/rowGroupUtils.js +1 -53
  202. package/es/components/iho-table/src/plugins/virtualTreePlugin/index.js +1 -100
  203. package/es/components/iho-table/src/types/index.js +1 -1
  204. package/es/components/iho-table/src/types/pluginType.js +1 -16
  205. package/es/components/iho-table/src/utils/index.js +1 -169
  206. package/es/components/index.js +1 -119
  207. package/es/components/info-header/index.js +1 -10
  208. package/es/components/info-header/src/HiddenContent.vue.js +1 -70
  209. package/es/components/info-header/src/InfoEllipsis.vue.js +1 -43
  210. package/es/components/info-header/src/InfoHeader.vue.js +1 -313
  211. package/es/components/insurance-sdk/index.js +1 -1
  212. package/es/components/insurance-sdk/src/constants/index.js +1 -160
  213. package/es/components/insurance-sdk/src/utils/index.js +1 -1
  214. package/es/components/insurance-sdk/src/utils/insurance.js +1 -268
  215. package/es/components/keyboard/index.js +1 -10
  216. package/es/components/keyboard/src/Keyboard.vue.js +1 -164
  217. package/es/components/keyboard/src/components/InputNumber.vue.js +1 -86
  218. package/es/components/keyboard/src/components/NumberPanel.vue.js +1 -299
  219. package/es/components/keyboard/src/utils/index.js +1 -5
  220. package/es/components/map/index.js +1 -10
  221. package/es/components/map/src/Map.vue.js +1 -336
  222. package/es/components/recommend-search/index.js +1 -10
  223. package/es/components/recommend-search/src/RecommendSearch.vue.js +1 -63
  224. package/es/components/recommend-search/src/components/BaseSearch.vue.js +1 -157
  225. package/es/components/recommend-search/src/components/RecommendInput.vue.js +1 -125
  226. package/es/components/recommend-search/src/components/RecommendMenu.vue.js +1 -104
  227. package/es/components/recommend-search/src/components/RecommendSelect.vue.js +1 -146
  228. package/es/components/recommend-search/src/constant/index.js +1 -7
  229. package/es/components/scale-view/index.js +1 -35
  230. package/es/components/scale-view/src/ScaleView.vue.js +1 -429
  231. package/es/components/scale-view/src/components/AnswerParse.vue.js +1 -80
  232. package/es/components/scale-view/src/components/EvaluateCountdown.vue.js +1 -117
  233. package/es/components/scale-view/src/components/EvaluatePage.vue.js +1 -141
  234. package/es/components/scale-view/src/components/LoadingCom.vue.js +1 -19
  235. package/es/components/scale-view/src/components/NoData.vue.js +1 -74
  236. package/es/components/scale-view/src/components/ScaleScore.js +1 -63
  237. package/es/components/scale-view/src/components/composables/choose-common.js +1 -83
  238. package/es/components/scale-view/src/components/formitem/address.js +1 -3993
  239. package/es/components/scale-view/src/components/formitem/r-address.js +1 -226
  240. package/es/components/scale-view/src/components/formitem/r-cascader.js +1 -133
  241. package/es/components/scale-view/src/components/formitem/r-checkbox.js +1 -281
  242. package/es/components/scale-view/src/components/formitem/r-collection.js +1 -111
  243. package/es/components/scale-view/src/components/formitem/r-datetime.js +1 -212
  244. package/es/components/scale-view/src/components/formitem/r-input.js +1 -86
  245. package/es/components/scale-view/src/components/formitem/r-map.js +1 -106
  246. package/es/components/scale-view/src/components/formitem/r-radio.js +1 -240
  247. package/es/components/scale-view/src/components/formitem/r-select.js +1 -202
  248. package/es/components/scale-view/src/components/formitem/r-sign.js +1 -177
  249. package/es/components/scale-view/src/components/formitem/r-upload.js +1 -215
  250. package/es/components/scale-view/src/components/formitem/sign-com.js +1 -307
  251. package/es/components/scale-view/src/components/formitem/standard-modal.js +1 -129
  252. package/es/components/scale-view/src/hooks/scaleview-computed.js +1 -354
  253. package/es/components/scale-view/src/hooks/scaleview-init.js +1 -437
  254. package/es/components/scale-view/src/hooks/scaleview-props.js +1 -81
  255. package/es/components/scale-view/src/hooks/scaleview-state.js +1 -38
  256. package/es/components/scale-view/src/hooks/scaleview-submit.js +1 -154
  257. package/es/components/scale-view/src/hooks/scaleview-validate.js +1 -187
  258. package/es/components/scale-view/src/hooks/use-component.js +1 -86
  259. package/es/components/scale-view/src/hooks/use-evaluate.js +1 -150
  260. package/es/components/scale-view/src/hooks/use-event.js +1 -129
  261. package/es/components/scale-view/src/hooks/use-noData.js +1 -41
  262. package/es/components/scale-view/src/utils/judge-types.js +1 -36
  263. package/es/components/search-cascader/index.js +1 -10
  264. package/es/components/search-cascader/src/SearchCascader.vue.js +1 -194
  265. package/es/components/search-cascader/src/components/SearchMenu.js +1 -196
  266. package/es/components/search-cascader/src/components/index.js +1 -1
  267. package/es/components/search-cascader/src/constants/index.js +1 -11
  268. package/es/components/search-cascader/src/hooks/index.js +1 -1
  269. package/es/components/search-cascader/src/hooks/useCssVariable.js +1 -7
  270. package/es/components/search-cascader/src/utils/index.js +1 -11
  271. package/es/components/select-label/index.js +1 -15
  272. package/es/components/select-label/src/LabelFormContent.vue.js +1 -447
  273. package/es/components/select-label/src/SelectLabel.vue.js +1 -6
  274. package/es/components/select-label/src/SelectLabel.vue2.js +1 -451
  275. package/es/components/select-label/src/components/label-classify.vue.js +1 -132
  276. package/es/components/select-person/index.js +1 -10
  277. package/es/components/select-person/src/SelectPerson.vue.js +1 -6
  278. package/es/components/select-person/src/SelectPerson.vue2.js +1 -303
  279. package/es/components/select-person/src/utils/index.js +1 -58
  280. package/es/components/shortcut-provider/index.js +1 -12
  281. package/es/components/shortcut-provider/src/ShortcutProvider.vue.js +1 -42
  282. package/es/components/shortcut-provider/src/constants/index.js +1 -8
  283. package/es/components/shortcut-provider/src/hooks/index.js +1 -2
  284. package/es/components/shortcut-provider/src/hooks/useShortcutSignature.js +1 -12
  285. package/es/components/shortcut-provider/src/hooks/useShortcuts.js +1 -188
  286. package/es/components/shortcut-provider/src/utils/index.js +1 -92
  287. package/es/components/shortcut-setter/index.js +1 -10
  288. package/es/components/shortcut-setter/src/ShortcutSetter.vue.js +1 -98
  289. package/es/components/shortcut-setter/src/ShortcutSetterItem.vue.js +1 -76
  290. package/es/components/steps-wheel/index.js +1 -10
  291. package/es/components/steps-wheel/src/StepsWheel.vue.js +1 -376
  292. package/es/components/table-filter/index.js +1 -21
  293. package/es/components/table-filter/src/base-search-com/BaseSearch.vue.js +1 -2272
  294. package/es/components/table-filter/src/classification/Classification-com.vue.js +1 -1315
  295. package/es/components/table-filter/src/classification/search-class-name.vue.js +1 -195
  296. package/es/components/table-filter/src/classification/search-professional-model.vue.js +1 -594
  297. package/es/components/table-filter/src/components/age-com/index.vue.js +1 -185
  298. package/es/components/table-filter/src/components/button-group/ButtonGroup.vue.js +1 -86
  299. package/es/components/table-filter/src/components/button-icon/getBtnIcon.js +1 -30
  300. package/es/components/table-filter/src/components/c-tree-select/tree-select.vue.js +1 -253
  301. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.js +1 -114
  302. package/es/components/table-filter/src/components/classify-filter/helpers/options.js +1 -14
  303. package/es/components/table-filter/src/components/classify-filter/hooks/useDisplayCategory.js +1 -87
  304. package/es/components/table-filter/src/components/classify-filter/hooks/useFilterConditions.js +1 -147
  305. package/es/components/table-filter/src/components/classify-filter/index.vue.js +1 -304
  306. package/es/components/table-filter/src/components/multi-select/multi-select.vue.js +1 -153
  307. package/es/components/table-filter/src/components/out-quick-search/out-quick-search.vue.js +1 -310
  308. package/es/components/table-filter/src/components/range-age/index.vue.js +1 -137
  309. package/es/components/table-filter/src/components/render-widget/components/CheckboxGroup.vue.js +1 -64
  310. package/es/components/table-filter/src/components/render-widget/components/Select.vue.js +1 -45
  311. package/es/components/table-filter/src/components/render-widget/components/index.js +1 -2
  312. package/es/components/table-filter/src/components/render-widget/enums.js +1 -27
  313. package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.js +1 -70
  314. package/es/components/table-filter/src/components/render-widget/index.vue.js +1 -107
  315. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.js +1 -152
  316. package/es/components/table-filter/src/components/search-condition/SearchCondition.vue.js +1 -1520
  317. package/es/components/table-filter/src/components/search-condition/fieldTypeList.js +1 -171
  318. package/es/components/table-filter/src/components/search-filter/SearchFilter.vue.js +1 -199
  319. package/es/components/table-filter/src/components/search-modal/set-classification.vue.js +1 -241
  320. package/es/components/table-filter/src/components/table-modal/TableModal.vue.js +1 -526
  321. package/es/components/table-filter/src/const/dataOptions.js +1 -107
  322. package/es/components/table-filter/src/const/index.js +1 -5
  323. package/es/components/table-filter/src/directive/flexibleResize.js +1 -157
  324. package/es/components/table-filter/src/directive/preventReClick.js +1 -14
  325. package/es/components/table-filter/src/directive/resize.js +1 -12
  326. package/es/components/table-filter/src/hooks/export.js +1 -1
  327. package/es/components/table-filter/src/hooks/useAdvanced.js +1 -64
  328. package/es/components/table-filter/src/hooks/useMixins.js +1 -532
  329. package/es/components/table-filter/src/hooks/useRenderWidget.js +1 -94
  330. package/es/components/table-filter/src/hooks/useTableSearchCon.js +1 -131
  331. package/es/components/table-filter/src/hooks/useWordBookutils.js +1 -91
  332. package/es/components/table-filter/src/quick-search/QuickSearch.vue.js +1 -2038
  333. package/es/components/table-filter/src/tool/generateDefOptions.js +1 -65
  334. package/es/components/table-filter/src/tool/getWidgetType.js +1 -27
  335. package/es/components/table-filter/src/tool/options.js +1 -200
  336. package/es/components/table-filter/src/tool/resizeSensor.js +1 -123
  337. package/es/components/table-filter/src/tool/time-domain.js +1 -100
  338. package/es/components/table-filter/src/tool/transformData.js +1 -169
  339. package/es/components/table-filter/src/tool/utils.js +1 -29
  340. package/es/components/table-filter/src/types/enums.js +1 -67
  341. package/es/components/table-filter/style/index.css +1 -1
  342. package/es/components/time-line/index.js +1 -10
  343. package/es/components/time-line/src/TimeLine.vue.js +1 -70
  344. package/es/components/vod-chunk-upload/index.js +1 -14
  345. package/es/components/vod-chunk-upload/src/chunk-upload-new.vue.js +1 -480
  346. package/es/components/vod-chunk-upload/src/hooks/upload-computed.js +1 -70
  347. package/es/components/vod-chunk-upload/src/hooks/upload-data.js +1 -96
  348. package/es/components/vod-chunk-upload/src/hooks/vod-computed.js +1 -79
  349. package/es/components/vod-chunk-upload/src/hooks/vod-data.js +1 -28
  350. package/es/components/vod-chunk-upload/src/vod-chunk-upload/index.js +1 -2
  351. package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue.js +1 -332
  352. package/es/components/vod-chunk-upload/src/vod-upload-modal.js +1 -94
  353. package/es/shared/assets/img/failure.png.js +1 -3
  354. package/es/shared/assets/img/no-permission.png.js +1 -3
  355. package/es/shared/assets/img/nodata.png.js +1 -3
  356. package/es/shared/assets/img/notfound.png.js +1 -3
  357. package/es/shared/assets/img/qr.png.js +1 -3
  358. package/es/shared/assets/img/success.png.js +1 -3
  359. package/es/shared/assets/img/video.png.js +1 -3
  360. package/es/shared/assets/img/video_default_cover.png.js +1 -3
  361. package/es/shared/assets/img/xb_big.png.js +1 -3
  362. package/es/shared/assets/img/xb_small.png.js +1 -3
  363. package/es/shared/components/SelectPage/SelectPage.vue.js +1 -61
  364. package/es/shared/components/SelectPage/index.js +1 -2
  365. package/es/shared/components/SlotRender/SlotRender.js +1 -35
  366. package/es/shared/components/SlotRender/index.js +1 -2
  367. package/es/shared/components/SvgIcon/SvgIcon.vue.js +1 -36
  368. package/es/shared/components/SvgIcon/index.js +1 -2
  369. package/es/shared/components/TextOverTooltip/TextOverTooltip.vue.js +1 -77
  370. package/es/shared/components/TextOverTooltip/index.js +1 -2
  371. package/es/shared/components/VueDraggable/index.js +1 -2
  372. package/es/shared/components/VueDraggable/src/core/componentBuilderHelper.js +1 -35
  373. package/es/shared/components/VueDraggable/src/core/componentStructure.js +1 -54
  374. package/es/shared/components/VueDraggable/src/core/renderHelper.js +1 -47
  375. package/es/shared/components/VueDraggable/src/core/sortableEvents.js +1 -14
  376. package/es/shared/components/VueDraggable/src/util/console.js +1 -9
  377. package/es/shared/components/VueDraggable/src/util/htmlHelper.js +1 -11
  378. package/es/shared/components/VueDraggable/src/util/string.js +1 -11
  379. package/es/shared/components/VueDraggable/src/util/tags.js +1 -130
  380. package/es/shared/components/VueDraggable/src/vuedraggable.js +1 -265
  381. package/es/shared/components/no-data/NoData.vue.js +1 -74
  382. package/es/shared/components/no-data/index.js +1 -2
  383. package/es/shared/components/player-vod/player.js +1 -121
  384. package/es/shared/components/player-vod/video-modal.js +1 -91
  385. package/es/shared/global/variable.js +1 -3
  386. package/es/shared/utils/anime.js +1 -129
  387. package/es/shared/utils/colorLog.js +1 -53
  388. package/es/shared/utils/index.js +1 -167
  389. package/es/shared/utils/loadViewer.js +1 -11
  390. package/es/shared/utils/tapable/AsyncParallelBailHook.js +1 -63
  391. package/es/shared/utils/tapable/AsyncParallelHook.js +1 -27
  392. package/es/shared/utils/tapable/AsyncSeriesBailHook.js +1 -18
  393. package/es/shared/utils/tapable/AsyncSeriesHook.js +1 -27
  394. package/es/shared/utils/tapable/AsyncSeriesLoopHook.js +1 -12
  395. package/es/shared/utils/tapable/AsyncSeriesWaterfallHook.js +1 -22
  396. package/es/shared/utils/tapable/Hook.js +1 -140
  397. package/es/shared/utils/tapable/HookCodeFactory.js +1 -456
  398. package/es/shared/utils/tapable/SyncBailHook.js +1 -19
  399. package/es/shared/utils/tapable/SyncHook.js +1 -34
  400. package/es/shared/utils/tapable/SyncLoopHook.js +1 -13
  401. package/es/shared/utils/tapable/SyncWaterfallHook.js +1 -47
  402. package/es/shared/utils/utilExpand.js +1 -781
  403. package/es/shared/utils/vexutils.js +1 -59
  404. package/package.json +2 -2
@@ -1,153 +1 @@
1
- import { uuidGenerator } from '../../../../shared/utils/index.js';
2
- import { cloneDeep, isFunction } from 'lodash-es';
3
- import { unref } from 'vue';
4
- import '../../index.js';
5
- import { useCommonLog } from './useCommonLog.js';
6
- import { useFormRequest } from './useFormRequest.js';
7
-
8
- class AsyncQueueEntry {
9
- constructor(item, key, callback) {
10
- this.item = item;
11
- this.key = key;
12
- this.state = 0 /* PENDING */;
13
- this.callback = callback;
14
- }
15
- }
16
- class ArrayQueue {
17
- constructor(items) {
18
- this._list = items ? Array.from(items) : [];
19
- }
20
- enqueue(item) {
21
- this._list.push(item);
22
- }
23
- dequeue() {
24
- return this._list.shift();
25
- }
26
- }
27
- class AsyncQueue {
28
- constructor({ name, processor, getKey, parallelism }) {
29
- this._queued = new ArrayQueue();
30
- this._entries = /* @__PURE__ */ new Map();
31
- this._activeTasks = 0;
32
- this._processingLock = false;
33
- this._stopped = false;
34
- this.name = name;
35
- this.processor = processor;
36
- this.getKey = getKey;
37
- this.parallelism = parallelism || 100;
38
- }
39
- add(item, callback) {
40
- if (this._stopped)
41
- return callback(new Error("Queue was stopped"));
42
- const key = this.getKey(item);
43
- if (this._entries.has(key)) {
44
- const entry = this._entries.get(key);
45
- if (entry.state === 1 /* DONE */) {
46
- setTimeout(() => {
47
- callback && callback(cloneDeep(entry.error), cloneDeep(entry.result));
48
- });
49
- } else if (!entry.callbacks) {
50
- entry.callbacks = [callback];
51
- } else {
52
- entry.callbacks.push(callback);
53
- }
54
- return;
55
- }
56
- const newEntry = new AsyncQueueEntry(item, key, callback);
57
- this._entries.set(key, newEntry);
58
- this._queued.enqueue(newEntry);
59
- if (!this._processingLock) {
60
- this._processingLock = true;
61
- Promise.resolve().then(this._ensureProcessing.bind(this));
62
- }
63
- }
64
- addAsync(item) {
65
- return new Promise((resolve, reject) => {
66
- this.add(item, (err, result) => {
67
- err && reject(err);
68
- resolve(result);
69
- });
70
- });
71
- }
72
- _ensureProcessing() {
73
- while (this._activeTasks < this.parallelism) {
74
- const entry = this._queued.dequeue();
75
- if (!entry)
76
- break;
77
- this._activeTasks++;
78
- entry.state = 0 /* PENDING */;
79
- this._startProcess(entry);
80
- }
81
- this._processingLock = false;
82
- }
83
- _startProcess(entry) {
84
- this.processor(
85
- entry.item,
86
- (e, r) => {
87
- if (e) {
88
- this._handlerResult(entry, e);
89
- return;
90
- }
91
- this._handlerResult(entry, e, r);
92
- },
93
- () => this._entries.delete(entry.key)
94
- );
95
- }
96
- _handlerResult(entry, e, r) {
97
- const callback = entry.callback;
98
- entry.state = 1 /* DONE */;
99
- entry.callback = void 0;
100
- entry.result = cloneDeep(r);
101
- entry.error = cloneDeep(e);
102
- this._activeTasks--;
103
- callback && callback(e, r);
104
- if (entry.callbacks) {
105
- entry.callbacks.forEach((cb) => cb(e, r));
106
- }
107
- if (!this._processingLock) {
108
- this._processingLock = true;
109
- Promise.resolve().then(this._ensureProcessing.bind(this));
110
- }
111
- }
112
- }
113
- function useAsyncQueue(requestInstance) {
114
- const { getHttpInstance } = useFormRequest();
115
- function create(parallelism = 3, option) {
116
- return new AsyncQueue({
117
- name: "FormRenderAsyncQueue",
118
- parallelism,
119
- async processor({ key, method = "post", cache, params, url }, cb, removeCache) {
120
- var _a, _b;
121
- const http = (_a = unref(requestInstance)) != null ? _a : getHttpInstance();
122
- if (!http) {
123
- useCommonLog().invalidHttpInstanceLog();
124
- cb();
125
- removeCache();
126
- return;
127
- }
128
- try {
129
- if (option && isFunction(option.beforeRequest)) {
130
- params = (_b = option.beforeRequest(key, params)) != null ? _b : {};
131
- }
132
- let res = await http[method](url, params);
133
- if (option && isFunction(option.afterRequest)) {
134
- res = option.afterRequest(key, res);
135
- }
136
- cb(void 0, Array.isArray(res) ? res : []);
137
- !cache && removeCache();
138
- } catch (e) {
139
- cb(new Error(`Request error => ${e}`));
140
- removeCache();
141
- }
142
- },
143
- getKey({ url, method = "post", cache, params }) {
144
- if (!cache)
145
- return uuidGenerator();
146
- return url + method + JSON.stringify(params || {});
147
- }
148
- });
149
- }
150
- return { create };
151
- }
152
-
153
- export { AsyncQueue, useAsyncQueue };
1
+ import{uuidGenerator as s}from"../../../../shared/utils/index.js";import{cloneDeep as e,isFunction as t}from"lodash-es";import{unref as r}from"vue";import"../../index.js";import{useCommonLog as i}from"./useCommonLog.js";import{useFormRequest as o}from"./useFormRequest.js";class a{constructor(s,e,t){this.item=s,this.key=e,this.state=0,this.callback=t}}class c{constructor(s){this._list=s?Array.from(s):[]}enqueue(s){this._list.push(s)}dequeue(){return this._list.shift()}}class n{constructor({name:s,processor:e,getKey:t,parallelism:r}){this._queued=new c,this._entries=new Map,this._activeTasks=0,this._processingLock=!1,this._stopped=!1,this.name=s,this.processor=e,this.getKey=t,this.parallelism=r||100}add(s,t){if(this._stopped)return t(new Error("Queue was stopped"));const r=this.getKey(s);if(this._entries.has(r)){const s=this._entries.get(r);return void(1===s.state?setTimeout((()=>{t&&t(e(s.error),e(s.result))})):s.callbacks?s.callbacks.push(t):s.callbacks=[t])}const i=new a(s,r,t);this._entries.set(r,i),this._queued.enqueue(i),this._processingLock||(this._processingLock=!0,Promise.resolve().then(this._ensureProcessing.bind(this)))}addAsync(s){return new Promise(((e,t)=>{this.add(s,((s,r)=>{s&&t(s),e(r)}))}))}_ensureProcessing(){for(;this._activeTasks<this.parallelism;){const s=this._queued.dequeue();if(!s)break;this._activeTasks++,s.state=0,this._startProcess(s)}this._processingLock=!1}_startProcess(s){this.processor(s.item,((e,t)=>{e?this._handlerResult(s,e):this._handlerResult(s,e,t)}),(()=>this._entries.delete(s.key)))}_handlerResult(s,t,r){const i=s.callback;s.state=1,s.callback=void 0,s.result=e(r),s.error=e(t),this._activeTasks--,i&&i(t,r),s.callbacks&&s.callbacks.forEach((s=>s(t,r))),this._processingLock||(this._processingLock=!0,Promise.resolve().then(this._ensureProcessing.bind(this)))}}function h(e){const{getHttpInstance:a}=o();return{create:function(o=3,c){return new n({name:"FormRenderAsyncQueue",parallelism:o,async processor({key:s,method:o="post",cache:n,params:h,url:l},u,p){var m,d;const _=null!=(m=r(e))?m:a();if(!_)return i().invalidHttpInstanceLog(),u(),void p();try{c&&t(c.beforeRequest)&&(h=null!=(d=c.beforeRequest(s,h))?d:{});let e=await _[o](l,h);c&&t(c.afterRequest)&&(e=c.afterRequest(s,e)),u(void 0,Array.isArray(e)?e:[]),!n&&p()}catch(s){u(new Error(`Request error => ${s}`)),p()}},getKey:({url:e,method:t="post",cache:r,params:i})=>r?e+t+JSON.stringify(i||{}):s()})}}}export{n as AsyncQueue,h as useAsyncQueue};
@@ -1,43 +1 @@
1
- import { untracked } from '@formily/reactive';
2
- import { nextTick } from 'vue';
3
-
4
- function useAutoHidden() {
5
- async function trigger(field) {
6
- const fieldDisplay = field.selfDisplay;
7
- untracked(async () => {
8
- if (field.componentType === "LINEBAR") {
9
- await nextTick();
10
- linebarVisibleCheck(field);
11
- } else {
12
- const parent = field.parent;
13
- if (!parent || parent.componentType !== "LINEBAR")
14
- return;
15
- if (fieldDisplay === "visible") {
16
- parent.setDisplay("visible");
17
- } else {
18
- linebarVisibleCheck(parent);
19
- }
20
- }
21
- });
22
- }
23
- return { trigger };
24
- }
25
- async function linebarVisibleCheck(field) {
26
- if (field.selfDisplay === "hidden")
27
- return;
28
- const visible = getChildrenAddress(field).some((address) => {
29
- const targetField = field.form.fields[address];
30
- return targetField && targetField.selfDisplay === "visible";
31
- });
32
- field.setDisplay(visible ? "visible" : "hidden");
33
- }
34
- function getChildrenAddress(field) {
35
- const fieldAddress = field.address.toString();
36
- const addresses = Reflect.get(field.form.query(fieldAddress + ".*"), "addresses");
37
- return addresses.filter((address) => {
38
- const targetField = field.form.fields[address];
39
- return targetField && targetField.address.parent().toString() === fieldAddress;
40
- });
41
- }
42
-
43
- export { useAutoHidden };
1
+ import{untracked as e}from"@formily/reactive";import{nextTick as t}from"vue";function s(){return{trigger:async function(s){const n=s.selfDisplay;e((async()=>{if("LINEBAR"===s.componentType)await t(),i(s);else{const e=s.parent;if(!e||"LINEBAR"!==e.componentType)return;"visible"===n?e.setDisplay("visible"):i(e)}}))}}}async function i(e){if("hidden"===e.selfDisplay)return;const t=function(e){const t=e.address.toString();return Reflect.get(e.form.query(t+".*"),"addresses").filter((s=>{const i=e.form.fields[s];return i&&i.address.parent().toString()===t}))}(e).some((t=>{const s=e.form.fields[t];return s&&"visible"===s.selfDisplay}));e.setDisplay(t?"visible":"hidden")}export{s as useAutoHidden};
@@ -1,119 +1 @@
1
- import { isField } from '@formily/core';
2
- import { isString } from '@vueuse/core';
3
- import { format } from 'date-fns';
4
- import { isFunction, isNumber } from 'lodash-es';
5
- import { FIELD_BUSINESS_TYPE } from '../constants/index.js';
6
- import '../utils/index.js';
7
- import { isIdCard, parseIdCard, parseAgeFromContext, parseBirthday, parseAge2Birthday } from '../utils/business.js';
8
-
9
- class BusinessCollector {
10
- constructor(businessFormatter) {
11
- this.businessFormatter = businessFormatter;
12
- this.typeLockMap = /* @__PURE__ */ new Map();
13
- this.typeCollector = /* @__PURE__ */ new Map();
14
- this.fieldNameCollector = /* @__PURE__ */ new Map();
15
- this.changeHandlerMap = /* @__PURE__ */ new Map([]);
16
- }
17
- formatter(...args) {
18
- return isFunction(this.businessFormatter) ? this.businessFormatter(...args) : args[0].value;
19
- }
20
- collect(type, fieldItem) {
21
- this.typeCollector.set(type, fieldItem);
22
- this.fieldNameCollector.set(fieldItem.val_key, type);
23
- }
24
- getField(type) {
25
- return this.typeCollector.get(type);
26
- }
27
- getFieldInstanceByType(formModel, type) {
28
- const field = this.getField(type);
29
- return field ? formModel.query(field.val_key).take() : null;
30
- }
31
- getType(fieldName) {
32
- return this.fieldNameCollector.get(fieldName);
33
- }
34
- getValueByField(formModel, fieldName) {
35
- const _field = formModel.query(fieldName).take();
36
- return isField(_field) ? _field.value : null;
37
- }
38
- getValueByType(formModel, type) {
39
- const field = this.getField(type);
40
- return field ? this.getValueByField(formModel, field.val_key) : null;
41
- }
42
- setValueByType(formModel, type, value) {
43
- const field = this.getField(type);
44
- field && formModel.setFieldState(field.val_key, (state) => {
45
- if (state.value === value)
46
- return;
47
- const lock = this.typeLockMap.get(type);
48
- this.typeLockMap.set(type, isNumber(lock) ? lock + 1 : 1);
49
- state.value = this.formatter({ value, type, fieldKey: field.val_key });
50
- });
51
- }
52
- registerChangeBusiness(type, handler) {
53
- this.changeHandlerMap.set(type, handler);
54
- return this;
55
- }
56
- trigger(formModel, fieldName, triggerType = "change") {
57
- var _a;
58
- const type = this.getType(fieldName);
59
- if (!type)
60
- return;
61
- if (triggerType === "change" && this.typeLockMap.get(type) > 0) {
62
- return this.typeLockMap.set(type, this.typeLockMap.get(type) - 1);
63
- }
64
- const handler = triggerType === "change" ? this.changeHandlerMap : null;
65
- if (!handler)
66
- return;
67
- (_a = handler.get(type)) == null ? void 0 : _a.call(this, formModel);
68
- }
69
- }
70
- function useBusinessBinding() {
71
- function getBirthdayFormat() {
72
- var _a;
73
- const birthdayField = this.getField(FIELD_BUSINESS_TYPE.BIRTHDAY);
74
- return (_a = birthdayField == null ? void 0 : birthdayField.date_format) != null ? _a : "yyyy-MM-dd HH:mm";
75
- }
76
- function handlerIdCardType(formModel) {
77
- const idCard = this.getValueByType(formModel, FIELD_BUSINESS_TYPE.ID_CARD);
78
- if (!idCard || !isString(idCard) || !isIdCard(idCard)) {
79
- return;
80
- }
81
- const info = parseIdCard(idCard);
82
- const { age, ageUnit } = parseAgeFromContext(info);
83
- this.setValueByType(formModel, FIELD_BUSINESS_TYPE.AGE_UNIT, ageUnit);
84
- this.setValueByType(formModel, FIELD_BUSINESS_TYPE.AGE, age);
85
- this.setValueByType(formModel, FIELD_BUSINESS_TYPE.SEX, info.sex);
86
- this.setValueByType(
87
- formModel,
88
- FIELD_BUSINESS_TYPE.BIRTHDAY,
89
- format(new Date(info.birthday), getBirthdayFormat.call(this))
90
- );
91
- }
92
- function handlerBirthdayType(formModel) {
93
- const birthday = this.getValueByType(formModel, FIELD_BUSINESS_TYPE.BIRTHDAY);
94
- if (!isString(birthday))
95
- return;
96
- const { age, ageUnit } = parseAgeFromContext(parseBirthday(birthday));
97
- this.setValueByType(formModel, FIELD_BUSINESS_TYPE.AGE_UNIT, ageUnit);
98
- this.setValueByType(formModel, FIELD_BUSINESS_TYPE.AGE, age);
99
- }
100
- function handlerAgeType(formModel) {
101
- const age = this.getValueByType(formModel, FIELD_BUSINESS_TYPE.AGE);
102
- const ageUnit = this.getValueByType(formModel, FIELD_BUSINESS_TYPE.AGE_UNIT);
103
- if (!isString(age) && !isNumber(age) || age === "")
104
- return;
105
- if (!isString(ageUnit) || ageUnit === "")
106
- return;
107
- this.setValueByType(
108
- formModel,
109
- FIELD_BUSINESS_TYPE.BIRTHDAY,
110
- parseAge2Birthday(+age, ageUnit, getBirthdayFormat.call(this))
111
- );
112
- }
113
- function create(formatter) {
114
- return new BusinessCollector(formatter).registerChangeBusiness(FIELD_BUSINESS_TYPE.ID_CARD, handlerIdCardType).registerChangeBusiness(FIELD_BUSINESS_TYPE.AGE_UNIT, handlerAgeType).registerChangeBusiness(FIELD_BUSINESS_TYPE.AGE, handlerAgeType).registerChangeBusiness(FIELD_BUSINESS_TYPE.BIRTHDAY, handlerBirthdayType);
115
- }
116
- return { create };
117
- }
118
-
119
- export { BusinessCollector, useBusinessBinding };
1
+ import{isField as e}from"@formily/core";import{isString as t}from"@vueuse/core";import{format as s}from"date-fns";import{isFunction as i,isNumber as r}from"lodash-es";import{FIELD_BUSINESS_TYPE as n}from"../constants/index.js";import"../utils/index.js";import{isIdCard as a,parseIdCard as l,parseAgeFromContext as o,parseBirthday as u,parseAge2Birthday as y}from"../utils/business.js";class h{constructor(e){this.businessFormatter=e,this.typeLockMap=new Map,this.typeCollector=new Map,this.fieldNameCollector=new Map,this.changeHandlerMap=new Map([])}formatter(...e){return i(this.businessFormatter)?this.businessFormatter(...e):e[0].value}collect(e,t){this.typeCollector.set(e,t),this.fieldNameCollector.set(t.val_key,e)}getField(e){return this.typeCollector.get(e)}getFieldInstanceByType(e,t){const s=this.getField(t);return s?e.query(s.val_key).take():null}getType(e){return this.fieldNameCollector.get(e)}getValueByField(t,s){const i=t.query(s).take();return e(i)?i.value:null}getValueByType(e,t){const s=this.getField(t);return s?this.getValueByField(e,s.val_key):null}setValueByType(e,t,s){const i=this.getField(t);i&&e.setFieldState(i.val_key,(e=>{if(e.value===s)return;const n=this.typeLockMap.get(t);this.typeLockMap.set(t,r(n)?n+1:1),e.value=this.formatter({value:s,type:t,fieldKey:i.val_key})}))}registerChangeBusiness(e,t){return this.changeHandlerMap.set(e,t),this}trigger(e,t,s="change"){var i;const r=this.getType(t);if(!r)return;if("change"===s&&this.typeLockMap.get(r)>0)return this.typeLockMap.set(r,this.typeLockMap.get(r)-1);const n="change"===s?this.changeHandlerMap:null;n&&(null==(i=n.get(r))||i.call(this,e))}}function c(){function e(){var e;const t=this.getField(n.BIRTHDAY);return null!=(e=null==t?void 0:t.date_format)?e:"yyyy-MM-dd HH:mm"}function i(i){const r=this.getValueByType(i,n.ID_CARD);if(!r||!t(r)||!a(r))return;const u=l(r),{age:y,ageUnit:h}=o(u);this.setValueByType(i,n.AGE_UNIT,h),this.setValueByType(i,n.AGE,y),this.setValueByType(i,n.SEX,u.sex),this.setValueByType(i,n.BIRTHDAY,s(new Date(u.birthday),e.call(this)))}function c(e){const s=this.getValueByType(e,n.BIRTHDAY);if(!t(s))return;const{age:i,ageUnit:r}=o(u(s));this.setValueByType(e,n.AGE_UNIT,r),this.setValueByType(e,n.AGE,i)}function p(s){const i=this.getValueByType(s,n.AGE),a=this.getValueByType(s,n.AGE_UNIT);(t(i)||r(i))&&""!==i&&t(a)&&""!==a&&this.setValueByType(s,n.BIRTHDAY,y(+i,a,e.call(this)))}return{create:function(e){return new h(e).registerChangeBusiness(n.ID_CARD,i).registerChangeBusiness(n.AGE_UNIT,p).registerChangeBusiness(n.AGE,p).registerChangeBusiness(n.BIRTHDAY,c)}}}export{h as BusinessCollector,c as useBusinessBinding};
@@ -1,20 +1 @@
1
- class ContextCollector {
2
- constructor() {
3
- this.contextMap = /* @__PURE__ */ new Map();
4
- }
5
- setContext(key, value) {
6
- this.contextMap.set(key, value);
7
- }
8
- getContext(key, value) {
9
- var _a;
10
- return (_a = this.contextMap.get(key)) == null ? void 0 : _a(value);
11
- }
12
- }
13
- function useChangeContext() {
14
- function create() {
15
- return new ContextCollector();
16
- }
17
- return { create };
18
- }
19
-
20
- export { ContextCollector, useChangeContext };
1
+ class t{constructor(){this.contextMap=new Map}setContext(t,e){this.contextMap.set(t,e)}getContext(t,e){var n;return null==(n=this.contextMap.get(t))?void 0:n(e)}}function e(){return{create:function(){return new t}}}export{t as ContextCollector,e as useChangeContext};
@@ -1,43 +1 @@
1
- import { isField } from '@formily/core';
2
- import { watch, ref } from 'vue';
3
- import '../../index.js';
4
- import { useFormField } from './useFormField.js';
5
-
6
- function useCommonInjection() {
7
- function injectValueValidate(traverser) {
8
- const { field } = useFormField();
9
- watch(traverser, () => {
10
- var _a, _b, _c;
11
- try {
12
- if (!isField(field.value))
13
- return;
14
- if (!field.value.visited && !((_a = field.value.selfErrors) == null ? void 0 : _a.length))
15
- return;
16
- (_c = (_b = field.value).validate) == null ? void 0 : _c.call(_b);
17
- } catch (e) {
18
- }
19
- });
20
- }
21
- function injectValueWatchFromEmpty(traverser, trigger) {
22
- watch(traverser, (n, o) => n != null && o == null && trigger(), { immediate: true });
23
- }
24
- function injectValueBindKey(traverser) {
25
- const key = ref(1);
26
- watch(traverser, (n, o) => {
27
- if (n === void 0 && o !== void 0) {
28
- key.value++;
29
- }
30
- });
31
- return key;
32
- }
33
- return { injectValueValidate, injectValueWatchFromEmpty, injectValueBindKey };
34
- }
35
- function useSelectOptionProps() {
36
- const nodeProps = () => {
37
- return { class: "form-render__selectOption" };
38
- };
39
- const menuProps = { class: "form-render__selectMenu" };
40
- return { nodeProps, menuProps };
41
- }
42
-
43
- export { useCommonInjection, useSelectOptionProps };
1
+ import{isField as e}from"@formily/core";import{watch as r,ref as n}from"vue";import"../../index.js";import{useFormField as t}from"./useFormField.js";function i(){return{injectValueValidate:function(n){const{field:i}=t();r(n,(()=>{var r,n,t;try{if(!e(i.value))return;if(!i.value.visited&&!(null==(r=i.value.selfErrors)?void 0:r.length))return;null==(t=(n=i.value).validate)||t.call(n)}catch(e){}}))},injectValueWatchFromEmpty:function(e,n){r(e,((e,r)=>null!=e&&null==r&&n()),{immediate:!0})},injectValueBindKey:function(e){const t=n(1);return r(e,((e,r)=>{void 0===e&&void 0!==r&&t.value++})),t}}}function l(){return{nodeProps:()=>({class:"form-render__selectOption"}),menuProps:{class:"form-render__selectMenu"}}}export{i as useCommonInjection,l as useSelectOptionProps};
@@ -1,12 +1 @@
1
- import { formRenderLog } from '../utils/index.js';
2
-
3
- function useCommonLog() {
4
- function invalidHttpInstanceLog() {
5
- formRenderLog(
6
- "before use http feature, you should regist http instance by useFormilyRequest.registGlobHttpInstance()"
7
- );
8
- }
9
- return { invalidHttpInstanceLog };
10
- }
11
-
12
- export { useCommonLog };
1
+ import{formRenderLog as t}from"../utils/index.js";function e(){return{invalidHttpInstanceLog:function(){t("before use http feature, you should regist http instance by useFormilyRequest.registGlobHttpInstance()")}}}export{e as useCommonLog};
@@ -1,225 +1 @@
1
- import { reactive, defineComponent, inject, computed, watch, onUnmounted, onMounted, createVNode, withModifiers, ref } from 'vue';
2
- import { checkInSetupEnv, jsonParse } from '../../../../shared/utils/index.js';
3
- import { RecursionField } from '@formily/vue';
4
- import { sumBy, property, noop, isObject, isArray, isString, cloneDeep, isNumber } from 'lodash-es';
5
- import '../../index.js';
6
- import { InjectionFormUUID, InjectionBusinessCollector } from '../constants/index.js';
7
- import { useFormField } from './useFormField.js';
8
- import { useFieldListAdaptor } from './useFieldListAdaptor.js';
9
- import { createObjSchema } from '../utils/schema.js';
10
-
11
- const spanMap = reactive(/* @__PURE__ */ new Map());
12
- function setSpan(uuid, address, span = 0) {
13
- spanMap.set(uuid, spanMap.get(uuid) || {});
14
- const spanObj = spanMap.get(uuid);
15
- spanObj[address + ""] = span;
16
- }
17
- function getSpan(uuid, address) {
18
- const spanObj = spanMap.get(uuid);
19
- if (!spanObj)
20
- return 0;
21
- return Object.entries(spanObj).reduce((res, [k, v]) => {
22
- if (k === address + "" || k.startsWith(`${address}.`))
23
- return res + v;
24
- return res;
25
- }, 0);
26
- }
27
- function deleteSpan(uuid, address) {
28
- const spanObj = spanMap.get(uuid);
29
- spanObj && Reflect.deleteProperty(spanObj, address + "");
30
- }
31
- function clearSpan(uuid) {
32
- spanMap.delete(uuid);
33
- }
34
- const ChildSchemaField = defineComponent({
35
- props: {
36
- fields: {
37
- type: Array,
38
- default: () => []
39
- },
40
- name: {
41
- type: String,
42
- required: true
43
- }
44
- },
45
- setup(props) {
46
- const uuid = inject(InjectionFormUUID);
47
- const {
48
- field
49
- } = useFormField();
50
- const collector = inject(InjectionBusinessCollector);
51
- const {
52
- schemaAdaptor
53
- } = useFieldListAdaptor(collector);
54
- function assignConfig(schema2) {
55
- return Object.assign(schema2, {
56
- ["x-decorator-props"]: {
57
- ...schema2["x-decorator-props"],
58
- labelPlacement: "left",
59
- showFeedback: false,
60
- showLabel: !!schema2.title
61
- },
62
- ["x-component-props"]: {
63
- ...schema2["x-component-props"],
64
- size: "small"
65
- }
66
- });
67
- }
68
- const schema = computed(() => {
69
- const schemaProperty = schemaAdaptor(props.fields);
70
- Object.values(schemaProperty).forEach(assignConfig);
71
- return createObjSchema(schemaProperty);
72
- });
73
- const column = computed(() => {
74
- return sumBy(Object.values(schema.value.properties || []), property("x-decorator-props.span"));
75
- });
76
- const fieldKey = computed(() => `${field.value.address.toString()}.${props.name}`);
77
- watch(column, (_column) => {
78
- setSpan(uuid, fieldKey.value, _column);
79
- }, {
80
- immediate: true
81
- });
82
- function getRecursionField() {
83
- const formModel = field.value.form;
84
- return formModel.query(fieldKey.value).take();
85
- }
86
- onUnmounted(() => {
87
- const recursionField = getRecursionField();
88
- recursionField && (recursionField.display = "none");
89
- deleteSpan(uuid, fieldKey.value);
90
- });
91
- onMounted(() => {
92
- const recursionField = getRecursionField();
93
- if (!recursionField)
94
- return;
95
- recursionField.display = "visible";
96
- });
97
- return () => createVNode("section", {
98
- "onClick": withModifiers(noop, ["stop"]),
99
- "class": "form-render__labelField",
100
- "style": {
101
- "--column": getSpan(uuid, fieldKey.value)
102
- }
103
- }, [createVNode(RecursionField, {
104
- "name": props.name,
105
- "schema": schema.value
106
- }, null)]);
107
- }
108
- });
109
- function isComplexOption(options) {
110
- return options.some((option) => {
111
- return isArray(option.childrenFields) && option.childrenFields.length;
112
- });
113
- }
114
- function useComplexOptions(props, emit) {
115
- checkInSetupEnv();
116
- const {
117
- fieldKey
118
- } = useFormField();
119
- const hasComplexOption = computed(() => isComplexOption(props.options));
120
- function dangerousTypeTransform(value) {
121
- if (isNumber(value))
122
- return value + "";
123
- return value;
124
- }
125
- const checkValueRef = ref();
126
- const valueRef = computed({
127
- get() {
128
- return dangerousTypeTransform(hasComplexOption.value ? checkValueRef.value : props.value);
129
- },
130
- set(value) {
131
- if (!hasComplexOption.value)
132
- return emit("update:value", value);
133
- if (!isObject(props.value))
134
- return;
135
- props.value[fieldKey.value] = value;
136
- checkValueRef.value = value;
137
- }
138
- });
139
- watch(checkValueRef, () => {
140
- if (!hasComplexOption.value || !isObject(props.value))
141
- return;
142
- props.value[fieldKey.value] = checkValueRef.value;
143
- });
144
- watch([() => props.value, hasComplexOption], ([v, _has]) => {
145
- if (!_has)
146
- return;
147
- if (isArray(v)) {
148
- checkValueRef.value = v;
149
- return emit("update:value", {
150
- [fieldKey.value]: v
151
- });
152
- }
153
- if (isString(v)) {
154
- if (v.startsWith("{")) {
155
- const result = cloneDeep(jsonParse(v));
156
- checkValueRef.value = result[fieldKey.value];
157
- return emit("update:value", result);
158
- }
159
- checkValueRef.value = v;
160
- return emit("update:value", {
161
- [fieldKey.value]: v
162
- });
163
- }
164
- if (!isObject(v)) {
165
- checkValueRef.value = void 0;
166
- emit("update:value", {});
167
- } else {
168
- checkValueRef.value = v[fieldKey.value];
169
- }
170
- }, {
171
- immediate: true
172
- });
173
- function valueMatcher(value, option, valueKey = "value") {
174
- if (isArray(value) ? !value.includes(option[valueKey]) : value !== option[valueKey])
175
- return;
176
- return isArray(option.childrenFields) && option.childrenFields.length;
177
- }
178
- function renderComplexOption({
179
- value,
180
- option,
181
- valueKey = "value",
182
- labelKey = "label"
183
- }) {
184
- return [option[labelKey], hasComplexOption.value && valueMatcher(value, option, valueKey) ? createVNode(ChildSchemaField, {
185
- "fields": option.childrenFields,
186
- "name": option[valueKey]
187
- }, null) : null];
188
- }
189
- return {
190
- renderComplexOption,
191
- valueRef,
192
- hasComplexOption,
193
- checkValueRef
194
- };
195
- }
196
- function useComplexOptionsSpan() {
197
- return {
198
- getSpan,
199
- setSpan,
200
- deleteSpan,
201
- clearSpan
202
- };
203
- }
204
- function useComplexOptionsKey() {
205
- function combineComplexOptionKey(fieldList, values) {
206
- const fieldMap = fieldList.reduce((res, field) => {
207
- res[field.val_key] = field;
208
- return res;
209
- }, {});
210
- return Object.entries(values).reduce((res, [k, v]) => {
211
- const field = fieldMap[k];
212
- if (field && isArray(field.option) && isComplexOption(field.option)) {
213
- res[k] = JSON.stringify(v);
214
- } else {
215
- res[k] = v;
216
- }
217
- return res;
218
- }, {});
219
- }
220
- return {
221
- combineComplexOptionKey
222
- };
223
- }
224
-
225
- export { useComplexOptions, useComplexOptionsKey, useComplexOptionsSpan };
1
+ import{reactive as e,defineComponent as t,inject as n,computed as l,watch as r,onUnmounted as u,onMounted as a,createVNode as o,withModifiers as i,ref as s}from"vue";import{checkInSetupEnv as c,jsonParse as p}from"../../../../shared/utils/index.js";import{RecursionField as d}from"@formily/vue";import{sumBy as v,property as m,noop as f,isObject as h,isArray as y,isString as b,cloneDeep as g,isNumber as x}from"lodash-es";import"../../index.js";import{InjectionFormUUID as j,InjectionBusinessCollector as F}from"../constants/index.js";import{useFormField as O}from"./useFormField.js";import{useFieldListAdaptor as S}from"./useFieldListAdaptor.js";import{createObjSchema as k}from"../utils/schema.js";const C=e(new Map);function K(e,t,n=0){C.set(e,C.get(e)||{});C.get(e)[t+""]=n}function w(e,t){const n=C.get(e);return n?Object.entries(n).reduce(((e,[n,l])=>n===t+""||n.startsWith(`${t}.`)?e+l:e),0):0}function A(e,t){const n=C.get(e);n&&Reflect.deleteProperty(n,t+"")}function R(e){C.delete(e)}const $=t({props:{fields:{type:Array,default:()=>[]},name:{type:String,required:!0}},setup(e){const t=n(j),{field:s}=O(),c=n(F),{schemaAdaptor:p}=S(c);function h(e){return Object.assign(e,{"x-decorator-props":{...e["x-decorator-props"],labelPlacement:"left",showFeedback:!1,showLabel:!!e.title},"x-component-props":{...e["x-component-props"],size:"small"}})}const y=l((()=>{const t=p(e.fields);return Object.values(t).forEach(h),k(t)})),b=l((()=>v(Object.values(y.value.properties||[]),m("x-decorator-props.span")))),g=l((()=>`${s.value.address.toString()}.${e.name}`));function x(){return s.value.form.query(g.value).take()}return r(b,(e=>{K(t,g.value,e)}),{immediate:!0}),u((()=>{const e=x();e&&(e.display="none"),A(t,g.value)})),a((()=>{const e=x();e&&(e.display="visible")})),()=>o("section",{onClick:i(f,["stop"]),class:"form-render__labelField",style:{"--column":w(t,g.value)}},[o(d,{name:e.name,schema:y.value},null)])}});function _(e){return e.some((e=>y(e.childrenFields)&&e.childrenFields.length))}function q(e,t){c();const{fieldKey:n}=O(),u=l((()=>_(e.options)));const a=s(),i=l({get(){return t=u.value?a.value:e.value,x(t)?t+"":t;var t},set(l){if(!u.value)return t("update:value",l);h(e.value)&&(e.value[n.value]=l,a.value=l)}});function d(e,t,n="value"){if(y(e)?e.includes(t[n]):e===t[n])return y(t.childrenFields)&&t.childrenFields.length}return r(a,(()=>{u.value&&h(e.value)&&(e.value[n.value]=a.value)})),r([()=>e.value,u],(([e,l])=>{if(l){if(y(e))return a.value=e,t("update:value",{[n.value]:e});if(b(e)){if(e.startsWith("{")){const l=g(p(e));return a.value=l[n.value],t("update:value",l)}return a.value=e,t("update:value",{[n.value]:e})}h(e)?a.value=e[n.value]:(a.value=void 0,t("update:value",{}))}}),{immediate:!0}),{renderComplexOption:function({value:e,option:t,valueKey:n="value",labelKey:l="label"}){return[t[l],u.value&&d(e,t,n)?o($,{fields:t.childrenFields,name:t[n]},null):null]},valueRef:i,hasComplexOption:u,checkValueRef:a}}function L(){return{getSpan:w,setSpan:K,deleteSpan:A,clearSpan:R}}function P(){return{combineComplexOptionKey:function(e,t){const n=e.reduce(((e,t)=>(e[t.val_key]=t,e)),{});return Object.entries(t).reduce(((e,[t,l])=>{const r=n[t];return r&&y(r.option)&&_(r.option)?e[t]=JSON.stringify(l):e[t]=l,e}),{})}}}export{q as useComplexOptions,P as useComplexOptionsKey,L as useComplexOptionsSpan};