cnhis-design-vue 3.1.40-beta.12 → 3.1.40-beta.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/_virtual/plugin-vue_export-helper.js +1 -9
- package/es/components/annotation-edit/index.js +1 -10
- package/es/components/annotation-edit/src/AnnotationEdit.js +1 -164
- package/es/components/big-table/index.js +1 -15
- package/es/components/big-table/src/BigTable.vue.js +1 -6
- package/es/components/big-table/src/BigTable.vue2.js +1 -2498
- package/es/components/big-table/src/bigTableEmits.js +1 -53
- package/es/components/big-table/src/bigTableProps.js +1 -120
- package/es/components/big-table/src/bigTableState.js +1 -62
- package/es/components/big-table/src/components/NoData.vue.js +1 -74
- package/es/components/big-table/src/components/edit-form/edit-date.js +1 -214
- package/es/components/big-table/src/components/edit-form/edit-input.js +1 -95
- package/es/components/big-table/src/components/edit-form/edit-select.js +1 -139
- package/es/components/big-table/src/components/edit-form/edit-separate.vue.js +1 -103
- package/es/components/big-table/src/components/edit-form/edit-time.js +1 -122
- package/es/components/big-table/src/components/edit-form/useCommon.js +1 -23
- package/es/components/big-table/src/components/input-button.vue.js +1 -39
- package/es/components/big-table/src/components/separate.vue.js +1 -30
- package/es/components/big-table/src/constants/index.js +1 -3
- package/es/components/big-table/src/hooks/index.js +1 -9
- package/es/components/big-table/src/hooks/useAnchor.js +1 -49
- package/es/components/big-table/src/hooks/useAnnotation.js +1 -21
- package/es/components/big-table/src/hooks/useBatchEditing.js +1 -301
- package/es/components/big-table/src/hooks/useEdit.js +1 -133
- package/es/components/big-table/src/hooks/useEvent.js +1 -95
- package/es/components/big-table/src/hooks/useFormat.js +1 -507
- package/es/components/big-table/src/hooks/useNestTable.js +1 -86
- package/es/components/big-table/src/hooks/useSeparateRow.js +1 -177
- package/es/components/big-table/src/hooks/useTableParse.js +1 -142
- package/es/components/big-table/src/utils.js +1 -618
- package/es/components/bpmn-workflow/index.js +1 -10
- package/es/components/bpmn-workflow/src/BpmnWorkflow.vue.js +1 -258
- package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/BpmnRenderer.js +1 -1452
- package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/CustomPathMap.js +1 -99
- package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRenderer.js +1 -114
- package/es/components/bpmn-workflow/src/custom/customModeler/customBpmn/CustomRules.js +1 -40
- package/es/components/bpmn-workflow/src/custom/customOtherModule/customViewerRenderer.js +1 -14
- package/es/components/bpmn-workflow/src/custom/customOtherModule/zoomScroll.js +1 -10
- package/es/components/button-print/index.js +1 -12
- package/es/components/button-print/src/ButtonPrint.vue.js +1 -6
- package/es/components/button-print/src/ButtonPrint.vue2.js +1 -528
- package/es/components/button-print/src/components/EditFormat.vue.js +1 -173
- package/es/components/button-print/src/components/IdentityVerification.vue.js +1 -182
- package/es/components/button-print/src/components/Preview.vue.js +1 -6
- package/es/components/button-print/src/components/Preview.vue2.js +1 -67
- package/es/components/button-print/src/utils/browserPrint.d.ts +2 -1
- package/es/components/button-print/src/utils/browserPrint.js +1 -43
- package/es/components/button-print/src/utils/dialog.js +1 -121
- package/es/components/button-print/src/utils/index.js +1 -2
- package/es/components/button-print/src/utils/print.d.ts +5 -1
- package/es/components/button-print/src/utils/print.js +1 -432
- package/es/components/editor/index.js +1 -10
- package/es/components/editor/src/Editor.js +1 -77
- package/es/components/fabric-chart/index.js +1 -10
- package/es/components/fabric-chart/src/FabricChart.vue.js +1 -71
- package/es/components/fabric-chart/src/components/PopupMenu.js +1 -118
- package/es/components/fabric-chart/src/components/PopupTip.vue.js +1 -34
- package/es/components/fabric-chart/src/components/useStyle.js +1 -36
- package/es/components/fabric-chart/src/hooks/constant.js +1 -78
- package/es/components/fabric-chart/src/hooks/index.js +1 -11
- package/es/components/fabric-chart/src/hooks/useBirthProcess.js +1 -642
- package/es/components/fabric-chart/src/hooks/useBirthProcessChart.js +1 -153
- package/es/components/fabric-chart/src/hooks/useBottom.js +1 -91
- package/es/components/fabric-chart/src/hooks/useCenter.js +1 -734
- package/es/components/fabric-chart/src/hooks/useCommon.js +1 -32
- package/es/components/fabric-chart/src/hooks/useCumputedPoint.js +1 -79
- package/es/components/fabric-chart/src/hooks/useDraw.js +1 -182
- package/es/components/fabric-chart/src/hooks/useEvent.js +1 -146
- package/es/components/fabric-chart/src/hooks/useGrid.js +1 -54
- package/es/components/fabric-chart/src/hooks/useLeft.js +1 -331
- package/es/components/fabric-chart/src/hooks/useOther.js +1 -95
- package/es/components/fabric-chart/src/hooks/useRight.js +1 -22
- package/es/components/fabric-chart/src/hooks/useShadow.js +1 -132
- package/es/components/fabric-chart/src/hooks/useTemperatureChart.js +1 -341
- package/es/components/fabric-chart/src/hooks/useTop.js +1 -154
- package/es/components/fabric-chart/src/utils/index.js +1 -15624
- package/es/components/fabric-chart/src/utils/utils.js +1 -32
- package/es/components/field-set/index.js +1 -10
- package/es/components/field-set/src/FieldSet.vue.js +1 -470
- package/es/components/form-config/index.js +1 -10
- package/es/components/form-config/src/FormConfig.vue.js +1 -124
- package/es/components/form-config/src/components/FormConfigCreator.vue.js +1 -100
- package/es/components/form-config/src/components/FormConfigDragDisplay.vue.js +1 -45
- package/es/components/form-config/src/components/FormConfigEdit.vue.js +1 -97
- package/es/components/form-config/src/components/FormConfigMaterialItem.js +1 -28
- package/es/components/form-config/src/components/index.js +1 -6
- package/es/components/form-config/src/components/renderer/CloseButton.vue.js +1 -45
- package/es/components/form-config/src/components/renderer/ComplexNode.vue.js +1 -45
- package/es/components/form-config/src/components/renderer/DefaultNode.vue.js +1 -60
- package/es/components/form-config/src/components/renderer/index.js +1 -3
- package/es/components/form-config/src/constants/index.js +1 -61
- package/es/components/form-config/src/hooks/index.js +1 -3
- package/es/components/form-config/src/hooks/useConfigurationField.js +1 -90
- package/es/components/form-config/src/hooks/useDataNormalize.js +1 -35
- package/es/components/form-config/src/hooks/usePresetRenderer.js +1 -36
- package/es/components/form-config/src/hooks/useSortalbeConfig.js +1 -42
- package/es/components/form-config/src/utils/index.js +1 -26
- package/es/components/form-render/index.js +1 -30
- package/es/components/form-render/src/FormRender.vue.js +1 -239
- package/es/components/form-render/src/FormRenderWrapper.vue.js +1 -49
- package/es/components/form-render/src/components/renderer/combination.js +1 -114
- package/es/components/form-render/src/components/renderer/complex.js +1 -37
- package/es/components/form-render/src/components/renderer/date.js +1 -171
- package/es/components/form-render/src/components/renderer/formItem.js +1 -128
- package/es/components/form-render/src/components/renderer/index.js +1 -43
- package/es/components/form-render/src/components/renderer/input.js +1 -50
- package/es/components/form-render/src/components/renderer/inputGroup.js +1 -11
- package/es/components/form-render/src/components/renderer/inputNumber.js +1 -55
- package/es/components/form-render/src/components/renderer/jsonCombination/hooks/useDeepValidate.js +1 -35
- package/es/components/form-render/src/components/renderer/jsonCombination/index.js +1 -175
- package/es/components/form-render/src/components/renderer/levelSearchCascader.js +1 -274
- package/es/components/form-render/src/components/renderer/lineBar/FormCollapse.vue.js +1 -71
- package/es/components/form-render/src/components/renderer/lineBar/index.js +1 -11
- package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -111
- package/es/components/form-render/src/components/renderer/remoteSearch.js +1 -139
- package/es/components/form-render/src/components/renderer/searchCascade.js +1 -244
- package/es/components/form-render/src/components/renderer/select.js +1 -176
- package/es/components/form-render/src/components/renderer/simpleComponent.js +1 -57
- package/es/components/form-render/src/components/renderer/slider.js +1 -38
- package/es/components/form-render/src/components/renderer/switch.js +1 -48
- package/es/components/form-render/src/components/renderer/textarea.js +1 -36
- package/es/components/form-render/src/components/tooltipMessage.vue.js +1 -37
- package/es/components/form-render/src/constants/index.js +1 -59
- package/es/components/form-render/src/hooks/index.js +1 -15
- package/es/components/form-render/src/hooks/useAnchor.js +1 -99
- package/es/components/form-render/src/hooks/useAsyncQueue.js +1 -153
- package/es/components/form-render/src/hooks/useAutoHidden.js +1 -43
- package/es/components/form-render/src/hooks/useBusinessBinding.js +1 -119
- package/es/components/form-render/src/hooks/useChangeContext.js +1 -20
- package/es/components/form-render/src/hooks/useCommonInjection.js +1 -43
- package/es/components/form-render/src/hooks/useCommonLog.js +1 -12
- package/es/components/form-render/src/hooks/useComplexOptions.js +1 -225
- package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -290
- package/es/components/form-render/src/hooks/useFieldNormalize.js +1 -65
- package/es/components/form-render/src/hooks/useFieldVisitor.js +1 -46
- package/es/components/form-render/src/hooks/useFormContext.js +1 -70
- package/es/components/form-render/src/hooks/useFormEvent.js +1 -140
- package/es/components/form-render/src/hooks/useFormField.js +1 -13
- package/es/components/form-render/src/hooks/useFormItemDeps.js +1 -31
- package/es/components/form-render/src/hooks/useFormRenderLifeCycle.js +1 -10
- package/es/components/form-render/src/hooks/useFormRenderOptions.js +1 -278
- package/es/components/form-render/src/hooks/useFormRequest.js +1 -42
- package/es/components/form-render/src/hooks/useFormValidator.js +1 -83
- package/es/components/form-render/src/hooks/useLowCodeReactions.js +1 -85
- package/es/components/form-render/src/hooks/useNuiThemeOverrides.js +1 -18
- package/es/components/form-render/src/hooks/usePresetScope.js +1 -22
- package/es/components/form-render/src/types/fieldItem.js +1 -1
- package/es/components/form-render/src/types/index.js +1 -1
- package/es/components/form-render/src/utils/business.js +1 -114
- package/es/components/form-render/src/utils/dom.js +1 -38
- package/es/components/form-render/src/utils/index.js +1 -241
- package/es/components/form-render/src/utils/schema.js +1 -105
- package/es/components/grid/index.js +1 -11
- package/es/components/grid/src/Grid.js +1 -28
- package/es/components/grid/src/hooks.js +1 -168
- package/es/components/iho-table/index.js +1 -36
- package/es/components/iho-table/src/IhoTable.vue.js +1 -157
- package/es/components/iho-table/src/constants/index.js +1 -157
- package/es/components/iho-table/src/hooks/export.js +1 -2
- package/es/components/iho-table/src/hooks/index.js +1 -2
- package/es/components/iho-table/src/hooks/tapHooks/index.js +1 -159
- package/es/components/iho-table/src/hooks/tapHooks/useConfigHooks.js +1 -67
- package/es/components/iho-table/src/hooks/tapHooks/useDataHooks.js +1 -26
- package/es/components/iho-table/src/hooks/tapHooks/useDomInsertHooks.js +1 -27
- package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.js +1 -280
- package/es/components/iho-table/src/hooks/tapHooks/useExposeHooks.js +1 -26
- package/es/components/iho-table/src/hooks/tapHooks/useFieldHooks.js +1 -38
- package/es/components/iho-table/src/hooks/tapHooks/useSetupHooks.js +1 -27
- package/es/components/iho-table/src/hooks/useColumnConfigAdaptor.js +1 -164
- package/es/components/iho-table/src/hooks/useTableContext.js +1 -17
- package/es/components/iho-table/src/hooks/useTablePlugin.js +1 -20
- package/es/components/iho-table/src/plugins/anchorPlugin/index.js +1 -19
- package/es/components/iho-table/src/plugins/anchorPlugin/tableAnchor.js +1 -51
- package/es/components/iho-table/src/plugins/anchorPlugin/useAnchor.js +1 -87
- package/es/components/iho-table/src/plugins/defaultConfigPlugin/index.js +1 -48
- package/es/components/iho-table/src/plugins/filterPlugin/filter.vue.js +1 -230
- package/es/components/iho-table/src/plugins/filterPlugin/index.js +1 -240
- package/es/components/iho-table/src/plugins/index.js +1 -47
- package/es/components/iho-table/src/plugins/keyboardEventPlugin/index.js +1 -30
- package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +1 -127
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.js +1 -203
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/index.js +1 -41
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/hooks/useAutoFocus.js +1 -21
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/inputRendererPlugin.js +1 -41
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/numberRendererPlugin.js +1 -79
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +1 -64
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/index.js +1 -46
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/selectUtils.js +1 -16
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue.js +1 -108
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/index.js +1 -163
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/separateUtils.js +1 -42
- package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin.js +1 -50
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/checkRendererPlugin.js +1 -30
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/colorRendererPlugin.js +1 -48
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/defaultRendererPlugin.js +1 -62
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/labelRendererPlugin.js +1 -52
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/pictureRendererPlugin.js +1 -92
- package/es/components/iho-table/src/plugins/rendererPlugins/widgets/seqRendererPlugin.js +1 -59
- package/es/components/iho-table/src/plugins/rowClickPlugin/index.js +1 -34
- package/es/components/iho-table/src/plugins/rowGroupSettingPlugin/index.js +1 -30
- package/es/components/iho-table/src/plugins/rowGroupSettingPlugin/rowGroupUtils.js +1 -53
- package/es/components/iho-table/src/plugins/virtualTreePlugin/index.js +1 -100
- package/es/components/iho-table/src/types/index.js +1 -1
- package/es/components/iho-table/src/types/pluginType.js +1 -16
- package/es/components/iho-table/src/utils/index.js +1 -169
- package/es/components/index.js +1 -119
- package/es/components/info-header/index.js +1 -10
- package/es/components/info-header/src/HiddenContent.vue.js +1 -70
- package/es/components/info-header/src/InfoEllipsis.vue.js +1 -43
- package/es/components/info-header/src/InfoHeader.vue.js +1 -313
- package/es/components/insurance-sdk/index.js +1 -1
- package/es/components/insurance-sdk/src/constants/index.js +1 -160
- package/es/components/insurance-sdk/src/utils/index.js +1 -1
- package/es/components/insurance-sdk/src/utils/insurance.js +1 -268
- package/es/components/keyboard/index.d.ts +1 -1
- package/es/components/keyboard/index.js +1 -10
- package/es/components/keyboard/src/Keyboard.vue.d.ts +1 -1
- package/es/components/keyboard/src/Keyboard.vue.js +1 -164
- package/es/components/keyboard/src/components/InputNumber.vue.js +1 -86
- package/es/components/keyboard/src/components/NumberPanel.vue.d.ts +1 -1
- package/es/components/keyboard/src/components/NumberPanel.vue.js +1 -299
- package/es/components/keyboard/src/utils/index.js +1 -5
- package/es/components/map/index.js +1 -10
- package/es/components/map/src/Map.vue.js +1 -336
- package/es/components/recommend-search/index.js +1 -10
- package/es/components/recommend-search/src/RecommendSearch.vue.js +1 -63
- package/es/components/recommend-search/src/components/BaseSearch.vue.js +1 -157
- package/es/components/recommend-search/src/components/RecommendInput.vue.js +1 -125
- package/es/components/recommend-search/src/components/RecommendMenu.vue.js +1 -104
- package/es/components/recommend-search/src/components/RecommendSelect.vue.js +1 -146
- package/es/components/recommend-search/src/constant/index.js +1 -7
- package/es/components/scale-view/index.js +1 -35
- package/es/components/scale-view/src/ScaleView.vue.js +1 -429
- package/es/components/scale-view/src/components/AnswerParse.vue.js +1 -80
- package/es/components/scale-view/src/components/EvaluateCountdown.vue.js +1 -117
- package/es/components/scale-view/src/components/EvaluatePage.vue.js +1 -141
- package/es/components/scale-view/src/components/LoadingCom.vue.js +1 -19
- package/es/components/scale-view/src/components/NoData.vue.js +1 -74
- package/es/components/scale-view/src/components/ScaleScore.js +1 -63
- package/es/components/scale-view/src/components/composables/choose-common.js +1 -83
- package/es/components/scale-view/src/components/formitem/address.js +1 -3993
- package/es/components/scale-view/src/components/formitem/r-address.js +1 -226
- package/es/components/scale-view/src/components/formitem/r-cascader.js +1 -133
- package/es/components/scale-view/src/components/formitem/r-checkbox.js +1 -281
- package/es/components/scale-view/src/components/formitem/r-collection.js +1 -111
- package/es/components/scale-view/src/components/formitem/r-datetime.js +1 -212
- package/es/components/scale-view/src/components/formitem/r-input.js +1 -86
- package/es/components/scale-view/src/components/formitem/r-map.js +1 -106
- package/es/components/scale-view/src/components/formitem/r-radio.js +1 -240
- package/es/components/scale-view/src/components/formitem/r-select.js +1 -202
- package/es/components/scale-view/src/components/formitem/r-sign.js +1 -177
- package/es/components/scale-view/src/components/formitem/r-upload.js +1 -215
- package/es/components/scale-view/src/components/formitem/sign-com.js +1 -307
- package/es/components/scale-view/src/components/formitem/standard-modal.js +1 -129
- package/es/components/scale-view/src/hooks/scaleview-computed.js +1 -354
- package/es/components/scale-view/src/hooks/scaleview-init.js +1 -437
- package/es/components/scale-view/src/hooks/scaleview-props.js +1 -81
- package/es/components/scale-view/src/hooks/scaleview-state.js +1 -38
- package/es/components/scale-view/src/hooks/scaleview-submit.js +1 -154
- package/es/components/scale-view/src/hooks/scaleview-validate.js +1 -187
- package/es/components/scale-view/src/hooks/use-component.js +1 -86
- package/es/components/scale-view/src/hooks/use-evaluate.js +1 -150
- package/es/components/scale-view/src/hooks/use-event.js +1 -129
- package/es/components/scale-view/src/hooks/use-noData.js +1 -41
- package/es/components/scale-view/src/utils/judge-types.js +1 -36
- package/es/components/search-cascader/index.js +1 -10
- package/es/components/search-cascader/src/SearchCascader.vue.js +1 -194
- package/es/components/search-cascader/src/components/SearchMenu.js +1 -196
- package/es/components/search-cascader/src/components/index.js +1 -1
- package/es/components/search-cascader/src/constants/index.js +1 -11
- package/es/components/search-cascader/src/hooks/index.js +1 -1
- package/es/components/search-cascader/src/hooks/useCssVariable.js +1 -7
- package/es/components/search-cascader/src/utils/index.js +1 -11
- package/es/components/select-label/index.js +1 -15
- package/es/components/select-label/src/LabelFormContent.vue.js +1 -447
- package/es/components/select-label/src/SelectLabel.vue.js +1 -6
- package/es/components/select-label/src/SelectLabel.vue2.js +1 -451
- package/es/components/select-label/src/components/label-classify.vue.js +1 -132
- package/es/components/select-person/index.js +1 -10
- package/es/components/select-person/src/SelectPerson.vue.js +1 -6
- package/es/components/select-person/src/SelectPerson.vue2.js +1 -303
- package/es/components/select-person/src/utils/index.js +1 -58
- package/es/components/shortcut-provider/index.js +1 -12
- package/es/components/shortcut-provider/src/ShortcutProvider.vue.js +1 -42
- package/es/components/shortcut-provider/src/constants/index.js +1 -8
- package/es/components/shortcut-provider/src/hooks/index.js +1 -2
- package/es/components/shortcut-provider/src/hooks/useShortcutSignature.js +1 -12
- package/es/components/shortcut-provider/src/hooks/useShortcuts.js +1 -188
- package/es/components/shortcut-provider/src/utils/index.js +1 -92
- package/es/components/shortcut-setter/index.js +1 -10
- package/es/components/shortcut-setter/src/ShortcutSetter.vue.js +1 -98
- package/es/components/shortcut-setter/src/ShortcutSetterItem.vue.js +1 -76
- package/es/components/steps-wheel/index.js +1 -10
- package/es/components/steps-wheel/src/StepsWheel.vue.js +1 -376
- package/es/components/table-filter/index.js +1 -21
- package/es/components/table-filter/src/base-search-com/BaseSearch.vue.js +1 -2272
- package/es/components/table-filter/src/classification/Classification-com.vue.js +1 -1315
- package/es/components/table-filter/src/classification/search-class-name.vue.js +1 -195
- package/es/components/table-filter/src/classification/search-professional-model.vue.js +1 -594
- package/es/components/table-filter/src/components/age-com/index.vue.js +1 -185
- package/es/components/table-filter/src/components/button-group/ButtonGroup.vue.js +1 -86
- package/es/components/table-filter/src/components/button-icon/getBtnIcon.js +1 -30
- package/es/components/table-filter/src/components/c-tree-select/tree-select.vue.js +1 -253
- package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue.js +1 -114
- package/es/components/table-filter/src/components/classify-filter/helpers/options.js +1 -14
- package/es/components/table-filter/src/components/classify-filter/hooks/useDisplayCategory.js +1 -87
- package/es/components/table-filter/src/components/classify-filter/hooks/useFilterConditions.js +1 -147
- package/es/components/table-filter/src/components/classify-filter/index.vue.js +1 -304
- package/es/components/table-filter/src/components/multi-select/multi-select.vue.js +1 -153
- package/es/components/table-filter/src/components/out-quick-search/out-quick-search.vue.js +1 -310
- package/es/components/table-filter/src/components/range-age/index.vue.js +1 -137
- package/es/components/table-filter/src/components/render-widget/components/CheckboxGroup.vue.js +1 -64
- package/es/components/table-filter/src/components/render-widget/components/Select.vue.js +1 -45
- package/es/components/table-filter/src/components/render-widget/components/index.js +1 -2
- package/es/components/table-filter/src/components/render-widget/enums.js +1 -27
- package/es/components/table-filter/src/components/render-widget/helpers/presetValToTimestamp.js +1 -70
- package/es/components/table-filter/src/components/render-widget/index.vue.js +1 -107
- package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.js +1 -152
- package/es/components/table-filter/src/components/search-condition/SearchCondition.vue.js +1 -1520
- package/es/components/table-filter/src/components/search-condition/fieldTypeList.js +1 -171
- package/es/components/table-filter/src/components/search-filter/SearchFilter.vue.js +1 -199
- package/es/components/table-filter/src/components/search-modal/set-classification.vue.js +1 -241
- package/es/components/table-filter/src/components/table-modal/TableModal.vue.js +1 -526
- package/es/components/table-filter/src/const/dataOptions.js +1 -107
- package/es/components/table-filter/src/const/index.js +1 -5
- package/es/components/table-filter/src/directive/flexibleResize.js +1 -157
- package/es/components/table-filter/src/directive/preventReClick.js +1 -14
- package/es/components/table-filter/src/directive/resize.js +1 -12
- package/es/components/table-filter/src/hooks/export.js +1 -1
- package/es/components/table-filter/src/hooks/useAdvanced.js +1 -64
- package/es/components/table-filter/src/hooks/useMixins.js +1 -532
- package/es/components/table-filter/src/hooks/useRenderWidget.js +1 -94
- package/es/components/table-filter/src/hooks/useTableSearchCon.js +1 -131
- package/es/components/table-filter/src/hooks/useWordBookutils.js +1 -91
- package/es/components/table-filter/src/quick-search/QuickSearch.vue.js +1 -2038
- package/es/components/table-filter/src/tool/generateDefOptions.js +1 -65
- package/es/components/table-filter/src/tool/getWidgetType.js +1 -27
- package/es/components/table-filter/src/tool/options.js +1 -200
- package/es/components/table-filter/src/tool/resizeSensor.js +1 -123
- package/es/components/table-filter/src/tool/time-domain.js +1 -100
- package/es/components/table-filter/src/tool/transformData.js +1 -169
- package/es/components/table-filter/src/tool/utils.js +1 -29
- package/es/components/table-filter/src/types/enums.js +1 -67
- package/es/components/time-line/index.js +1 -10
- package/es/components/time-line/src/TimeLine.vue.js +1 -70
- package/es/components/vod-chunk-upload/index.js +1 -14
- package/es/components/vod-chunk-upload/src/chunk-upload-new.vue.js +1 -480
- package/es/components/vod-chunk-upload/src/hooks/upload-computed.js +1 -70
- package/es/components/vod-chunk-upload/src/hooks/upload-data.js +1 -96
- package/es/components/vod-chunk-upload/src/hooks/vod-computed.js +1 -79
- package/es/components/vod-chunk-upload/src/hooks/vod-data.js +1 -28
- package/es/components/vod-chunk-upload/src/vod-chunk-upload/index.js +1 -2
- package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue.js +1 -332
- package/es/components/vod-chunk-upload/src/vod-upload-modal.js +1 -94
- package/es/shared/assets/img/failure.png.js +1 -3
- package/es/shared/assets/img/no-permission.png.js +1 -3
- package/es/shared/assets/img/nodata.png.js +1 -3
- package/es/shared/assets/img/notfound.png.js +1 -3
- package/es/shared/assets/img/qr.png.js +1 -3
- package/es/shared/assets/img/success.png.js +1 -3
- package/es/shared/assets/img/video.png.js +1 -3
- package/es/shared/assets/img/video_default_cover.png.js +1 -3
- package/es/shared/assets/img/xb_big.png.js +1 -3
- package/es/shared/assets/img/xb_small.png.js +1 -3
- package/es/shared/components/SelectPage/SelectPage.vue.js +1 -61
- package/es/shared/components/SelectPage/index.js +1 -2
- package/es/shared/components/SlotRender/SlotRender.js +1 -35
- package/es/shared/components/SlotRender/index.js +1 -2
- package/es/shared/components/SvgIcon/SvgIcon.vue.js +1 -36
- package/es/shared/components/SvgIcon/index.js +1 -2
- package/es/shared/components/TextOverTooltip/TextOverTooltip.vue.js +1 -77
- package/es/shared/components/TextOverTooltip/index.js +1 -2
- package/es/shared/components/VueDraggable/index.js +1 -2
- package/es/shared/components/VueDraggable/src/core/componentBuilderHelper.js +1 -35
- package/es/shared/components/VueDraggable/src/core/componentStructure.js +1 -54
- package/es/shared/components/VueDraggable/src/core/renderHelper.js +1 -47
- package/es/shared/components/VueDraggable/src/core/sortableEvents.js +1 -14
- package/es/shared/components/VueDraggable/src/util/console.js +1 -9
- package/es/shared/components/VueDraggable/src/util/htmlHelper.js +1 -11
- package/es/shared/components/VueDraggable/src/util/string.js +1 -11
- package/es/shared/components/VueDraggable/src/util/tags.js +1 -130
- package/es/shared/components/VueDraggable/src/vuedraggable.js +1 -265
- package/es/shared/components/no-data/NoData.vue.js +1 -74
- package/es/shared/components/no-data/index.js +1 -2
- package/es/shared/components/player-vod/player.js +1 -121
- package/es/shared/components/player-vod/video-modal.js +1 -91
- package/es/shared/global/variable.js +1 -3
- package/es/shared/utils/anime.js +1 -129
- package/es/shared/utils/colorLog.js +1 -53
- package/es/shared/utils/index.js +1 -167
- package/es/shared/utils/loadViewer.js +1 -11
- package/es/shared/utils/tapable/AsyncParallelBailHook.js +1 -63
- package/es/shared/utils/tapable/AsyncParallelHook.js +1 -27
- package/es/shared/utils/tapable/AsyncSeriesBailHook.js +1 -18
- package/es/shared/utils/tapable/AsyncSeriesHook.js +1 -27
- package/es/shared/utils/tapable/AsyncSeriesLoopHook.js +1 -12
- package/es/shared/utils/tapable/AsyncSeriesWaterfallHook.js +1 -22
- package/es/shared/utils/tapable/Hook.js +1 -140
- package/es/shared/utils/tapable/HookCodeFactory.js +1 -456
- package/es/shared/utils/tapable/SyncBailHook.js +1 -19
- package/es/shared/utils/tapable/SyncHook.js +1 -34
- package/es/shared/utils/tapable/SyncLoopHook.js +1 -13
- package/es/shared/utils/tapable/SyncWaterfallHook.js +1 -47
- package/es/shared/utils/utilExpand.js +1 -781
- package/es/shared/utils/vexutils.js +1 -59
- package/package.json +2 -2
|
@@ -1,32 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
function useCommon(canvas) {
|
|
4
|
-
const $message = useMessage();
|
|
5
|
-
function getEqualXTypes(pointX, field, range = 6) {
|
|
6
|
-
const types = [];
|
|
7
|
-
const half = range / 2;
|
|
8
|
-
canvas.value.forEachObject((obj) => {
|
|
9
|
-
if (obj.origin && !obj.origin.isMenu && obj.left >= pointX - half && obj.left <= pointX + half) {
|
|
10
|
-
types.push(obj.origin[field]);
|
|
11
|
-
}
|
|
12
|
-
});
|
|
13
|
-
return [...new Set(types)];
|
|
14
|
-
}
|
|
15
|
-
function repeatTip() {
|
|
16
|
-
$message.warning("\u8BE5\u65F6\u6BB5\u5DF2\u5B58\u5728\u6570\u503C\u4E0D\u80FD\u65B0\u589E");
|
|
17
|
-
}
|
|
18
|
-
function maxLimitTip() {
|
|
19
|
-
$message.warning("\u672A\u6765\u65F6\u95F4\u4E0D\u5141\u8BB8\u5F55\u5165");
|
|
20
|
-
}
|
|
21
|
-
function minLimitTip() {
|
|
22
|
-
$message.warning("\u4E0D\u5141\u8BB8\u5C0F\u4E8E\u5165\u9662\u65F6\u95F4");
|
|
23
|
-
}
|
|
24
|
-
return {
|
|
25
|
-
getEqualXTypes,
|
|
26
|
-
repeatTip,
|
|
27
|
-
maxLimitTip,
|
|
28
|
-
minLimitTip
|
|
29
|
-
};
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
export { useCommon };
|
|
1
|
+
import{useMessage as n}from"naive-ui";function i(i){const t=n();return{getEqualXTypes:function(n,t,e=6){const r=[],o=e/2;return i.value.forEachObject((i=>{i.origin&&!i.origin.isMenu&&i.left>=n-o&&i.left<=n+o&&r.push(i.origin[t])})),[...new Set(r)]},repeatTip:function(){t.warning("该时段已存在数值不能新增")},maxLimitTip:function(){t.warning("未来时间不允许录入")},minLimitTip:function(){t.warning("不允许小于入院时间")}}}export{i as useCommon};
|
|
@@ -1,79 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
function useCumputedPoint(propItems) {
|
|
4
|
-
const { xScaleList, originX, endY, xCellWidth, left, vitalSignsOriginY, painOriginY, canvasWidth } = propItems;
|
|
5
|
-
function cumputedX(value, setAllCenter = false) {
|
|
6
|
-
const time = new Date(value).getTime();
|
|
7
|
-
const [minScale] = xScaleList;
|
|
8
|
-
const maxScale = xScaleList.at(-1);
|
|
9
|
-
if (time < minScale.start)
|
|
10
|
-
return 0;
|
|
11
|
-
if (time > maxScale.end)
|
|
12
|
-
return canvasWidth;
|
|
13
|
-
const index = xScaleList.findIndex((v) => v.end >= time);
|
|
14
|
-
if (index > -1) {
|
|
15
|
-
const item = xScaleList[index];
|
|
16
|
-
return item.center;
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
function cumputedY(type, scaleValueList, value) {
|
|
20
|
-
const yScaleCell = propItems[`${type}YCell`];
|
|
21
|
-
const yCellUnit = +value - Math.min(...scaleValueList);
|
|
22
|
-
const newEndY = type === "pain" ? painOriginY.endY : vitalSignsOriginY.endY;
|
|
23
|
-
return newEndY - yScaleCell * yCellUnit;
|
|
24
|
-
}
|
|
25
|
-
function getXValue(pointX) {
|
|
26
|
-
const index = xScaleList.findIndex((v) => v.left + xCellWidth >= pointX);
|
|
27
|
-
if (index > -1) {
|
|
28
|
-
const item = xScaleList[index];
|
|
29
|
-
const residueX = pointX - item.left;
|
|
30
|
-
const residueTime = item.scaleCell * residueX;
|
|
31
|
-
const time = item.start + residueTime;
|
|
32
|
-
return format(new Date(time), "yyyy-MM-dd HH:mm");
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
function getYValue(type, pointY) {
|
|
36
|
-
var _a;
|
|
37
|
-
const yScaleCell = propItems[`${type}YCell`];
|
|
38
|
-
const list = ((_a = left.yScaleValue.find((v) => v.type === type)) == null ? void 0 : _a.list) || [];
|
|
39
|
-
const minVal = list.length ? Math.min(...list) : 0;
|
|
40
|
-
const newEndY = type === "pain" ? painOriginY.endY : vitalSignsOriginY.endY;
|
|
41
|
-
const y = (newEndY - pointY) / yScaleCell + minVal;
|
|
42
|
-
return Math.floor(y * 100) / 100;
|
|
43
|
-
}
|
|
44
|
-
return {
|
|
45
|
-
cumputedX,
|
|
46
|
-
cumputedY,
|
|
47
|
-
getXValue,
|
|
48
|
-
getYValue
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
function useBirthProcessCumputedPoint(propItems) {
|
|
52
|
-
const { xAxis, originX, originY, xCellWidth, endY, timeXCell, startTime, scaleValues } = propItems;
|
|
53
|
-
function cumputedX(value) {
|
|
54
|
-
const time = new Date(value).getTime();
|
|
55
|
-
return (time - startTime) / timeXCell + originX;
|
|
56
|
-
}
|
|
57
|
-
function cumputedY(key, range, value) {
|
|
58
|
-
const [minValue] = range;
|
|
59
|
-
return endY - (+value - minValue) / propItems[`${key}YCell`];
|
|
60
|
-
}
|
|
61
|
-
function getXValue(pointX) {
|
|
62
|
-
const time = (pointX - originX) * timeXCell + startTime;
|
|
63
|
-
return format(new Date(time), "yyyy-MM-dd HH:mm");
|
|
64
|
-
}
|
|
65
|
-
function getYValue(key, pointY) {
|
|
66
|
-
const item = scaleValues.find((item2) => key === item2.key);
|
|
67
|
-
const [minValue] = (item == null ? void 0 : item.range) || [0];
|
|
68
|
-
const y = (endY - pointY) * propItems[`${key}YCell`] + minValue;
|
|
69
|
-
return Math.floor(y * 100) / 100;
|
|
70
|
-
}
|
|
71
|
-
return {
|
|
72
|
-
cumputedX,
|
|
73
|
-
cumputedY,
|
|
74
|
-
getXValue,
|
|
75
|
-
getYValue
|
|
76
|
-
};
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
export { useBirthProcessCumputedPoint, useCumputedPoint };
|
|
1
|
+
import{format as n}from"date-fns";function e(e){const{xScaleList:t,originX:i,endY:r,xCellWidth:l,left:u,vitalSignsOriginY:o,painOriginY:a,canvasWidth:c}=e;return{cumputedX:function(n,e=!1){const i=new Date(n).getTime(),[r]=t,l=t.at(-1);if(i<r.start)return 0;if(i>l.end)return c;const u=t.findIndex((n=>n.end>=i));if(u>-1){return t[u].center}},cumputedY:function(n,t,i){const r=e[`${n}YCell`],l=+i-Math.min(...t);return("pain"===n?a.endY:o.endY)-r*l},getXValue:function(e){const i=t.findIndex((n=>n.left+l>=e));if(i>-1){const r=t[i],l=e-r.left,u=r.scaleCell*l,o=r.start+u;return n(new Date(o),"yyyy-MM-dd HH:mm")}},getYValue:function(n,t){var i;const r=e[`${n}YCell`],l=(null==(i=u.yScaleValue.find((e=>e.type===n)))?void 0:i.list)||[],c=l.length?Math.min(...l):0,d=(("pain"===n?a.endY:o.endY)-t)/r+c;return Math.floor(100*d)/100}}}function t(e){const{xAxis:t,originX:i,originY:r,xCellWidth:l,endY:u,timeXCell:o,startTime:a,scaleValues:c}=e;return{cumputedX:function(n){return(new Date(n).getTime()-a)/o+i},cumputedY:function(n,t,i){const[r]=t;return u-(+i-r)/e[`${n}YCell`]},getXValue:function(e){return n(new Date((e-i)*o+a),"yyyy-MM-dd HH:mm")},getYValue:function(n,t){const i=c.find((e=>n===e.key)),[r]=(null==i?void 0:i.range)||[0],l=(u-t)*e[`${n}YCell`]+r;return Math.floor(100*l)/100}}}export{t as useBirthProcessCumputedPoint,e as useCumputedPoint};
|
|
@@ -1,182 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
const defaultStyle = {
|
|
4
|
-
evented: false,
|
|
5
|
-
selectable: false
|
|
6
|
-
};
|
|
7
|
-
const defaultBorderStyle = {
|
|
8
|
-
stroke: "#999",
|
|
9
|
-
strokeWidth: 1,
|
|
10
|
-
...defaultStyle
|
|
11
|
-
};
|
|
12
|
-
const defaultLineStyle = {
|
|
13
|
-
stroke: "#000",
|
|
14
|
-
strokeWidth: 1,
|
|
15
|
-
strokeDashArray: [0, 0],
|
|
16
|
-
...defaultStyle
|
|
17
|
-
};
|
|
18
|
-
const defaultRectStyle = {
|
|
19
|
-
fill: "transparent",
|
|
20
|
-
stroke: "#999",
|
|
21
|
-
strokeWidth: 1,
|
|
22
|
-
originX: "center",
|
|
23
|
-
originY: "center",
|
|
24
|
-
...defaultStyle
|
|
25
|
-
};
|
|
26
|
-
const defaultTextStyle = {
|
|
27
|
-
fontFamily: "\u5FAE\u8F6F\u96C5\u9ED1",
|
|
28
|
-
fontSize: 12,
|
|
29
|
-
fill: "#000",
|
|
30
|
-
centeredRotation: true,
|
|
31
|
-
originX: "center",
|
|
32
|
-
originY: "center",
|
|
33
|
-
lineHeight: 1,
|
|
34
|
-
...defaultStyle
|
|
35
|
-
};
|
|
36
|
-
function drawLine(points, style) {
|
|
37
|
-
return new fabric.Line(points, {
|
|
38
|
-
...defaultLineStyle,
|
|
39
|
-
...style
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
function drawText([x, y], style) {
|
|
43
|
-
const text = new fabric.Text(String(style.value), {
|
|
44
|
-
...defaultTextStyle,
|
|
45
|
-
left: x,
|
|
46
|
-
top: y,
|
|
47
|
-
...style
|
|
48
|
-
});
|
|
49
|
-
return text;
|
|
50
|
-
}
|
|
51
|
-
function drawArrow([x, y1, y2], style, type = "down") {
|
|
52
|
-
const arrowLine = drawLine([x, y1, x, y2], {
|
|
53
|
-
strokeWidth: 1,
|
|
54
|
-
stroke: style.fill
|
|
55
|
-
});
|
|
56
|
-
const arrow = drawText([x + 0.5, type === "up" ? y2 - 3 : y2 + 3], {
|
|
57
|
-
value: "v",
|
|
58
|
-
originX: "center",
|
|
59
|
-
originY: "bottom",
|
|
60
|
-
fontSize: 16,
|
|
61
|
-
angle: type === "up" ? 180 : 0,
|
|
62
|
-
...style
|
|
63
|
-
});
|
|
64
|
-
const arrowGroup = new fabric.Group([arrowLine, arrow], {
|
|
65
|
-
...defaultStyle,
|
|
66
|
-
originX: "center",
|
|
67
|
-
originY: "top"
|
|
68
|
-
});
|
|
69
|
-
return arrowGroup;
|
|
70
|
-
}
|
|
71
|
-
function drawTextGroup(rectStyle, fontStyle, groupStyle) {
|
|
72
|
-
const rect = new fabric.Rect({
|
|
73
|
-
...defaultRectStyle,
|
|
74
|
-
...rectStyle
|
|
75
|
-
});
|
|
76
|
-
const { value = "\u6807\u9898", textAlign = "center", verticalAlign = "center" } = fontStyle;
|
|
77
|
-
const textLeft = rectStyle.width / 2;
|
|
78
|
-
const textTop = rectStyle.height / 2;
|
|
79
|
-
const texts = new fabric.Text(String(value), {
|
|
80
|
-
...defaultTextStyle,
|
|
81
|
-
...fontStyle,
|
|
82
|
-
...textAlign == "left" || textAlign == "right" ? {
|
|
83
|
-
originX: textAlign,
|
|
84
|
-
left: textAlign == "left" ? -textLeft : textLeft
|
|
85
|
-
} : {},
|
|
86
|
-
...verticalAlign == "top" || verticalAlign == "bottom" ? {
|
|
87
|
-
originY: verticalAlign,
|
|
88
|
-
top: verticalAlign == "top" ? -textTop : textTop
|
|
89
|
-
} : {}
|
|
90
|
-
});
|
|
91
|
-
return new fabric.Group([rect, texts], {
|
|
92
|
-
...defaultStyle,
|
|
93
|
-
...groupStyle
|
|
94
|
-
});
|
|
95
|
-
}
|
|
96
|
-
function drawPoint(type = "circle", style) {
|
|
97
|
-
const newStyle = {
|
|
98
|
-
originX: "center",
|
|
99
|
-
originY: "center",
|
|
100
|
-
hasControls: false,
|
|
101
|
-
hasBorders: false,
|
|
102
|
-
hoverCursor: "pointer",
|
|
103
|
-
...style
|
|
104
|
-
};
|
|
105
|
-
const createCircleBorder = () => {
|
|
106
|
-
return new fabric.Circle({
|
|
107
|
-
objectCaching: false,
|
|
108
|
-
strokeWidth: style.strokeWidth || 1,
|
|
109
|
-
stroke: style.stroke || "red",
|
|
110
|
-
radius: style.radius || 5,
|
|
111
|
-
fill: "#fff"
|
|
112
|
-
});
|
|
113
|
-
};
|
|
114
|
-
switch (type) {
|
|
115
|
-
case "triangle":
|
|
116
|
-
return new fabric.Triangle({
|
|
117
|
-
width: 20,
|
|
118
|
-
height: 20,
|
|
119
|
-
strokeWidth: 1,
|
|
120
|
-
scale: 1,
|
|
121
|
-
...newStyle
|
|
122
|
-
});
|
|
123
|
-
case "circle":
|
|
124
|
-
return new fabric.Circle({
|
|
125
|
-
objectCaching: false,
|
|
126
|
-
strokeWidth: 1,
|
|
127
|
-
radius: 5,
|
|
128
|
-
scale: 1,
|
|
129
|
-
...newStyle
|
|
130
|
-
});
|
|
131
|
-
case "image":
|
|
132
|
-
return new fabric.Image(style.element, {
|
|
133
|
-
...newStyle,
|
|
134
|
-
scale: 1
|
|
135
|
-
});
|
|
136
|
-
case "yemai": {
|
|
137
|
-
const createAdd = () => {
|
|
138
|
-
const width = ((style.radius || 5) + (style.strokeWidth || 1)) * 2;
|
|
139
|
-
const subLineStyle = {
|
|
140
|
-
stroke: style.strokeX || "blue",
|
|
141
|
-
strokeWidth: style.strokeWidthX || 1,
|
|
142
|
-
originX: "center",
|
|
143
|
-
originY: "center"
|
|
144
|
-
};
|
|
145
|
-
const line1 = new fabric.Line([0, width / 2, width, width / 2], subLineStyle);
|
|
146
|
-
const line2 = new fabric.Line([width / 2, 0, width / 2, width], subLineStyle);
|
|
147
|
-
return new fabric.Group([line1, line2]);
|
|
148
|
-
};
|
|
149
|
-
return new fabric.Group([createCircleBorder(), createAdd()], {
|
|
150
|
-
scale: 1,
|
|
151
|
-
...newStyle
|
|
152
|
-
});
|
|
153
|
-
}
|
|
154
|
-
case "koumai": {
|
|
155
|
-
const left = (style.radius || 5) + (style.strokeWidth || 1);
|
|
156
|
-
const circle = new fabric.Circle({
|
|
157
|
-
objectCaching: false,
|
|
158
|
-
radius: style.radiusCircle || 2,
|
|
159
|
-
fill: style.fillCircle || "#000",
|
|
160
|
-
originX: "center",
|
|
161
|
-
originY: "center",
|
|
162
|
-
left,
|
|
163
|
-
top: left
|
|
164
|
-
});
|
|
165
|
-
return new fabric.Group([createCircleBorder(), circle], {
|
|
166
|
-
scale: 1,
|
|
167
|
-
...newStyle
|
|
168
|
-
});
|
|
169
|
-
}
|
|
170
|
-
default:
|
|
171
|
-
style && Reflect.deleteProperty(style, "stroke");
|
|
172
|
-
return new fabric.Text(String(type), {
|
|
173
|
-
fontFamily: "\u5FAE\u8F6F\u96C5\u9ED1",
|
|
174
|
-
scale: 1,
|
|
175
|
-
fontSize: 14,
|
|
176
|
-
fill: "#000",
|
|
177
|
-
...newStyle
|
|
178
|
-
});
|
|
179
|
-
}
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
export { defaultBorderStyle, defaultLineStyle, defaultRectStyle, defaultStyle, defaultTextStyle, drawArrow, drawLine, drawPoint, drawText, drawTextGroup };
|
|
1
|
+
import{fabric as e}from"../utils/index.js";const t={evented:!1,selectable:!1},r={stroke:"#999",strokeWidth:1,...t},i={stroke:"#000",strokeWidth:1,strokeDashArray:[0,0],...t},n={fill:"transparent",stroke:"#999",strokeWidth:1,originX:"center",originY:"center",...t},o={fontFamily:"微软雅黑",fontSize:12,fill:"#000",centeredRotation:!0,originX:"center",originY:"center",lineHeight:1,...t};function c(t,r){return new e.Line(t,{...i,...r})}function s([t,r],i){return new e.Text(String(i.value),{...o,left:t,top:r,...i})}function l([r,i,n],o,l="down"){const a=c([r,i,r,n],{strokeWidth:1,stroke:o.fill}),u=s([r+.5,"up"===l?n-3:n+3],{value:"v",originX:"center",originY:"bottom",fontSize:16,angle:"up"===l?180:0,...o});return new e.Group([a,u],{...t,originX:"center",originY:"top"})}function a(r,i,c){const s=new e.Rect({...n,...r}),{value:l="标题",textAlign:a="center",verticalAlign:u="center"}=i,g=r.width/2,d=r.height/2,f=new e.Text(String(l),{...o,...i,..."left"==a||"right"==a?{originX:a,left:"left"==a?-g:g}:{},..."top"==u||"bottom"==u?{originY:u,top:"top"==u?-d:d}:{}});return new e.Group([s,f],{...t,...c})}function u(t="circle",r){const i={originX:"center",originY:"center",hasControls:!1,hasBorders:!1,hoverCursor:"pointer",...r},n=()=>new e.Circle({objectCaching:!1,strokeWidth:r.strokeWidth||1,stroke:r.stroke||"red",radius:r.radius||5,fill:"#fff"});switch(t){case"triangle":return new e.Triangle({width:20,height:20,strokeWidth:1,scale:1,...i});case"circle":return new e.Circle({objectCaching:!1,strokeWidth:1,radius:5,scale:1,...i});case"image":return new e.Image(r.element,{...i,scale:1});case"yemai":{const t=()=>{const t=2*((r.radius||5)+(r.strokeWidth||1)),i={stroke:r.strokeX||"blue",strokeWidth:r.strokeWidthX||1,originX:"center",originY:"center"},n=new e.Line([0,t/2,t,t/2],i),o=new e.Line([t/2,0,t/2,t],i);return new e.Group([n,o])};return new e.Group([n(),t()],{scale:1,...i})}case"koumai":{const t=(r.radius||5)+(r.strokeWidth||1),o=new e.Circle({objectCaching:!1,radius:r.radiusCircle||2,fill:r.fillCircle||"#000",originX:"center",originY:"center",left:t,top:t});return new e.Group([n(),o],{scale:1,...i})}default:return r&&Reflect.deleteProperty(r,"stroke"),new e.Text(String(t),{fontFamily:"微软雅黑",scale:1,fontSize:14,fill:"#000",...i})}}export{r as defaultBorderStyle,i as defaultLineStyle,n as defaultRectStyle,t as defaultStyle,o as defaultTextStyle,l as drawArrow,c as drawLine,u as drawPoint,s as drawText,a as drawTextGroup};
|
|
@@ -1,146 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { fabric } from '../utils/index.js';
|
|
3
|
-
|
|
4
|
-
function useEvent(element) {
|
|
5
|
-
useEventListener(element.nextSibling, "contextmenu", (e) => {
|
|
6
|
-
e.preventDefault();
|
|
7
|
-
return false;
|
|
8
|
-
});
|
|
9
|
-
}
|
|
10
|
-
function useCanvasEvent(canvas, propItems, emits) {
|
|
11
|
-
const { originY, originX, endX, endY, iconsWidth, selectionStyle, topList } = propItems;
|
|
12
|
-
function drawRect(options, key) {
|
|
13
|
-
const { left, top, width, height } = options;
|
|
14
|
-
const rect = new fabric.Rect({
|
|
15
|
-
key,
|
|
16
|
-
left: left != null ? left : 0,
|
|
17
|
-
top: top != null ? top : 0,
|
|
18
|
-
width,
|
|
19
|
-
height,
|
|
20
|
-
stroke: "transparent",
|
|
21
|
-
fill: "transparent",
|
|
22
|
-
lockMovementX: true,
|
|
23
|
-
lockMovementY: true,
|
|
24
|
-
transparentCorners: false,
|
|
25
|
-
hasControls: false,
|
|
26
|
-
...selectionStyle,
|
|
27
|
-
strokeWidth: 0
|
|
28
|
-
});
|
|
29
|
-
canvas.value.add(rect);
|
|
30
|
-
return rect;
|
|
31
|
-
}
|
|
32
|
-
let selections = [];
|
|
33
|
-
function initSelection() {
|
|
34
|
-
const selections2 = [];
|
|
35
|
-
selections2.push(
|
|
36
|
-
drawRect(
|
|
37
|
-
{
|
|
38
|
-
left: iconsWidth,
|
|
39
|
-
top: originY + 1,
|
|
40
|
-
width: originX - iconsWidth,
|
|
41
|
-
height: endY - originY - 3
|
|
42
|
-
},
|
|
43
|
-
"left"
|
|
44
|
-
)
|
|
45
|
-
);
|
|
46
|
-
let topY = 0;
|
|
47
|
-
topList.forEach((item, index) => {
|
|
48
|
-
if (index > 0) {
|
|
49
|
-
topY += propItems[`${topList[index - 1].key}Height`];
|
|
50
|
-
}
|
|
51
|
-
const commonOptions = {
|
|
52
|
-
top: topY + 1,
|
|
53
|
-
height: propItems[`${item.key}Height`] - 1
|
|
54
|
-
};
|
|
55
|
-
selections2.push(
|
|
56
|
-
drawRect(
|
|
57
|
-
{
|
|
58
|
-
left: iconsWidth,
|
|
59
|
-
width: endX - iconsWidth,
|
|
60
|
-
...commonOptions
|
|
61
|
-
},
|
|
62
|
-
item.key + "All"
|
|
63
|
-
)
|
|
64
|
-
);
|
|
65
|
-
selections2.push(
|
|
66
|
-
drawRect(
|
|
67
|
-
{
|
|
68
|
-
left: iconsWidth,
|
|
69
|
-
width: originX - iconsWidth,
|
|
70
|
-
...commonOptions
|
|
71
|
-
},
|
|
72
|
-
item.key + "Title"
|
|
73
|
-
)
|
|
74
|
-
);
|
|
75
|
-
selections2.push(
|
|
76
|
-
drawRect(
|
|
77
|
-
{
|
|
78
|
-
left: originX,
|
|
79
|
-
width: endX - originX,
|
|
80
|
-
...commonOptions
|
|
81
|
-
},
|
|
82
|
-
item.key
|
|
83
|
-
)
|
|
84
|
-
);
|
|
85
|
-
});
|
|
86
|
-
selections2.push(
|
|
87
|
-
drawRect(
|
|
88
|
-
{
|
|
89
|
-
left: originX,
|
|
90
|
-
top: originY + 1,
|
|
91
|
-
width: endX - originX,
|
|
92
|
-
height: endY - originY - 3
|
|
93
|
-
},
|
|
94
|
-
"grid"
|
|
95
|
-
)
|
|
96
|
-
);
|
|
97
|
-
selections2.forEach((obj) => {
|
|
98
|
-
if (obj.key.endsWith("All")) {
|
|
99
|
-
obj.sendToBack();
|
|
100
|
-
obj.on("mouseup", (event) => {
|
|
101
|
-
const { button, pointer } = event;
|
|
102
|
-
if (button == 1) {
|
|
103
|
-
const _key = obj.key.replace("All", "");
|
|
104
|
-
const key = (pointer == null ? void 0 : pointer.x) && (pointer == null ? void 0 : pointer.x) <= originX ? _key + "Title" : _key;
|
|
105
|
-
obj.sendToBack();
|
|
106
|
-
select(key);
|
|
107
|
-
emits("select", key);
|
|
108
|
-
}
|
|
109
|
-
});
|
|
110
|
-
} else {
|
|
111
|
-
obj.on("mousedown", () => {
|
|
112
|
-
resetStrokeWidth();
|
|
113
|
-
setActiveObj(obj);
|
|
114
|
-
emits("select", obj.key);
|
|
115
|
-
});
|
|
116
|
-
}
|
|
117
|
-
});
|
|
118
|
-
return selections2;
|
|
119
|
-
}
|
|
120
|
-
function select(key) {
|
|
121
|
-
resetStrokeWidth();
|
|
122
|
-
const obj = selections == null ? void 0 : selections.find((obj2) => obj2.key === key);
|
|
123
|
-
setActiveObj(obj);
|
|
124
|
-
}
|
|
125
|
-
function init() {
|
|
126
|
-
if (typeof (selectionStyle == null ? void 0 : selectionStyle.evented) === "boolean" && !(selectionStyle == null ? void 0 : selectionStyle.evented))
|
|
127
|
-
return;
|
|
128
|
-
selections = initSelection();
|
|
129
|
-
}
|
|
130
|
-
function resetStrokeWidth() {
|
|
131
|
-
selections.forEach((obj) => {
|
|
132
|
-
obj.set("strokeWidth", 0);
|
|
133
|
-
obj.key.endsWith("All") && obj.sendToBack();
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
|
-
function setActiveObj(obj) {
|
|
137
|
-
var _a;
|
|
138
|
-
canvas.value.discardActiveObject();
|
|
139
|
-
!(obj == null ? void 0 : obj.key.includes("grid")) && (obj == null ? void 0 : obj.bringToFront());
|
|
140
|
-
obj == null ? void 0 : obj.set("strokeWidth", (_a = selectionStyle.strokeWidth) != null ? _a : 2);
|
|
141
|
-
}
|
|
142
|
-
init();
|
|
143
|
-
return { select };
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
export { useCanvasEvent, useEvent };
|
|
1
|
+
import{useEventListener as e}from"@vueuse/core";import{fabric as t}from"../utils/index.js";function n(t){e(t.nextSibling,"contextmenu",(e=>(e.preventDefault(),!1)))}function o(e,n,o){const{originY:l,originX:i,endX:s,endY:r,iconsWidth:u,selectionStyle:d,topList:h}=n;function c(n,o){const{left:l,top:i,width:s,height:r}=n,u=new t.Rect({key:o,left:null!=l?l:0,top:null!=i?i:0,width:s,height:r,stroke:"transparent",fill:"transparent",lockMovementX:!0,lockMovementY:!0,transparentCorners:!1,hasControls:!1,...d,strokeWidth:0});return e.value.add(u),u}let f=[];function k(e){p();a(null==f?void 0:f.find((t=>t.key===e)))}function p(){f.forEach((e=>{e.set("strokeWidth",0),e.key.endsWith("All")&&e.sendToBack()}))}function a(t){var n;e.value.discardActiveObject(),!(null==t?void 0:t.key.includes("grid"))&&(null==t||t.bringToFront()),null==t||t.set("strokeWidth",null!=(n=d.strokeWidth)?n:2)}return("boolean"!=typeof(null==d?void 0:d.evented)||(null==d?void 0:d.evented))&&(f=function(){const e=[];e.push(c({left:u,top:l+1,width:i-u,height:r-l-3},"left"));let t=0;return h.forEach(((o,l)=>{l>0&&(t+=n[`${h[l-1].key}Height`]);const r={top:t+1,height:n[`${o.key}Height`]-1};e.push(c({left:u,width:s-u,...r},o.key+"All")),e.push(c({left:u,width:i-u,...r},o.key+"Title")),e.push(c({left:i,width:s-i,...r},o.key))})),e.push(c({left:i,top:l+1,width:s-i,height:r-l-3},"grid")),e.forEach((e=>{e.key.endsWith("All")?(e.sendToBack(),e.on("mouseup",(t=>{const{button:n,pointer:l}=t;if(1==n){const t=e.key.replace("All",""),n=(null==l?void 0:l.x)&&(null==l?void 0:l.x)<=i?t+"Title":t;e.sendToBack(),k(n),o("select",n)}}))):e.on("mousedown",(()=>{p(),a(e),o("select",e.key)}))})),e}()),{select:k}}export{o as useCanvasEvent,n as useEvent};
|
|
@@ -1,54 +1 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { drawLine, defaultBorderStyle } from './useDraw.js';
|
|
3
|
-
|
|
4
|
-
function useGrid(canvas, propItems, isBirthProcess = false) {
|
|
5
|
-
var _a, _b, _c, _d;
|
|
6
|
-
const { gridYNumber, originY, grid, originX, endX, xCellWidth, yCellHeight, gridXNumber, endY } = propItems;
|
|
7
|
-
const yList = [];
|
|
8
|
-
const xList = [];
|
|
9
|
-
const mainList = /* @__PURE__ */ new Set();
|
|
10
|
-
for (let i = 0; i <= gridYNumber; i++) {
|
|
11
|
-
const y = originY + parseInt(String(yCellHeight * (gridYNumber - i)));
|
|
12
|
-
if (isBirthProcess) {
|
|
13
|
-
const line = drawLine([originX, y, endX, y], { ...defaultBorderStyle, ...((_a = grid.mainLineStyle) == null ? void 0 : _a.x) || {} });
|
|
14
|
-
yList.push(line);
|
|
15
|
-
} else {
|
|
16
|
-
const style = i % grid.subYCell === 0 ? ((_b = grid.mainLineStyle) == null ? void 0 : _b.x) || {} : grid.subLineStyle || {};
|
|
17
|
-
const line = drawLine([originX, y, endX, y], style);
|
|
18
|
-
if (i % grid.subYCell === 0) {
|
|
19
|
-
mainList.add(line);
|
|
20
|
-
} else {
|
|
21
|
-
yList.push(line);
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
for (let i = 0; i <= gridXNumber; i++) {
|
|
26
|
-
const x = originX + parseInt(String(xCellWidth * i));
|
|
27
|
-
if (isBirthProcess) {
|
|
28
|
-
const line = drawLine([x, originY, x, endY], { ...defaultBorderStyle, ...((_c = grid.mainLineStyle) == null ? void 0 : _c.y) || {} });
|
|
29
|
-
xList.push(line);
|
|
30
|
-
} else {
|
|
31
|
-
let style = grid.subLineStyle || {};
|
|
32
|
-
if (i % grid.subSecondXCell === 0) {
|
|
33
|
-
style = grid.subSecondLineStyle || {};
|
|
34
|
-
}
|
|
35
|
-
if (i % grid.subXCell === 0) {
|
|
36
|
-
style = i !== 0 && i !== gridXNumber ? ((_d = grid.mainLineStyle) == null ? void 0 : _d.y) || {} : defaultBorderStyle;
|
|
37
|
-
}
|
|
38
|
-
const line = drawLine([x, originY, x, endY], style);
|
|
39
|
-
if (i % grid.subXCell === 0 && i !== 0 && i !== gridXNumber) {
|
|
40
|
-
mainList.add(line);
|
|
41
|
-
} else {
|
|
42
|
-
xList.push(line);
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
const group = new fabric.Group([...xList, ...yList, ...mainList], {
|
|
47
|
-
evented: false,
|
|
48
|
-
selectable: false
|
|
49
|
-
});
|
|
50
|
-
canvas.value.add(group);
|
|
51
|
-
canvas.value.sendToBack(group);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
export { useGrid as default };
|
|
1
|
+
import{fabric as e}from"../utils/index.js";import{drawLine as l,defaultBorderStyle as n}from"./useDraw.js";function i(i,t,s=!1){var o,u,d,r;const{gridYNumber:a,originY:c,grid:S,originX:b,endX:m,xCellWidth:p,yCellHeight:y,gridXNumber:f,endY:g}=t,v=[],C=[],L=new Set;for(let e=0;e<=a;e++){const i=c+parseInt(String(y*(a-e)));if(s){const e=l([b,i,m,i],{...n,...(null==(o=S.mainLineStyle)?void 0:o.x)||{}});v.push(e)}else{const n=e%S.subYCell==0?(null==(u=S.mainLineStyle)?void 0:u.x)||{}:S.subLineStyle||{},t=l([b,i,m,i],n);e%S.subYCell==0?L.add(t):v.push(t)}}for(let e=0;e<=f;e++){const i=b+parseInt(String(p*e));if(s){const e=l([i,c,i,g],{...n,...(null==(d=S.mainLineStyle)?void 0:d.y)||{}});C.push(e)}else{let t=S.subLineStyle||{};e%S.subSecondXCell==0&&(t=S.subSecondLineStyle||{}),e%S.subXCell==0&&(t=0!==e&&e!==f?(null==(r=S.mainLineStyle)?void 0:r.y)||{}:n);const s=l([i,c,i,g],t);e%S.subXCell==0&&0!==e&&e!==f?L.add(s):C.push(s)}}const h=new e.Group([...C,...v,...L],{evented:!1,selectable:!1});i.value.add(h),i.value.sendToBack(h)}export{i as default};
|