cnhis-design-vue 3.1.48-release.2 → 3.1.48-release.4

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 (112) hide show
  1. package/README.md +87 -87
  2. package/es/components/base-search/index.d.ts +13 -0
  3. package/es/components/base-search/src/index.vue.d.ts +13 -0
  4. package/es/components/base-search/src/index.vue2.js +1 -1
  5. package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
  6. package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
  7. package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
  8. package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
  9. package/es/components/card-reader-sdk/src/cardReaderSDK.d.ts +29 -21
  10. package/es/components/card-reader-sdk/src/cardReaderSDK.js +1 -1
  11. package/es/components/card-reader-sdk/src/components/readCardDialog.vue.d.ts +19 -0
  12. package/es/components/card-reader-sdk/src/components/readCardDialog.vue2.js +1 -1
  13. package/es/components/card-reader-sdk/src/constants/index.d.ts +60 -168
  14. package/es/components/card-reader-sdk/src/constants/index.js +1 -1
  15. package/es/components/card-reader-sdk/src/insuranceSDK.d.ts +1 -6
  16. package/es/components/card-reader-sdk/src/insuranceSDK.js +1 -1
  17. package/es/components/card-reader-sdk/src/types/index.d.ts +11 -11
  18. package/es/components/card-reader-sdk/src/utils/index.d.ts +1 -1
  19. package/es/components/card-reader-sdk/src/utils/index.js +1 -1
  20. package/es/components/card-reader-sdk/src/utils/readHealthCard.d.ts +6 -1
  21. package/es/components/card-reader-sdk/src/utils/readHealthCard.js +1 -1
  22. package/es/components/fabric-chart/src/constants/index.d.ts +4 -0
  23. package/es/components/fabric-chart/src/constants/index.js +1 -1
  24. package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcess.js +1 -1
  25. package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcessChart.js +1 -1
  26. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useCenter.d.ts +7 -1
  27. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useCenter.js +1 -1
  28. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useLeft.js +1 -1
  29. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useOther.d.ts +7 -2
  30. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useOther.js +1 -1
  31. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useSurgicalAnesthesiaChart.js +1 -1
  32. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useTop.js +1 -1
  33. package/es/components/fabric-chart/src/hooks/temperature/useBottom.js +1 -1
  34. package/es/components/fabric-chart/src/hooks/temperature/useCenter.js +1 -1
  35. package/es/components/fabric-chart/src/hooks/temperature/useLeft.js +1 -1
  36. package/es/components/fabric-chart/src/hooks/temperature/useOther.js +1 -1
  37. package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +1 -1
  38. package/es/components/fabric-chart/src/hooks/temperature/useTop.js +1 -1
  39. package/es/components/fabric-chart/src/utils/index.d.ts +6 -0
  40. package/es/components/fabric-chart/src/utils/index.js +1 -1
  41. package/es/components/form-config/index.d.ts +28 -0
  42. package/es/components/form-config/src/FormConfig.vue.d.ts +28 -0
  43. package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +12 -0
  44. package/es/components/form-render/src/components/renderer/radio&checkbox.d.ts +13 -0
  45. package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -1
  46. package/es/components/form-render/src/components/renderer/select.d.ts +3 -0
  47. package/es/components/form-render/src/components/renderer/select.js +1 -1
  48. package/es/components/form-render/src/hooks/useBusinessBinding.d.ts +1 -1
  49. package/es/components/form-render/src/hooks/useBusinessBinding.js +1 -1
  50. package/es/components/form-render/src/hooks/useComplexOptions.d.ts +9 -6
  51. package/es/components/form-render/src/hooks/useComplexOptions.js +1 -1
  52. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -1
  53. package/es/components/form-render/src/hooks/useFieldNormalize.js +1 -1
  54. package/es/components/form-render/src/hooks/useFormRenderOptions.d.ts +4 -0
  55. package/es/components/form-render/src/hooks/useFormRenderOptions.js +1 -1
  56. package/es/components/form-render/src/types/fieldItem.d.ts +5 -0
  57. package/es/components/form-render/src/types/index.d.ts +1 -0
  58. package/es/components/form-render/style/index.css +1 -1
  59. package/es/components/iho-table/index.d.ts +8 -3
  60. package/es/components/iho-table/src/IhoTable.vue.d.ts +8 -3
  61. package/es/components/iho-table/src/constants/index.d.ts +4 -5
  62. package/es/components/iho-table/src/constants/index.js +1 -1
  63. package/es/components/iho-table/src/hooks/tapHooks/index.d.ts +1 -0
  64. package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.d.ts +2 -1
  65. package/es/components/iho-table/src/hooks/tapHooks/useEventHooks.js +1 -1
  66. package/es/components/iho-table/src/hooks/useColumnConfigAdaptor.js +1 -1
  67. package/es/components/iho-table/src/plugins/highLightSetPlugin.js +1 -1
  68. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.d.ts +9 -0
  69. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +1 -1
  70. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue.d.ts +2 -2
  71. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/separateRendererPlugin/editSeparate.vue2.js +1 -1
  72. package/es/components/iho-table/src/plugins/rowGroupSettingPlugin/rowGroupUtils.js +1 -1
  73. package/es/components/iho-table/src/plugins/virtualTreePlugin/index.js +1 -1
  74. package/es/components/iho-table/src/types/index.d.ts +3 -1
  75. package/es/components/iho-table/src/types/pluginType.d.ts +5 -3
  76. package/es/components/index.css +1 -1
  77. package/es/components/info-header/style/index.css +1 -1
  78. package/es/components/scale-view/index.d.ts +24 -1
  79. package/es/components/scale-view/src/ScaleView.vue.d.ts +24 -1
  80. package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
  81. package/es/components/scale-view/src/components/DescribeContent.vue.d.ts +21 -0
  82. package/es/components/scale-view/src/components/DescribeContent.vue.js +1 -0
  83. package/es/components/scale-view/src/components/DescribeContent.vue2.js +1 -0
  84. package/es/components/scale-view/src/components/formitem/r-datetime.js +1 -1
  85. package/es/components/scale-view/src/hooks/scaleview-computed.d.ts +6 -2
  86. package/es/components/scale-view/src/hooks/scaleview-computed.js +1 -1
  87. package/es/components/scale-view/src/hooks/scaleview-init.js +1 -1
  88. package/es/components/scale-view/src/utils/judge-types.js +1 -1
  89. package/es/components/scale-view/style/index.css +1 -1
  90. package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
  91. package/es/components/select-person/src/SearchMultiple.vue.d.ts +0 -6
  92. package/es/components/shortcut-setter/index.d.ts +4 -0
  93. package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +4 -0
  94. package/es/components/table-export-field/src/components/ExportModal.vue.d.ts +3 -0
  95. package/es/env.d.ts +25 -25
  96. package/es/shared/assets/img/failure.png.js +1 -1
  97. package/es/shared/assets/img/no-permission.png.js +1 -1
  98. package/es/shared/assets/img/nodata.png.js +1 -1
  99. package/es/shared/assets/img/notfound.png.js +1 -1
  100. package/es/shared/assets/img/qr.png.js +1 -1
  101. package/es/shared/assets/img/success.png.js +1 -1
  102. package/es/shared/assets/img/video.png.js +1 -1
  103. package/es/shared/assets/img/video_default_cover.png.js +1 -1
  104. package/es/shared/assets/img/xb_big.png.js +1 -1
  105. package/es/shared/assets/img/xb_small.png.js +1 -1
  106. package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
  107. package/es/shared/package.json.js +1 -1
  108. package/es/shared/utils/fabricjs/index.d.ts +6823 -0
  109. package/es/shared/utils/tapable/index.d.ts +139 -0
  110. package/es/shared/utils/tapableLess.d.ts +28 -0
  111. package/es/shared/utils/tapableLess.js +1 -0
  112. package/package.json +2 -2
@@ -1 +1 @@
1
- import{eventListener2EventName as e}from"../utils/index.js";var o=(e=>(e.DEFAULT="DEFAULT",e.PICTURE="PICTURE",e.FILE="FILE",e.MONEY="MONEY",e.HEADPORTRAIT="HEADPORTRAIT",e.LABEL="LABEL",e.TELEPHONE="TELEPHONE",e.BIRTHDAY="BIRTHDAY",e.MULTISELECT="MULTISELECT",e.CASCADE="CASCADE",e.SEARCH_TREE="SEARCH_TREE",e.COLOR="COLOR",e.EVALUATE="EVALUATE",e.MAP="MAP",e.VIDEO="VIDEO",e.SYSTEMFIELDS="SYSTEMFIELDS",e.PERCENTAGE="PERCENTAGE",e.HTML="HTML",e.CANDIDATE_COMPONENTS="CANDIDATE_COMPONENTS",e.TASKDATE="TASKDATE",e.AGE="AGE",e.STATUS="STATUS",e.WEBSITE="WEBSITE",e.IDCARD="IDCARD",e.COUNTDOWN="COUNTDOWN",e.DURATION="DURATION",e.COMBINATION="COMBINATION",e.PASSWORD="PASSWORD",e.QR_CODE="QR_CODE",e.CUSTOMER_NAME="CUSTOMER_NAME",e.BANK_CARD="BANK_CARD",e.SEQUENCE="SEQUENCE",e.VARIABLE_HEIGHT="VARIABLE_HEIGHT",e))(o||{});const n=Object.freeze(["onKeydownStart","onKeydown","onKeydownEnd","onPaste","onCopy","onCut","onCurrentChange","onRadioChange","onCheckboxChange","onCheckboxAll","onCheckboxRangeStart","onCheckboxRangeChange","onCheckboxRangeEnd","onCellClick","onCellDblclick","onCellMenu","onCellMouseenter","onCellMouseleave","onHeaderCellClick","onHeaderCellDblclick","onHeaderCellMenu","onFooterCellClick","onFooterCellDblclick","onFooterCellMenu","onSortChange","onFilterChange","onFilterVisible","onResizableChange","onToggleRowExpand","onToggleTreeExpand","onMenuClick","onEditClosed","onEditActived","onEditDisabled","onValidError","onScroll","onCustom","onOpenFnr","onFnrChange","onFnrFind","onFnrFindAll","onFnrReplace","onFnrReplaceAll","onCellAreaCopy","onCellAreaCut","onCellAreaPaste","onCellAreaMerge","onClearCellAreaMerge","onHeaderCellAreaSelection","onCellAreaSelectionStart","onCellAreaSelectionDrag","onCellAreaSelectionEnd","onCellAreaExtensionStart","onCellAreaExtensionDrag","onCellAreaExtensionEnd","onCellAreaArrowsStart","onCellAreaArrowsEnd","onActiveCellChangeStart","onActiveCellChangeEnd"]),E=n.map(e),l=Object.freeze(["firstRowGroup","secondRowGroup","thirdRowGroup","fourthRowGroup","fifthRowGroup","sixthRowGroup","seventhRowGroup","eighthRowGroup","ninthRowGroup","tenthRowGroup"]),C=-1/0,A=1/0;var T=(e=>(e.INPUT="INPUT",e.SEPARATE="SEPARATE",e.SELECT="SELECT",e.SELECT_MORE="SELECT_MORE",e.DATE="DATE",e.TIME="TIME",e.NUMBER="NUMBER",e.RADIO="RADIO",e))(T||{}),r=(e=>(e[e.NEGATIVE=0]="NEGATIVE",e[e.POSITIVE=1]="POSITIVE",e))(r||{}),t=(e=>(e.NEGATIVE="0",e.POSITIVE="1",e))(t||{}),a=(e=>(e.NOT_TREE="0",e.UNKNOWN="1",e.TRANSFORM_TREE_TYPE="2",e.TRANSFORM_WITH_SPAN_METHOD="3",e))(a||{}),I=(e=>(e[e.left=1]="left",e[e.right=2]="right",e))(I||{});const R=["formChange","settingClick","formClick","keyboard","rowDrag"],S=[...R,...E],i=Symbol("injectionIhoTableConfig"),O=Symbol("injectionIhoTableFieldList"),D=Symbol("InjectionIhoTableEmits"),N=Symbol("InjectionIhoTableAnnotation"),c=Symbol("InjectionIhoTableUUID"),h=Symbol("InjectionIhoTableInstance"),M=Symbol("InjectionIhoTableHandler"),d=Symbol("InjectionIhoTableEventListener");export{T as EDITABLE_WIDGET_TYPE,C as HIGHEST_PRIORITY,I as IHO_TABLE_FIXED_STATUS,r as IHO_TABLE_NUMBER_STATUS,t as IHO_TABLE_STRING_STATUS,a as IHO_TABLE_TREE_TYPE,R as IhoTableCustomEventNameTuple,S as IhoTableEventNameTuple,l as IhoTableRowGroupSequence,N as InjectionIhoTableAnnotation,i as InjectionIhoTableConfig,D as InjectionIhoTableEmits,d as InjectionIhoTableEventListener,O as InjectionIhoTableFieldList,M as InjectionIhoTableHandler,h as InjectionIhoTableInstance,c as InjectionIhoTableUUID,A as LOWEST_PRIORITY,n as VxeEventListenerNameList,E as VxeTableEventNameList,o as WIDGET_TYPE};
1
+ import{eventListener2EventName as e}from"../utils/index.js";var o=(e=>(e.DEFAULT="DEFAULT",e.PICTURE="PICTURE",e.FILE="FILE",e.MONEY="MONEY",e.HEADPORTRAIT="HEADPORTRAIT",e.LABEL="LABEL",e.TELEPHONE="TELEPHONE",e.BIRTHDAY="BIRTHDAY",e.MULTISELECT="MULTISELECT",e.CASCADE="CASCADE",e.SEARCH_TREE="SEARCH_TREE",e.COLOR="COLOR",e.EVALUATE="EVALUATE",e.MAP="MAP",e.VIDEO="VIDEO",e.SYSTEMFIELDS="SYSTEMFIELDS",e.PERCENTAGE="PERCENTAGE",e.HTML="HTML",e.CANDIDATE_COMPONENTS="CANDIDATE_COMPONENTS",e.TASKDATE="TASKDATE",e.AGE="AGE",e.STATUS="STATUS",e.WEBSITE="WEBSITE",e.IDCARD="IDCARD",e.COUNTDOWN="COUNTDOWN",e.DURATION="DURATION",e.COMBINATION="COMBINATION",e.PASSWORD="PASSWORD",e.QR_CODE="QR_CODE",e.CUSTOMER_NAME="CUSTOMER_NAME",e.BANK_CARD="BANK_CARD",e.SEQUENCE="SEQUENCE",e.VARIABLE_HEIGHT="VARIABLE_HEIGHT",e))(o||{});const n=Object.freeze(["onKeydownStart","onKeydown","onKeydownEnd","onPaste","onCopy","onCut","onCurrentChange","onRadioChange","onCheckboxChange","onCheckboxAll","onCheckboxRangeStart","onCheckboxRangeChange","onCheckboxRangeEnd","onCellClick","onCellDblclick","onCellMenu","onCellMouseenter","onCellMouseleave","onHeaderCellClick","onHeaderCellDblclick","onHeaderCellMenu","onFooterCellClick","onFooterCellDblclick","onFooterCellMenu","onSortChange","onFilterChange","onFilterVisible","onResizableChange","onToggleRowExpand","onToggleTreeExpand","onMenuClick","onEditClosed","onEditActived","onEditDisabled","onValidError","onScroll","onCustom","onOpenFnr","onFnrChange","onFnrFind","onFnrFindAll","onFnrReplace","onFnrReplaceAll","onCellAreaCopy","onCellAreaCut","onCellAreaPaste","onCellAreaMerge","onClearCellAreaMerge","onHeaderCellAreaSelection","onCellAreaSelectionStart","onCellAreaSelectionDrag","onCellAreaSelectionEnd","onCellAreaExtensionStart","onCellAreaExtensionDrag","onCellAreaExtensionEnd","onCellAreaArrowsStart","onCellAreaArrowsEnd","onActiveCellChangeStart","onActiveCellChangeEnd","onPageChange"]),E=n.map(e),l=Object.freeze(["firstRowGroup","secondRowGroup","thirdRowGroup","fourthRowGroup","fifthRowGroup","sixthRowGroup","seventhRowGroup","eighthRowGroup","ninthRowGroup","tenthRowGroup"]),C=-1/0,A=1/0;var T=(e=>(e.INPUT="INPUT",e.SEPARATE="SEPARATE",e.SELECT="SELECT",e.SELECT_MORE="SELECT_MORE",e.DATE="DATE",e.TIME="TIME",e.NUMBER="NUMBER",e.RADIO="RADIO",e))(T||{}),r=(e=>(e[e.NEGATIVE=0]="NEGATIVE",e[e.POSITIVE=1]="POSITIVE",e))(r||{}),t=(e=>(e.NEGATIVE="0",e.POSITIVE="1",e))(t||{}),a=(e=>(e.NOT_TREE="0",e.UNKNOWN="1",e.TRANSFORM_TREE_TYPE="2",e.TRANSFORM_WITH_SPAN_METHOD="3",e))(a||{}),I=(e=>(e[e.left=1]="left",e[e.right=2]="right",e))(I||{});const R=["formChange","settingClick","formClick","keyboard","rowDrag"],S=[...R,...E],i=Symbol("injectionIhoTableConfig"),O=Symbol("injectionIhoTableFieldList"),D=Symbol("InjectionIhoTableEmits"),N=Symbol("InjectionIhoTableAnnotation"),c=Symbol("InjectionIhoTableUUID"),h=Symbol("InjectionIhoTableInstance"),M=Symbol("InjectionIhoTableHandler"),d=Symbol("InjectionIhoTableEventListener");export{T as EDITABLE_WIDGET_TYPE,C as HIGHEST_PRIORITY,I as IHO_TABLE_FIXED_STATUS,r as IHO_TABLE_NUMBER_STATUS,t as IHO_TABLE_STRING_STATUS,a as IHO_TABLE_TREE_TYPE,R as IhoTableCustomEventNameTuple,S as IhoTableEventNameTuple,l as IhoTableRowGroupSequence,N as InjectionIhoTableAnnotation,i as InjectionIhoTableConfig,D as InjectionIhoTableEmits,d as InjectionIhoTableEventListener,O as InjectionIhoTableFieldList,M as InjectionIhoTableHandler,h as InjectionIhoTableInstance,c as InjectionIhoTableUUID,A as LOWEST_PRIORITY,n as VxeEventListenerNameList,E as VxeTableEventNameList,o as WIDGET_TYPE};
@@ -83,6 +83,7 @@ export declare function createTableEventHandlers({ hooks, config, $table, emits,
83
83
  onCellAreaArrowsEnd: import("vxe-table").VxeTableEvents.CellAreaArrowsEnd | undefined;
84
84
  onActiveCellChangeStart: import("vxe-table").VxeTableEvents.ActiveCellChangeStart | undefined;
85
85
  onActiveCellChangeEnd: import("vxe-table").VxeTableEvents.ActiveCellChangeEnd | undefined;
86
+ onPageChange: unknown;
86
87
  };
87
88
  export declare function createDataTransfer(hooks: TableHooks, config: MaybeRef<IhoTableConfig>, $table: MaybeRef<Nullable<VxeTableInstance>>): (data: AnyObject[]) => Promise<AnyObject[]>;
88
89
  export declare function createDomInsertComponent(hooks: TableHooks): {
@@ -63,12 +63,13 @@ declare class EventHooks extends AbstractEventHooks {
63
63
  readonly onActiveCellChangeEnd: AsyncParallelHook<[import("vxe-table").VxeTableProDefines.ActiveCellChangeEndEventParams, import("../../../../../../es/components/iho-table/src/types").IhoTableConfig, import("../../../../../../es/components/iho-table/src/types").IhoTableHandler & import("../../../../../../es/components/iho-table/src/types").IhoTableHandlerContext<false>], import("../../../../../../es/shared/utils/tapable").UnsetAdditionalOptions>;
64
64
  readonly onCellAreaSelectionAllStart: AsyncParallelHook<[any, import("../../../../../../es/components/iho-table/src/types").IhoTableConfig, import("../../../../../../es/components/iho-table/src/types").IhoTableHandler & import("../../../../../../es/components/iho-table/src/types").IhoTableHandlerContext<false>], import("../../../../../../es/shared/utils/tapable").UnsetAdditionalOptions>;
65
65
  readonly onCellAreaSelectionAllEnd: AsyncParallelHook<[any, import("../../../../../../es/components/iho-table/src/types").IhoTableConfig, import("../../../../../../es/components/iho-table/src/types").IhoTableHandler & import("../../../../../../es/components/iho-table/src/types").IhoTableHandlerContext<false>], import("../../../../../../es/shared/utils/tapable").UnsetAdditionalOptions>;
66
+ readonly onPageChange: AsyncParallelHook<[import("vxe-table/types/pager").VxePagerDefines.PageChangeEventParams, import("../../../../../../es/components/iho-table/src/types").IhoTableConfig, import("../../../../../../es/components/iho-table/src/types").IhoTableHandler & import("../../../../../../es/components/iho-table/src/types").IhoTableHandlerContext<false>], import("../../../../../../es/shared/utils/tapable").UnsetAdditionalOptions>;
66
67
  }
67
68
  export declare function useEventHooks(): {
68
69
  create: () => EventHooks;
69
70
  };
70
71
  export declare class IhoTableEventListener {
71
- eventMap: Map<"toggleRowExpand" | "toggleTreeExpand" | "copy" | "scroll" | "formChange" | "settingClick" | "formClick" | "keyboard" | "rowDrag" | "cut" | "paste" | "keydown" | "keydownStart" | "keydownEnd" | "currentChange" | "radioChange" | "checkboxChange" | "checkboxAll" | "checkboxRangeStart" | "checkboxRangeChange" | "checkboxRangeEnd" | "cellClick" | "cellDblclick" | "cellMenu" | "cellMouseenter" | "cellMouseleave" | "headerCellClick" | "headerCellDblclick" | "headerCellMenu" | "footerCellClick" | "footerCellDblclick" | "footerCellMenu" | "sortChange" | "filterChange" | "filterVisible" | "resizableChange" | "menuClick" | "editClosed" | "editActived" | "editDisabled" | "validError" | "custom" | "openFnr" | "fnrChange" | "fnrFind" | "fnrFindAll" | "fnrReplace" | "fnrReplaceAll" | "cellAreaCopy" | "cellAreaCut" | "cellAreaPaste" | "cellAreaMerge" | "clearCellAreaMerge" | "headerCellAreaSelection" | "cellAreaSelectionStart" | "cellAreaSelectionDrag" | "cellAreaSelectionEnd" | "cellAreaExtensionStart" | "cellAreaExtensionDrag" | "cellAreaExtensionEnd" | "cellAreaArrowsStart" | "cellAreaArrowsEnd" | "activeCellChangeStart" | "activeCellChangeEnd", Set<Func<any[], any>>>;
72
+ eventMap: Map<"toggleRowExpand" | "toggleTreeExpand" | "copy" | "scroll" | "formChange" | "settingClick" | "formClick" | "keyboard" | "rowDrag" | "cut" | "paste" | "keydown" | "keydownStart" | "keydownEnd" | "currentChange" | "radioChange" | "checkboxChange" | "checkboxAll" | "checkboxRangeStart" | "checkboxRangeChange" | "checkboxRangeEnd" | "cellClick" | "cellDblclick" | "cellMenu" | "cellMouseenter" | "cellMouseleave" | "headerCellClick" | "headerCellDblclick" | "headerCellMenu" | "footerCellClick" | "footerCellDblclick" | "footerCellMenu" | "sortChange" | "filterChange" | "filterVisible" | "resizableChange" | "menuClick" | "editClosed" | "editActived" | "editDisabled" | "validError" | "custom" | "openFnr" | "fnrChange" | "fnrFind" | "fnrFindAll" | "fnrReplace" | "fnrReplaceAll" | "cellAreaCopy" | "cellAreaCut" | "cellAreaPaste" | "cellAreaMerge" | "clearCellAreaMerge" | "headerCellAreaSelection" | "cellAreaSelectionStart" | "cellAreaSelectionDrag" | "cellAreaSelectionEnd" | "cellAreaExtensionStart" | "cellAreaExtensionDrag" | "cellAreaExtensionEnd" | "cellAreaArrowsStart" | "cellAreaArrowsEnd" | "activeCellChangeStart" | "activeCellChangeEnd" | "pageChange", Set<Func<any[], any>>>;
72
73
  addEventListener<T extends IhoTableEventNameUnion>(key: T, handler: (...payload: IhoTableEmitPayload<T>) => void): void;
73
74
  trigger<T extends IhoTableEventNameUnion>(key: T, ...payload: IhoTableEmitPayload<T>): void;
74
75
  }
@@ -1 +1 @@
1
- import"../../../../../shared/utils/tapable/SyncHook.js";import"../../../../../shared/utils/tapable/SyncBailHook.js";import"../../../../../shared/utils/tapable/SyncWaterfallHook.js";import"../../../../../shared/utils/tapable/SyncLoopHook.js";import e from"../../../../../shared/utils/tapable/AsyncParallelHook.js";import"../../../../../shared/utils/tapable/AsyncParallelBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";import{getCurrentInstance as n,onMounted as t,onBeforeUnmount as o,provide as i}from"vue";import{InjectionIhoTableEventListener as c}from"../../constants/index.js";import{AbstractEventHooks as s}from"../../types/pluginType.js";class l extends s{constructor(){super(...arguments),this.onKeydownStart=new e(["event","context","config"]),this.onKeydown=new e(["event","context","config"]),this.onKeydownEnd=new e(["event","context","config"]),this.onPaste=new e(["event","context","config"]),this.onCopy=new e(["event","context","config"]),this.onCut=new e(["event","context","config"]),this.onCurrentChange=new e(["event","context","config"]),this.onRadioChange=new e(["event","context","config"]),this.onCheckboxChange=new e(["event","context","config"]),this.onCheckboxAll=new e(["event","context","config"]),this.onCheckboxRangeStart=new e(["event","context","config"]),this.onCheckboxRangeChange=new e(["event","context","config"]),this.onCheckboxRangeEnd=new e(["event","context","config"]),this.onCellClick=new e(["event","context","config"]),this.onCellDblclick=new e(["event","context","config"]),this.onCellMenu=new e(["event","context","config"]),this.onCellMouseenter=new e(["event","context","config"]),this.onCellMouseleave=new e(["event","context","config"]),this.onHeaderCellClick=new e(["event","context","config"]),this.onHeaderCellDblclick=new e(["event","context","config"]),this.onHeaderCellMenu=new e(["event","context","config"]),this.onFooterCellClick=new e(["event","context","config"]),this.onFooterCellDblclick=new e(["event","context","config"]),this.onFooterCellMenu=new e(["event","context","config"]),this.onSortChange=new e(["event","context","config"]),this.onFilterChange=new e(["event","context","config"]),this.onFilterVisible=new e(["event","context","config"]),this.onResizableChange=new e(["event","context","config"]),this.onToggleRowExpand=new e(["event","context","config"]),this.onToggleTreeExpand=new e(["event","context","config"]),this.onMenuClick=new e(["event","context","config"]),this.onEditClosed=new e(["event","context","config"]),this.onEditActived=new e(["event","context","config"]),this.onEditDisabled=new e(["event","context","config"]),this.onValidError=new e(["event","context","config"]),this.onScroll=new e(["event","context","config"]),this.onCustom=new e(["event","context","config"]),this.onOpenFnr=new e(["event","context","config"]),this.onFnrChange=new e(["event","context","config"]),this.onFnrFind=new e(["event","context","config"]),this.onFnrFindAll=new e(["event","context","config"]),this.onFnrReplace=new e(["event","context","config"]),this.onFnrReplaceAll=new e(["event","context","config"]),this.onCellAreaCopy=new e(["event","context","config"]),this.onCellAreaCut=new e(["event","context","config"]),this.onCellAreaPaste=new e(["event","context","config"]),this.onCellAreaMerge=new e(["event","context","config"]),this.onClearCellAreaMerge=new e(["event","context","config"]),this.onHeaderCellAreaSelection=new e(["event","context","config"]),this.onCellAreaSelectionStart=new e(["event","context","config"]),this.onCellAreaSelectionDrag=new e(["event","context","config"]),this.onCellAreaSelectionEnd=new e(["event","context","config"]),this.onCellAreaExtensionStart=new e(["event","context","config"]),this.onCellAreaExtensionDrag=new e(["event","context","config"]),this.onCellAreaExtensionEnd=new e(["event","context","config"]),this.onCellAreaArrowsStart=new e(["event","context","config"]),this.onCellAreaArrowsEnd=new e(["event","context","config"]),this.onActiveCellChangeStart=new e(["event","context","config"]),this.onActiveCellChangeEnd=new e(["event","context","config"]),this.onCellAreaSelectionAllStart=new e(["event","context","config"]),this.onCellAreaSelectionAllEnd=new e(["event","context","config"])}}function r(){return{create:function(){return new l}}}class a{constructor(){this.eventMap=new Map}addEventListener(e,i){if(!n())throw new Error("addEventListener can only used in setup environment!");const c=this.eventMap.get(e)||new Set;this.eventMap.set(e,c),t((()=>c.add(i))),o((()=>c.delete(i)))}trigger(e,...n){var t;null==(t=this.eventMap.get(e))||t.forEach((e=>{e(...n)}))}}function h(){if(!n())throw new Error("provideIhoTableEventListener can only used in setup environment!");const e=new a;return i(c,e),e}export{a as IhoTableEventListener,h as provideIhoTableEventListener,r as useEventHooks};
1
+ import"../../../../../shared/utils/tapable/SyncHook.js";import"../../../../../shared/utils/tapable/SyncBailHook.js";import"../../../../../shared/utils/tapable/SyncWaterfallHook.js";import"../../../../../shared/utils/tapable/SyncLoopHook.js";import e from"../../../../../shared/utils/tapable/AsyncParallelHook.js";import"../../../../../shared/utils/tapable/AsyncParallelBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";import{getCurrentInstance as n,onMounted as t,onBeforeUnmount as o,provide as i}from"vue";import{InjectionIhoTableEventListener as c}from"../../constants/index.js";import{AbstractEventHooks as s}from"../../types/pluginType.js";class l extends s{constructor(){super(...arguments),this.onKeydownStart=new e(["event","context","config"]),this.onKeydown=new e(["event","context","config"]),this.onKeydownEnd=new e(["event","context","config"]),this.onPaste=new e(["event","context","config"]),this.onCopy=new e(["event","context","config"]),this.onCut=new e(["event","context","config"]),this.onCurrentChange=new e(["event","context","config"]),this.onRadioChange=new e(["event","context","config"]),this.onCheckboxChange=new e(["event","context","config"]),this.onCheckboxAll=new e(["event","context","config"]),this.onCheckboxRangeStart=new e(["event","context","config"]),this.onCheckboxRangeChange=new e(["event","context","config"]),this.onCheckboxRangeEnd=new e(["event","context","config"]),this.onCellClick=new e(["event","context","config"]),this.onCellDblclick=new e(["event","context","config"]),this.onCellMenu=new e(["event","context","config"]),this.onCellMouseenter=new e(["event","context","config"]),this.onCellMouseleave=new e(["event","context","config"]),this.onHeaderCellClick=new e(["event","context","config"]),this.onHeaderCellDblclick=new e(["event","context","config"]),this.onHeaderCellMenu=new e(["event","context","config"]),this.onFooterCellClick=new e(["event","context","config"]),this.onFooterCellDblclick=new e(["event","context","config"]),this.onFooterCellMenu=new e(["event","context","config"]),this.onSortChange=new e(["event","context","config"]),this.onFilterChange=new e(["event","context","config"]),this.onFilterVisible=new e(["event","context","config"]),this.onResizableChange=new e(["event","context","config"]),this.onToggleRowExpand=new e(["event","context","config"]),this.onToggleTreeExpand=new e(["event","context","config"]),this.onMenuClick=new e(["event","context","config"]),this.onEditClosed=new e(["event","context","config"]),this.onEditActived=new e(["event","context","config"]),this.onEditDisabled=new e(["event","context","config"]),this.onValidError=new e(["event","context","config"]),this.onScroll=new e(["event","context","config"]),this.onCustom=new e(["event","context","config"]),this.onOpenFnr=new e(["event","context","config"]),this.onFnrChange=new e(["event","context","config"]),this.onFnrFind=new e(["event","context","config"]),this.onFnrFindAll=new e(["event","context","config"]),this.onFnrReplace=new e(["event","context","config"]),this.onFnrReplaceAll=new e(["event","context","config"]),this.onCellAreaCopy=new e(["event","context","config"]),this.onCellAreaCut=new e(["event","context","config"]),this.onCellAreaPaste=new e(["event","context","config"]),this.onCellAreaMerge=new e(["event","context","config"]),this.onClearCellAreaMerge=new e(["event","context","config"]),this.onHeaderCellAreaSelection=new e(["event","context","config"]),this.onCellAreaSelectionStart=new e(["event","context","config"]),this.onCellAreaSelectionDrag=new e(["event","context","config"]),this.onCellAreaSelectionEnd=new e(["event","context","config"]),this.onCellAreaExtensionStart=new e(["event","context","config"]),this.onCellAreaExtensionDrag=new e(["event","context","config"]),this.onCellAreaExtensionEnd=new e(["event","context","config"]),this.onCellAreaArrowsStart=new e(["event","context","config"]),this.onCellAreaArrowsEnd=new e(["event","context","config"]),this.onActiveCellChangeStart=new e(["event","context","config"]),this.onActiveCellChangeEnd=new e(["event","context","config"]),this.onCellAreaSelectionAllStart=new e(["event","context","config"]),this.onCellAreaSelectionAllEnd=new e(["event","context","config"]),this.onPageChange=new e(["event","context","config"])}}function r(){return{create:function(){return new l}}}class a{constructor(){this.eventMap=new Map}addEventListener(e,i){if(!n())throw new Error("addEventListener can only used in setup environment!");const c=this.eventMap.get(e)||new Set;this.eventMap.set(e,c),t((()=>c.add(i))),o((()=>c.delete(i)))}trigger(e,...n){var t;null==(t=this.eventMap.get(e))||t.forEach((e=>{e(...n)}))}}function h(){if(!n())throw new Error("provideIhoTableEventListener can only used in setup environment!");const e=new a;return i(c,e),e}export{a as IhoTableEventListener,h as provideIhoTableEventListener,r as useEventHooks};
@@ -1 +1 @@
1
- import{cloneDeep as e,isString as t,isFunction as n,pick as o,isArray as i,isNumber as a}from"lodash-es";import{isObject as r}from"@vue/shared";const s=Symbol("remove property");function l(){return{formConfigLikeAdaptor:function(l){const p={};return r(l)?{fieldList:function(l){const m=new Map([["NONE",0],["LEFT",1],["RIGHT",2]]),u=new Map([["0",0],["1",1]]),c=new Map([...["RADIO","RADIO_BLOCK","CHECKBOX","CHECKBOX_BLOCK","SELECT","SEARCH","SEARCH_MORE","SWITCH_COMPONENT"].map((e=>[e,"select"])),...["DATE"].map((e=>[e,"date"])),...["INPUT"].map((e=>[e,"input"])),...["DIGITAL"].map((e=>[e,"number"]))]),d=(e,t)=>{if(!r(e))return;const n={label:e.describe,...e};t.options=i(t.options)?[...t.options,n]:[n]},f=(e,n)=>{0!==e&&"0"!==e&&e&&(t(e)||a(e))&&(console.log("value=>",e),n.componentProps={maxTagCount:+e,...n.componentProps})},_=new Map([["multi_select_value",f],["is_null",(e,t,n,o)=>{"1"!==e&&"0"===e&&(o[n.val_key]=[{required:!0,message:"必填"}])}],["validate",(e,t)=>{if(!r(e))return;t.componentProps={...Object.entries({maxlength:"max_length",minlength:"min_length",max:"max_value",min:"min_value",precision:"decimal_length"}).reduce(((t,[n,o])=>(t[n]=e[o],t)),{}),...t.componentProps}}],["dateValidate",(e,t)=>{r(e)&&(t.isDateDisabled=(t,n)=>{if(!r(n))return;const{startDate:o,endDate:i}=e;let a=!1;return o&&(a=new Date(n[o]).getTime()>t),i&&(a=a||new Date(n[i]).getTime()<t),a})}],["date_format","valueFormat"],...["open","close"].map((e=>[e,d])),["is_edit",{property:"isEdit",valueMap:u}],["html_type",(e,n,o)=>{var i;if(!t(e))return;if("DATE"===e)return void(n.formType=t(o.date_format)&&o.date_format.startsWith("HH:mm")?"time":"date");n.formType=null!=(i=c.get(e))?i:e;const a="SEARCH"!==e&&("SEARCH_MORE"===e||("SELECT"===e?"0"===o.multi_select:null));a&&(n.componentProps={multiple:a,...n.componentProps})}],["option",{property:"options",fieldMap:new Map([["text","label"]])}],...["alias","name"].map((e=>[e,(e,t,n)=>{var o;t.title=`${null!=(o=n.alias)?o:n.name}${n.suffix?`(${n.suffix})`:""}`}]))]),v=new Map([["sum","isSum"],["show","isShow"],["elementId","columnName"],["columnWidth","colWidth"],["fixedWayEnum",{property:"isFixed",valueMap:m}],["multi_select_value",f],["setting",{fieldMap:_,assign:!0}]]);return l.map((e=>E(e,p,v)));function E(a,l,p){if(!p)return e(a);const m={};return Object.entries(a).forEach((([e,o])=>{const i=p.get(e);return i?i!==s?t(i)?m[i]=o:n(i)?i(o,m,a,l):void(r(i)&&(i.assign?Object.assign(m,u(o,i)):m[i.property||e]=u(o,i))):void 0:m[e]=o})),m.componentProps=Object.assign({},m.componentProps,o(m,["options","isDateDisabled"])),m;function u(e,t){var o,a;return!r(t)||n(t)?e:i(e)?e.map((e=>u(e,t))):r(e)?E(e,l,t.fieldMap):null!=(a=null==(o=t.valueMap)?void 0:o.get(e))?a:e}}}(l.fieldList),editRules:p}:{fieldList:[],editRules:p}}}}export{l as useColumnConfigAdaptor};
1
+ import{cloneDeep as e,isString as t,isFunction as n,pick as o,isArray as a,isNumber as i}from"lodash-es";import{isObject as r}from"@vue/shared";const s=Symbol("remove property");function l(){return{formConfigLikeAdaptor:function(l){const p={};return r(l)?{fieldList:function(l){const m=new Map([["NONE",0],["LEFT",1],["RIGHT",2]]),u=new Map([["0",0],["1",1]]),c=new Map([...["RADIO","RADIO_BLOCK","CHECKBOX","CHECKBOX_BLOCK","SELECT","SEARCH","SEARCH_MORE","SWITCH_COMPONENT"].map((e=>[e,"select"])),...["DATE"].map((e=>[e,"date"])),...["INPUT"].map((e=>[e,"input"])),...["DIGITAL"].map((e=>[e,"number"]))]),d=(e,t)=>{if(!r(e))return;const n={label:e.describe,...e};t.options=a(t.options)?[...t.options,n]:[n]},f=(e,n)=>{0!==e&&"0"!==e&&e&&(t(e)||i(e))&&(console.log("value=>",e),n.componentProps={maxTagCount:+e,...n.componentProps})},_=new Map([["multi_select_value",f],["is_null",(e,t,n,o)=>{"1"!==e&&"0"===e&&(o[n.val_key]=[{required:!0,message:"必填"}])}],["validate",(e,t)=>{if(!r(e))return;t.componentProps={...Object.entries({maxlength:"max_length",minlength:"min_length",max:"max_value",min:"min_value",precision:"decimal_length"}).reduce(((t,[n,o])=>(t[n]=e[o],t)),{}),...t.componentProps}}],["dateValidate",(e,t)=>{r(e)&&(t.isDateDisabled=(t,n)=>{if(!r(n))return;const{startDate:o,endDate:a}=e;let i=!1;return o&&(i=new Date(n[o]).getTime()>t),a&&(i=i||new Date(n[a]).getTime()<t),i})}],["date_format","valueFormat"],...["open","close"].map((e=>[e,d])),["is_edit",{property:"isEdit",valueMap:u}],["free_entry",(e,t,n)=>{t.componentProps={...t.componentProps,allowCreate:"1"===e||1===e,shouldSave:"1"===n.save_free_entry||1===n.save_free_entry}}],["html_type",(e,n,o)=>{var a;if(!t(e))return;if("DATE"===e)return void(n.formType=t(o.date_format)&&o.date_format.startsWith("HH:mm")?"time":"date");n.formType=null!=(a=c.get(e))?a:e;const i="SEARCH"!==e&&("SEARCH_MORE"===e||("SELECT"===e?"0"===o.multi_select:null));i&&(n.componentProps={multiple:i,...n.componentProps})}],["option",{property:"options",fieldMap:new Map([["text","label"]])}],...["alias","name"].map((e=>[e,(e,t,n)=>{var o;t.title=`${null!=(o=n.alias)?o:n.name}${n.suffix?`(${n.suffix})`:""}`}]))]),v=new Map([["sum","isSum"],["show","isShow"],["elementId","columnName"],["columnWidth","colWidth"],["fixedWayEnum",{property:"isFixed",valueMap:m}],["multi_select_value",f],["setting",{fieldMap:_,assign:!0}]]);return l.map((e=>E(e,p,v)));function E(i,l,p){if(!p)return e(i);const m={};return Object.entries(i).forEach((([e,o])=>{const a=p.get(e);return a?a!==s?t(a)?m[a]=o:n(a)?a(o,m,i,l):void(r(a)&&(a.assign?Object.assign(m,u(o,a)):m[a.property||e]=u(o,a))):void 0:m[e]=o})),m.componentProps=Object.assign({},m.componentProps,o(m,["options","isDateDisabled"])),m;function u(e,t){var o,i;return!r(t)||n(t)?e:a(e)?e.map((e=>u(e,t))):r(e)?E(e,l,t.fieldMap):null!=(i=null==(o=t.valueMap)?void 0:o.get(e))?i:e}}}(l.fieldList),editRules:p}:{fieldList:[],editRules:p}}}}export{l as useColumnConfigAdaptor};
@@ -1 +1 @@
1
- import{hex2rgba as o}from"../../../../shared/utils/index.js";import{isFunction as r,isString as t,isObject as n}from"lodash-es";import"../../index.js";import{useUUIDMap as e}from"../utils/index.js";import{defineTablePlugin as s}from"../hooks/useTablePlugin.js";function u(){const u="highLightSetPlugin",{getItemFromUUID:i,removeItemFromUUID:l,setItemFromUUID:a}=e((()=>!1));return s({name:u,apply(e){e.dataHooks.data.tapPromise(u,(async(o,r)=>{r.uuid&&(o.rowColor||o.fontColor)&&a(r.uuid,!0)})),e.dataHooks.dataEnd.tap(u,(e=>{if(!e.uuid||!i(e.uuid))return;const s=e.rowStyle;e.rowStyle=function(t){if(t.row.rowColor||t.row.fontColor){const[n,e,u,i]=o(t.row.rowColor||"",.2),l={"--row-background-color":`rgba(${n}, ${e}, ${u}, ${i})`,color:t.row.fontColor};return r(s)?Object.assign(l,s(t)):l}return r(s)?s(t):null};const u=e.rowClassName;e.rowClassName=function(o){if(o.row.rowColor){const e="row--custom";if(t(u))return`${e} ${u}`;if(r(u)){const r=u(o);return n(r)?Object.assign({"row--custom":!0},r):t(r)?`${e} ${r}`:null}return e}return r(u)?u(o):t(u)?u:null},l(e.uuid)}))}})}export{u as highLightSetPlugin};
1
+ import{traverse as o,hex2rgba as r}from"../../../../shared/utils/index.js";import{isFunction as t,isString as n,isObject as e}from"lodash-es";import"../../index.js";import{useUUIDMap as i}from"../utils/index.js";import{defineTablePlugin as u}from"../hooks/useTablePlugin.js";function s(){const s="highLightSetPlugin",{getItemFromUUID:l,removeItemFromUUID:a,setItemFromUUID:m}=i((()=>!1));return u({name:s,apply(i){i.dataHooks.data.tapPromise(s,(async(r,t)=>{if(!t.uuid||l(t.uuid))return;let n=!1;o(r,((o,r)=>{(o.rowColor||o.fontColor)&&(n=!0,r())}),["children","childrenList"]),n&&m(t.uuid,!0)})),i.dataHooks.dataEnd.tap(s,(o=>{if(!o.uuid||!l(o.uuid))return;const i=o.rowStyle;o.rowStyle=function(o){if(o.row.rowColor||o.row.fontColor){const[n,e,u,s]=r(o.row.rowColor||"",.2),l={"--row-background-color":`rgba(${n}, ${e}, ${u}, ${s})`,color:o.row.fontColor};return t(i)?Object.assign(l,i(o)):l}return t(i)?i(o):null};const u=o.rowClassName;o.rowClassName=function(o){if(o.row.rowColor){const r="row--custom";if(n(u))return`${r} ${u}`;if(t(u)){const t=u(o);return e(t)?Object.assign({"row--custom":!0},t):n(t)?`${r} ${t}`:null}return r}return t(u)?u(o):n(u)?u:null},a(o.uuid)}))}})}export{s as highLightSetPlugin};
@@ -33,6 +33,10 @@ declare const _default: import("vue").DefineComponent<{
33
33
  type: BooleanConstructor;
34
34
  default: boolean;
35
35
  };
36
+ shouldSave: {
37
+ type: BooleanConstructor;
38
+ default: boolean;
39
+ };
36
40
  }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
37
41
  value: {
38
42
  type: PropType<string | number | (string | number)[]>;
@@ -64,11 +68,16 @@ declare const _default: import("vue").DefineComponent<{
64
68
  type: BooleanConstructor;
65
69
  default: boolean;
66
70
  };
71
+ shouldSave: {
72
+ type: BooleanConstructor;
73
+ default: boolean;
74
+ };
67
75
  }>> & {
68
76
  "onUpdate:value"?: ((...args: any[]) => any) | undefined;
69
77
  }, {
70
78
  options: AnyObject[];
71
79
  placeholder: string;
72
80
  allowCreate: boolean;
81
+ shouldSave: boolean;
73
82
  }>;
74
83
  export default _default;
@@ -1 +1 @@
1
- import{defineComponent as e,inject as l,ref as o,computed as a,createVNode as t}from"vue";import{keywordMatcher as u}from"../../../../../../../shared/utils/index.js";import{NSelect as r}from"naive-ui";import{useIhoTableFormEvent as n}from"../../../../utils/index.js";import{useDebounceFn as i}from"@vueuse/core";import{isEmpty as s,isFunction as p}from"lodash-es";var c=e({name:"EditSelect",props:{value:{type:[Array,String,Number]},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0},options:{type:Array,default:()=>[]},queryOptions:{type:Function},placeholder:{type:String,default:"请选择"},allowCreate:{type:Boolean,default:!1}},emits:["update:value"],setup(e,{emit:c}){const d=l("$xetable"),v=o(null);function m(e){v.value=e}const f=o(!1),{emitFormChangeWithParams:y}=n({...e,$table:d}),b=o("");function w(){b.value=""}const h=o([]),x=a((()=>{const l=s(h.value)?e.options:h.value;if(!b.value)return l;const o=l.filter((e=>e.label&&e.label.includes(b.value)||u(b.value,e.keyword)));return!e.allowCreate||o.some((e=>e.label===b.value))?o:[...o,{label:b.value,value:b.value,created:!0}]})),q=o(!1),O=i((async function(l=""){b.value=l;try{if(q.value=!0,!p(e.queryOptions))return;h.value=await e.queryOptions({keyword:l,row:e.row,column:e.column,rowIndex:e.rowIndex})}catch(l){console.log(`获取${e.column.field}options错误`)}finally{q.value=!1}}),400);function g(l,o){const a=e.value;c("update:value",l),y({oldValue:a,option:o})}function S(e){var l,o;"Tab"===e.key&&v.value&&(null==(o=(l=v.value).handleKeydown)||o.call(l,{...e,key:"Enter",preventDefault:e.preventDefault.bind(e)}))}const j=()=>({class:"iho-table__selectOption"}),k={class:"iho-table__selectMenu"};return()=>t(r,{ref:m,show:f.value,"onUpdate:show":e=>f.value=e,placeholder:e.placeholder,loading:q.value,options:x.value,value:e.value,remote:!0,onSearch:O,clearable:!0,filterable:!0,nodeProps:j,menuProps:k,onUpdateShow:w,onUpdateValue:g,onKeydown:S},null)}});export{c as default};
1
+ import{defineComponent as e,inject as o,ref as l,computed as t,createVNode as a,toRaw as u}from"vue";import{keywordMatcher as r,arrayed as n}from"../../../../../../../shared/utils/index.js";import{NSelect as i}from"naive-ui";import{InjectionIhoTableUUID as s}from"../../../../constants/index.js";import{selectOptionsMap as d}from"../hooks/useSelectOption.js";import{useIhoTableFormEvent as p}from"../../../../utils/index.js";import{useDebounceFn as c}from"@vueuse/core";import{isEmpty as v,isFunction as m,isArray as f,isObject as h,omit as y}from"lodash-es";var b=e({name:"EditSelect",props:{value:{type:[Array,String,Number]},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0},options:{type:Array,default:()=>[]},queryOptions:{type:Function},placeholder:{type:String,default:"请选择"},allowCreate:{type:Boolean,default:!1},shouldSave:{type:Boolean,default:!1}},emits:["update:value"],setup(e,{emit:b}){const w=o("$xetable"),S=l(null);function x(e){S.value=e}const O=l(!1),{emitFormChangeWithParams:g}=p({...e,$table:w}),j=l("");function q(){return E()}const k=l([]),_=t((()=>{let o=v(k.value)?e.options:k.value;return j.value?(o=o.filter((e=>e.label&&e.label.includes(j.value)||r(j.value,e.keyword))),!e.allowCreate||o.some((e=>e.label===j.value))?o:[...o,{label:j.value,value:j.value,created:!0,shouldSave:e.shouldSave}]):o})),C=l(!1),E=c((async function(o=""){j.value=o;try{if(C.value=!0,!m(e.queryOptions)||!v(e.options))return;k.value=await e.queryOptions({keyword:o,row:e.row,column:e.column,rowIndex:e.rowIndex})}catch(o){console.log(`获取${e.column.field}options错误`)}finally{C.value=!1}}),400),I=o(s);function P(o,l){const t=e.value;b("update:value",o);const a=d.get(I);a&&f(a[e.column.field])&&n(l).forEach((o=>{if(!h(o))return;const l=o;l.created&&l.shouldSave&&a[e.column.field].push(y(u(l),["created","shouldSave"]))})),g({oldValue:t,option:l})}function U(e){var o,l;"Tab"===e.key&&S.value&&(null==(l=(o=S.value).handleKeydown)||l.call(o,{...e,key:"Enter",preventDefault:e.preventDefault.bind(e)}))}const $=()=>({class:"iho-table__selectOption"}),A={class:"iho-table__selectMenu"};return()=>a(i,{ref:x,show:O.value,"onUpdate:show":e=>O.value=e,placeholder:e.placeholder,loading:C.value,options:_.value,value:e.value,remote:!0,onSearch:E,clearable:!0,filterable:!0,nodeProps:$,menuProps:A,onUpdateShow:q,onUpdateValue:P,onKeydown:U},null)}});export{b as default};
@@ -1,6 +1,6 @@
1
1
  import { AnyObject, Func } from '../../../../../../../../es/shared/types';
2
2
  import { CSSProperties, PropType } from 'vue';
3
- import { VxeTableDefines } from 'vxe-table';
3
+ import { VxeTableConstructor, VxeTableDefines, VxeTableMethods, VxeTablePrivateMethods } from 'vxe-table';
4
4
  declare const _default: import("vue").DefineComponent<{
5
5
  value: {};
6
6
  height: {
@@ -52,6 +52,7 @@ declare const _default: import("vue").DefineComponent<{
52
52
  }>>;
53
53
  emit: (event: "click" | "update:value", ...args: any[]) => void;
54
54
  tableHandler: import("../../../../types").IhoTableHandler;
55
+ $table: VxeTableConstructor & VxeTablePrivateMethods & VxeTableMethods;
55
56
  popoverRef: import("vue").Ref<{
56
57
  syncPosition: Func;
57
58
  } | undefined>;
@@ -62,7 +63,6 @@ declare const _default: import("vue").DefineComponent<{
62
63
  onContentClick: (event: MouseEvent) => void;
63
64
  updateShow: (show: boolean) => void;
64
65
  onShow: () => Promise<void>;
65
- emitFormChangeWithParams: (params?: AnyObject) => void;
66
66
  onClose: () => Promise<void>;
67
67
  style: import("vue").ComputedRef<CSSProperties>;
68
68
  NPopover: any;
@@ -1 +1 @@
1
- import{defineComponent as e,inject as a,ref as t,watch as o,computed as u,onDeactivated as l,openBlock as r,createBlock as n,unref as i,withCtx as s,createElementVNode as p,withModifiers as d,normalizeStyle as v,toDisplayString as c,renderSlot as m,createVNode as f}from"vue";import{cloneDeep as h,isObject as w,isArray as y}from"lodash-es";import{NPopover as g,NInput as b}from"naive-ui";import{InjectionIhoTableHandler as x}from"../../../../constants/index.js";import{useIhoTableFormEvent as k}from"../../../../utils/index.js";const _=["onClick"];var C=e({__name:"editSeparate",props:{value:{},height:{type:Number,default:48},column:{type:Object,required:!0},row:{type:Object,required:!0},displayContent:{type:String,default:""},rowIndex:{type:Number,required:!0}},emits:["update:value","click"],setup(e,{emit:C}){const j=e,U=a(x),q=t(),P=t();function S(e){P.value=e}const T=t(!1);function I(e){T.value=e}function N(e){T.value=!T.value,C("click",e)}o(T,(function(e){e?async function(){var e;P.value=h(j.value),await new Promise((e=>setTimeout(e))),null==(e=q.value)||e.syncPosition()}():R()}));const{emitFormChangeWithParams:O}=k(j);async function R(){if(!w(P.value)&&!y(P.value)&&j.value===P.value)return;const e=j.value;C("update:value",P.value),O({oldValue:e}),U.updateTableDataRef()}const z=u((()=>({border:"1px solid #f5f5f5",height:j.height-16+"px",display:"flex",alignItems:"center",padding:"0",background:"white",wordBreak:"keep-all",boxSizing:"border-box","border-radius":"4px"})));return l(R),(a,t)=>(r(),n(i(g),{ref_key:"popoverRef",ref:q,trigger:"manual",show:T.value,"onUpdate:show":t[1]||(t[1]=e=>T.value=e),"show-arrow":!1},{trigger:s((()=>[p("div",{onClick:d(N,["stop"]),style:v(i(z)),class:"iho-table__separateText"},c(e.displayContent||" "),13,_)])),default:s((()=>[m(a.$slots,"menu",{value:P.value,"onUpdate:value":S,"onUpdate:show":I,col:e.column,row:e.row},(()=>[f(i(b),{value:P.value,"onUpdate:value":t[0]||(t[0]=e=>P.value=e),type:"textarea"},null,8,["value"])]))])),_:3},8,["show"]))}});export{C as default};
1
+ import{defineComponent as e,inject as a,ref as t,watch as o,computed as l,onBeforeUnmount as u,onDeactivated as r,openBlock as n,createBlock as i,unref as s,withCtx as p,createElementVNode as d,withModifiers as v,normalizeStyle as c,toDisplayString as m,renderSlot as f,createVNode as h}from"vue";import{cloneDeep as b,isObject as w,isArray as y}from"lodash-es";import{NPopover as g,NInput as x}from"naive-ui";import{InjectionIhoTableHandler as k}from"../../../../constants/index.js";import{useIhoTableFormEvent as _}from"../../../../utils/index.js";const C=["onClick"];var j=e({__name:"editSeparate",props:{value:{},height:{type:Number,default:48},column:{type:Object,required:!0},row:{type:Object,required:!0},displayContent:{type:String,default:""},rowIndex:{type:Number,required:!0}},emits:["update:value","click"],setup(e,{emit:j}){const U=e,q=a(k),P=a("$xetable"),S=t(),T=t();function $(e){T.value=e}const I=t(!1);function N(e){I.value=e}function O(e){I.value=!I.value,j("click",e)}async function R(){if(!w(T.value)&&!y(T.value)&&U.value===T.value)return;const e=U.value;j("update:value",T.value),_({...U,$table:P}).emitFormChangeWithParams({oldValue:e}),q.updateTableDataRef()}o(I,(function(e){e?async function(){var e;T.value=b(U.value),await new Promise((e=>setTimeout(e))),null==(e=S.value)||e.syncPosition()}():R()}));const z=l((()=>({border:"1px solid #f5f5f5",height:U.height-16+"px",display:"flex",alignItems:"center",padding:"0",background:"white",wordBreak:"keep-all",boxSizing:"border-box","border-radius":"4px"})));return u(R),r(R),(a,t)=>(n(),i(s(g),{ref_key:"popoverRef",ref:S,trigger:"manual",show:I.value,"onUpdate:show":t[1]||(t[1]=e=>I.value=e),"show-arrow":!1},{trigger:p((()=>[d("div",{onClick:v(O,["stop"]),style:c(s(z)),class:"iho-table__separateText"},m(e.displayContent||" "),13,C)])),default:p((()=>[f(a.$slots,"menu",{value:T.value,"onUpdate:value":$,"onUpdate:show":N,col:e.column,row:e.row},(()=>[h(s(x),{value:T.value,"onUpdate:value":t[0]||(t[0]=e=>T.value=e),type:"textarea"},null,8,["value"])]))])),_:3},8,["show"]))}});export{j as default};
@@ -1 +1 @@
1
- import{isObject as e}from"@vue/shared";import{isArray as n,isString as t}from"lodash-es";import{IhoTableRowGroupSequence as r}from"../../constants/index.js";function i(t,i,o=(e=>e.field)){const s=i.map((e=>o(e)));return r.some((r=>{const i=t[r];if(!n(i))return!0;i.forEach((t=>{if(!n(t.list)||!t.list.length)return;const r=[];let i=null;t.list.forEach(((n,o)=>{const c=function(n,t,r){return t.findIndex((t=>t!==r&&(e(t)?t.fieldName:t)===n))}(n,s,i);~c&&(r.push(s[c]),0===o?s.splice(c,1,i={fieldName:t.title,children:r}):s.splice(c,1))}))}))})),s}function o(n,r){return n.reduce(((n,i)=>{if(t(i)){const e=r(i);e&&n.push(e)}if(e(i)&&i.children){const e=r(i.fieldName,!0);e&&(e.children=o(i.children,r),n.push(e))}return n}),[])}export{i as createRowGroupList,o as groupTraverser};
1
+ import{isObject as e}from"@vue/shared";import{isArray as n,isString as t}from"lodash-es";import{IhoTableRowGroupSequence as r}from"../../constants/index.js";function i(t,i,o=(e=>e.field)){const s=i.map((e=>o(e)));return r.some((r=>{const i=t[r];if(!n(i))return!0;i.forEach((t=>{if(!n(t.list)||!t.list.length)return;const r=[];let i=null,o=0;t.list.forEach(((n,c)=>{const l=function(n,t,r){return t.findIndex((t=>t!==r&&(e(t)?t.fieldName:t)===n))}(n,s,i);~l?(r.push(s[l]),c===o?s.splice(l,1,i={fieldName:t.title,children:r}):s.splice(l,1)):c===o&&o++}))}))})),s}function o(n,r){return n.reduce(((n,i)=>{if(t(i)){const e=r(i);e&&n.push(e)}if(e(i)&&i.children){const e=r(i.fieldName,!0);e&&(e.children=o(i.children,r),n.push(e))}return n}),[])}export{i as createRowGroupList,o as groupTraverser};
@@ -1 +1 @@
1
- import{traverse as e,uuidGenerator as t,DMZ as r}from"../../../../../shared/utils/index.js";import{isArray as n,isFunction as i,isEmpty as o}from"lodash-es";import{onBeforeUnmount as s}from"vue";import"../../../index.js";import{HIGHEST_PRIORITY as d,IHO_TABLE_TREE_TYPE as a}from"../../constants/index.js";import{isTransformTreeType as l}from"../../utils/index.js";import{defineTablePlugin as f}from"../../hooks/useTablePlugin.js";function u(){const u="virtualTreePlugin",p=new Map;return f({name:u,apply(f){f.configHooks.treeConfig.tap({name:u,stage:d},((e,t)=>l(t)?Object.assign({transform:!0,expandAll:!0,reserve:!0,children:"childrenList",rowField:"__id"},e):e)),f.dataHooks.data.tap(u,((r,i,o)=>{if(!i.treeConfig)return;const{transform:s,rowField:d="__id",parentField:a="parentId",children:f="childrenList"}=i.treeConfig;function u(e){e[d]=e[d]||e.theUniqueKey||t()}l(i)&&s&&(u(r),n(r[f])&&e(r[f],((e,t,r)=>{r&&(e[a]=r[d]),o.insertAfter(e),u(e)}),f,r))})),f.fieldHooks.fieldList.tap(u,((e,t)=>{if(!t.treeConfig)return e;const{transform:n}=t.treeConfig||r;if(!l(t)||!n||!t.uuid)return e;const i=e.filter((e=>!1!==e.visible));let o=i.findIndex((e=>e.treeNode));~o||i.some(((e,t)=>{if(!e.type)return o=t,e.treeNode=!0}));const s=i.length-o-i.filter((e=>"right"===e.fixed)).length;return p.set(t.uuid,{index:o,colspan:s}),e})),f.configHooks.treeConfig.tap(u,((e,t)=>{if(!e)return e;const{transform:r,parentField:n="parentId",hasChild:s="hasChild",children:d="childrenList"}=e;if(i(t.spanMethod)||!r||`${t.isTree}`!==a.TRANSFORM_WITH_SPAN_METHOD)return e;const l=Object.freeze({rowspan:0,colspan:0});return t.spanMethod=({row:e,column:r,$columnIndex:i})=>{const a=p.get(t.uuid);if(a&&(Reflect.has(e,s)?e[s]:!e[n])&&!o(e[d]))return r.treeNode?{rowspan:1,colspan:a.colspan}:"right"!==r.fixed&&i>=a.index?l:void 0},e})),f.setupHooks.setup.tap(u,(e=>{s((()=>{var t;(null==(t=e.value)?void 0:t.uuid)&&p.delete(e.value.uuid)}))}))}})}export{u as virtualTreePlugin};
1
+ import{traverse as e,uuidGenerator as t,DMZ as r}from"../../../../../shared/utils/index.js";import{isArray as i,sortBy as n,isFunction as o,isEmpty as s}from"lodash-es";import{onBeforeUnmount as d}from"vue";import"../../../index.js";import{HIGHEST_PRIORITY as a,IHO_TABLE_TREE_TYPE as f}from"../../constants/index.js";import{isTransformTreeType as l}from"../../utils/index.js";import{defineTablePlugin as u}from"../../hooks/useTablePlugin.js";function p(){const p="virtualTreePlugin",c=new Map;return u({name:p,apply(u){u.configHooks.treeConfig.tap({name:p,stage:a},((e,t)=>l(t)?Object.assign({transform:!0,expandAll:!0,reserve:!0,children:"childrenList",rowField:"__id"},e):e)),u.dataHooks.data.tap(p,((r,n,o)=>{if(!n.treeConfig)return;const{transform:s,rowField:d="__id",parentField:a="parentId",children:f="childrenList"}=n.treeConfig;function u(e){e[d]=e[d]||e.theUniqueKey||t()}l(n)&&s&&(u(r),i(r[f])&&e(r[f],((e,t,r)=>{r&&(e[a]=r[d]),o.insertAfter(e),u(e)}),f,r))})),u.fieldHooks.fieldList.tap(p,((e,t)=>{if(!t.treeConfig)return e;const{transform:i}=t.treeConfig||r;if(!l(t)||!i||!t.uuid)return e;const o=e.filter((e=>!1!==e.visible));let s=o.findIndex((e=>e.treeNode));if(~s&&o[s].fixed){const e=n(o,(e=>"left"===e.fixed?-1:"right"===e.fixed?1:0));s=e.findIndex((e=>e.treeNode))}~s||o.some(((e,t)=>{if(!e.type)return s=t,e.treeNode=!0}));const d=o.length-s-o.filter((e=>"right"===e.fixed)).length;return c.set(t.uuid,{index:s,colspan:d}),e})),u.configHooks.treeConfig.tap(p,((e,t)=>{if(!e)return e;const{transform:r,parentField:i="parentId",hasChild:n="hasChild",children:d="childrenList"}=e;if(o(t.spanMethod)||!r||`${t.isTree}`!==f.TRANSFORM_WITH_SPAN_METHOD)return e;const a=Object.freeze({rowspan:0,colspan:0});return t.spanMethod=({row:e,column:r,$columnIndex:o})=>{const f=c.get(t.uuid);if(f&&(Reflect.has(e,n)?e[n]:!e[i])&&!s(e[d]))return r.treeNode?{rowspan:1,colspan:f.colspan}:"right"!==r.fixed&&o>=f.index?a:void 0},e})),u.setupHooks.setup.tap(p,(e=>{d((()=>{var t;(null==(t=e.value)?void 0:t.uuid)&&c.delete(e.value.uuid)}))}))}})}export{p as virtualTreePlugin};
@@ -1,6 +1,7 @@
1
1
  import { AnyObject, ArrayAble, BindEventSettingItem, FormOperationalConfig, LOW_CODE_VALUE_RELATION, MaybeString, TupleToUnion } from '../../../../../es/shared/types';
2
2
  import { VxeTableProps, VxeTableDefines, VxeTableInstance, VxeColumnPropTypes, VxeTablePropTypes, VxeTableConstructor } from 'vxe-table';
3
- import { VxeTableListeners, VxeTablePrivateMethods } from 'vxe-table/types/table';
3
+ import { VxePagerEventProps } from 'vxe-table/types/pager';
4
+ import { VxeTableEventProps, VxeTableListeners, VxeTablePrivateMethods } from 'vxe-table/types/table';
4
5
  import { IHO_TABLE_STRING_STATUS, IhoTableEventNameTuple, IhoTableRowGroupSequence } from '../../../../../es/components/iho-table/src/constants';
5
6
  import Sortable from 'sortablejs';
6
7
  export * from './pluginType';
@@ -151,6 +152,7 @@ export declare type IhoTableAnchorItem = {
151
152
  title: string;
152
153
  left: number;
153
154
  };
155
+ export declare type IhoTableEventTypes = VxeTableEventProps & VxePagerEventProps;
154
156
  export declare type IhoTableExpose = {
155
157
  $table: VxeTableInstance;
156
158
  loadData(data: AnyObject[]): void;
@@ -3,9 +3,10 @@ import { AsyncParallelHook, AsyncSeriesHook, SyncHook, SyncWaterfallHook } from
3
3
  import { MaybeRef } from '@vueuse/core';
4
4
  import { Ref, VNode } from 'vue';
5
5
  import { VxeGlobalCommands, VxeGlobalFormats, VxeGlobalHooks, VxeGlobalMenus, VxeGlobalRenderer, VxeTableInstance, VXETableSetupOptions } from 'vxe-table';
6
- import { VxeTableEventProps, VxeTableEvents } from 'vxe-table/types/table';
6
+ import { VxeTableEvents } from 'vxe-table/types/table';
7
+ import { VxePagerEvents } from 'vxe-table/types/pager';
7
8
  import { VxeGlobalInterceptor } from 'vxe-table/types/v-x-e-table';
8
- import { IhoTableConfig, IhoTableEmits, IhoTableFieldItem, IhoTableHandler } from '.';
9
+ import { IhoTableConfig, IhoTableEmits, IhoTableEventTypes, IhoTableFieldItem, IhoTableHandler } from '.';
9
10
  export declare type IhoTableInstance = {
10
11
  interceptor: VxeGlobalInterceptor;
11
12
  renderer: VxeGlobalRenderer;
@@ -71,7 +72,7 @@ export declare abstract class AbstractFieldHooks {
71
72
  export declare type WithIhoEventContext<T> = [...WithTableConfig<T>, IhoTableHandler & IhoTableHandlerContext<false>];
72
73
  declare type EventHookType<T extends Func> = AsyncParallelHook<WithIhoEventContext<Parameters<T>>>;
73
74
  declare type VxeEventTypes = Required<{
74
- readonly [K in keyof VxeTableEventProps]: EventHookType<NonNullable<VxeTableEventProps[K]>>;
75
+ readonly [K in keyof IhoTableEventTypes]: EventHookType<NonNullable<IhoTableEventTypes[K]>>;
75
76
  }>;
76
77
  export declare abstract class AbstractEventHooks implements VxeEventTypes {
77
78
  abstract readonly onKeydownStart: EventHookType<VxeTableEvents.KeydownStart>;
@@ -135,6 +136,7 @@ export declare abstract class AbstractEventHooks implements VxeEventTypes {
135
136
  abstract readonly onActiveCellChangeEnd: EventHookType<VxeTableEvents.ActiveCellChangeEnd>;
136
137
  abstract readonly onCellAreaSelectionAllStart: EventHookType<(payload: any) => void>;
137
138
  abstract readonly onCellAreaSelectionAllEnd: EventHookType<(payload: any) => void>;
139
+ abstract readonly onPageChange: EventHookType<VxePagerEvents.PageChange>;
138
140
  }
139
141
  declare type DataHookContext = {
140
142
  remove(): void;