cnhis-design-vue 3.3.1-beta.13 → 3.3.1-beta.14

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 (182) hide show
  1. package/README.md +87 -87
  2. package/es/components/ai-chat/index.d.ts +145 -10
  3. package/es/components/ai-chat/src/Index.vue.d.ts +145 -10
  4. package/es/components/ai-chat/src/Index.vue2.js +1 -1
  5. package/es/components/ai-chat/src/api/index.d.ts +6 -0
  6. package/es/components/ai-chat/src/api/index.js +1 -0
  7. package/es/components/ai-chat/src/components/ChatAudio.vue.d.ts +44 -0
  8. package/es/components/ai-chat/src/components/ChatAudio.vue.js +1 -0
  9. package/es/components/ai-chat/src/components/ChatAudio.vue2.js +1 -0
  10. package/es/components/ai-chat/src/components/ChatCard.js +1 -1
  11. package/es/components/ai-chat/src/components/ChatFooter.vue.d.ts +55 -2
  12. package/es/components/ai-chat/src/components/ChatFooter.vue2.js +1 -1
  13. package/es/components/ai-chat/src/components/ChatMainInner.d.ts +2 -0
  14. package/es/components/ai-chat/src/components/ChatMainInner.js +1 -0
  15. package/es/components/ai-chat/src/components/ChatRight.vue.d.ts +55 -0
  16. package/es/components/ai-chat/src/components/ChatRight.vue.js +1 -0
  17. package/es/components/ai-chat/src/components/ChatRight.vue2.js +1 -0
  18. package/es/components/ai-chat/src/components/card/JsonCard.d.ts +25 -0
  19. package/es/components/ai-chat/src/components/card/JsonCard.js +1 -0
  20. package/es/components/ai-chat/src/components/card/SelectIcon.d.ts +14 -0
  21. package/es/components/ai-chat/src/components/card/SelectIcon.js +1 -0
  22. package/es/components/ai-chat/src/hooks/useProgram.d.ts +6 -0
  23. package/es/components/ai-chat/src/hooks/useProgram.js +1 -0
  24. package/es/components/ai-chat/src/hooks/useWebsocket.d.ts +2 -0
  25. package/es/components/ai-chat/src/hooks/useWebsocket.js +1 -0
  26. package/es/components/ai-chat/src/utils/index.d.ts +1 -0
  27. package/es/components/ai-chat/src/utils/index.js +1 -1
  28. package/es/components/ai-chat/style/index.css +1 -1
  29. package/es/components/audio-sdk/index.d.ts +2 -304
  30. package/es/components/audio-sdk/index.js +1 -1
  31. package/es/components/audio-sdk/src/audioSDK.d.ts +8 -5
  32. package/es/components/audio-sdk/src/audioSDK.js +1 -1
  33. package/es/components/audio-sdk/src/components/recording.vue.d.ts +4 -43
  34. package/es/components/audio-sdk/src/components/recording.vue2.js +1 -1
  35. package/es/components/audio-sdk/src/utils/recordingModal.d.ts +4 -7
  36. package/es/components/audio-sdk/src/utils/recordingModal.js +1 -1
  37. package/es/components/audio-sdk/style/index.css +1 -1
  38. package/es/components/callback/src/components/render/popupMaps.d.ts +1 -7
  39. package/es/components/card-render/src/components/index.d.ts +23 -23
  40. package/es/components/classification/src/components/table-modal/index.vue.d.ts +3 -0
  41. package/es/components/date-picker/src/DatePicker.vue2.js +1 -1
  42. package/es/components/editor/src/Editor.js +1 -1
  43. package/es/components/editor/style/index.css +1 -0
  44. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useOther.js +1 -1
  45. package/es/components/field-editor/index.d.ts +1 -7
  46. package/es/components/field-editor/src/FieldEditor.vue.d.ts +1 -7
  47. package/es/components/form-config/index.d.ts +3 -38
  48. package/es/components/form-config/src/FormConfig.vue.d.ts +3 -38
  49. package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +1 -7
  50. package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +1 -17
  51. package/es/components/form-config/src/components/FormConfigEventSetting.vue.d.ts +1 -8
  52. package/es/components/form-render/index.d.ts +1 -7
  53. package/es/components/form-render/index.js +1 -1
  54. package/es/components/form-render/src/FormRender.vue.d.ts +1 -7
  55. package/es/components/form-render/src/FormRender.vue2.js +1 -1
  56. package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +1 -7
  57. package/es/components/form-render/src/components/renderer/date.d.ts +0 -2
  58. package/es/components/form-render/src/components/renderer/date.js +1 -1
  59. package/es/components/form-render/src/components/renderer/formItem.d.ts +0 -2
  60. package/es/components/form-render/src/components/renderer/formItem.js +1 -1
  61. package/es/components/form-render/src/components/renderer/input.d.ts +0 -5
  62. package/es/components/form-render/src/components/renderer/input.js +1 -1
  63. package/es/components/form-render/src/components/renderer/lineBar/FormCollapse.vue.d.ts +1 -14
  64. package/es/components/form-render/src/components/renderer/lineBar/index.d.ts +1 -14
  65. package/es/components/form-render/src/components/renderer/select.d.ts +0 -5
  66. package/es/components/form-render/src/components/renderer/select.js +1 -1
  67. package/es/components/form-render/src/components/tooltipMessage.vue.d.ts +1 -12
  68. package/es/components/form-render/src/components/tooltipMessage.vue2.js +1 -1
  69. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -1
  70. package/es/components/form-render/src/hooks/useFieldNormalize.d.ts +0 -4
  71. package/es/components/form-render/src/types/fieldItem.d.ts +0 -1
  72. package/es/components/form-render/src/types/index.d.ts +0 -2
  73. package/es/components/form-render/src/utils/index.d.ts +0 -1
  74. package/es/components/form-render/src/utils/index.js +1 -1
  75. package/es/components/form-render/style/index.css +1 -1
  76. package/es/components/iho-chat/index.d.ts +0 -1
  77. package/es/components/iho-chat/src/Index.vue.d.ts +0 -1
  78. package/es/components/iho-chat/src/components/ChatFooter.vue2.js +1 -1
  79. package/es/components/iho-chat/src/components/ChatMain.vue.d.ts +0 -1
  80. package/es/components/iho-chat/src/components/ChatMain.vue2.js +1 -1
  81. package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
  82. package/es/components/iho-table/index.d.ts +23 -26
  83. package/es/components/iho-table/index.js +1 -1
  84. package/es/components/iho-table/src/IhoTable.vue2.js +1 -1
  85. package/es/components/iho-table/src/hooks/tapHooks/index.d.ts +1 -1
  86. package/es/components/iho-table/src/hooks/tapHooks/index.js +1 -1
  87. package/es/components/iho-table/src/hooks/tapHooks/useDataHooks.d.ts +3 -3
  88. package/es/components/iho-table/src/hooks/tapHooks/useDataHooks.js +1 -1
  89. package/es/components/iho-table/src/hooks/useTablePlugin.js +1 -1
  90. package/es/components/iho-table/src/plugins/filterRenderPlugin/index.js +1 -1
  91. package/es/components/iho-table/src/plugins/headerPlugin/index.d.ts +1 -1
  92. package/es/components/iho-table/src/plugins/headerPlugin/index.js +1 -1
  93. package/es/components/iho-table/src/plugins/highLightSetPlugin.js +1 -1
  94. package/es/components/iho-table/src/plugins/index.d.ts +0 -78
  95. package/es/components/iho-table/src/plugins/index.js +1 -1
  96. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/hooks/useSelectOption.d.ts +0 -7
  97. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/hooks/useSelectOption.js +1 -1
  98. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/index.js +1 -1
  99. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/selectUtils.d.ts +2 -1
  100. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/selectUtils.js +1 -1
  101. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/checkRendererPlugin.js +1 -1
  102. package/es/components/iho-table/src/plugins/stickyFixedPlugin.js +1 -1
  103. package/es/components/iho-table/src/plugins/varialbleHeightPlugin.js +1 -1
  104. package/es/components/iho-table/src/plugins/verticalTablePlugin/src/utils.js +1 -1
  105. package/es/components/iho-table/src/types/index.d.ts +0 -1
  106. package/es/components/iho-table/src/types/pluginType.d.ts +2 -2
  107. package/es/components/index.css +1 -1
  108. package/es/components/index.d.ts +1 -2
  109. package/es/components/index.js +1 -1
  110. package/es/components/info-header/index.d.ts +2 -24
  111. package/es/components/info-header/src/InfoHeader.vue.d.ts +2 -24
  112. package/es/components/info-header/src/components/infoDescription/DescriptionItem.vue.d.ts +0 -2
  113. package/es/components/info-header/src/components/infoDescription/DescriptionList.vue.d.ts +0 -2
  114. package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +1 -9
  115. package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +1 -7
  116. package/es/components/scale-view/index.d.ts +2 -3
  117. package/es/components/scale-view/src/ScaleView.vue.d.ts +2 -3
  118. package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
  119. package/es/components/scale-view/src/hooks/scaleview-init.d.ts +1 -3
  120. package/es/components/scale-view/src/hooks/scaleview-init.js +1 -1
  121. package/es/components/scale-view/src/hooks/use-component.d.ts +2189 -1
  122. package/es/components/shortcut-setter/index.d.ts +1 -8
  123. package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +1 -8
  124. package/es/env.d.ts +25 -25
  125. package/es/shared/assets/img/ai__avatar.png.js +1 -1
  126. package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
  127. package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
  128. package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
  129. package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
  130. package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
  131. package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
  132. package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
  133. package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
  134. package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
  135. package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
  136. package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
  137. package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
  138. package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
  139. package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
  140. package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
  141. package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
  142. package/es/shared/assets/img/failure.png.js +1 -1
  143. package/es/shared/assets/img/file-emr.png.js +1 -0
  144. package/es/shared/assets/img/file.png.js +1 -0
  145. package/es/shared/assets/img/logo.png.js +1 -1
  146. package/es/shared/assets/img/no-permission.png.js +1 -1
  147. package/es/shared/assets/img/nodata.png.js +1 -1
  148. package/es/shared/assets/img/notfound.png.js +1 -1
  149. package/es/shared/assets/img/qr.png.js +1 -1
  150. package/es/shared/assets/img/success.png.js +1 -1
  151. package/es/shared/assets/img/table_style_2.png.js +1 -1
  152. package/es/shared/assets/img/use.png.js +1 -0
  153. package/es/shared/assets/img/video.png.js +1 -1
  154. package/es/shared/assets/img/video_default_cover.png.js +1 -1
  155. package/es/shared/assets/img/xb_big.png.js +1 -1
  156. package/es/shared/assets/img/xb_small.png.js +1 -1
  157. package/es/shared/package.json.js +1 -1
  158. package/package.json +2 -2
  159. package/es/components/audio-sdk/src/Index.vue.d.ts +0 -304
  160. package/es/components/audio-sdk/src/Index.vue.js +0 -1
  161. package/es/components/audio-sdk/src/Index.vue2.js +0 -1
  162. package/es/components/audio-sdk/src/components/form.vue.d.ts +0 -51
  163. package/es/components/audio-sdk/src/components/form.vue.js +0 -1
  164. package/es/components/audio-sdk/src/components/form.vue2.js +0 -1
  165. package/es/components/audio-sdk/src/components/recording-modal.vue.d.ts +0 -91
  166. package/es/components/audio-sdk/src/components/recording-modal.vue.js +0 -1
  167. package/es/components/audio-sdk/src/components/recording-modal.vue2.js +0 -1
  168. package/es/components/audio-sdk/src/utils/index.d.ts +0 -4
  169. package/es/components/audio-sdk/src/utils/index.js +0 -1
  170. package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
  171. package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +0 -1
  172. package/es/components/bpmn-workflow/types/ModelingModule.d.ts +0 -1
  173. package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +0 -1
  174. package/es/shared/components/ArrowIcon/ArrowIcon.vue.js +0 -1
  175. package/es/shared/components/ArrowIcon/index.d.ts +0 -2
  176. package/es/shared/components/ArrowIcon/index.js +0 -1
  177. package/es/shared/components/DateIcon/DateIcon.vue.js +0 -1
  178. package/es/shared/components/DateIcon/index.d.ts +0 -2
  179. package/es/shared/components/DateIcon/index.js +0 -1
  180. package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +0 -86
  181. package/es/shared/utils/fabricjs/index.d.ts +0 -6823
  182. package/es/shared/utils/tapable/index.d.ts +0 -139
@@ -1 +1 @@
1
- import"../../../../../shared/utils/tapable/SyncHook.js";import"../../../../../shared/utils/tapable/SyncBailHook.js";import t from"../../../../../shared/utils/tapable/SyncWaterfallHook.js";import"../../../../../shared/utils/tapable/SyncLoopHook.js";import a from"../../../../../shared/utils/tapable/AsyncParallelHook.js";import"../../../../../shared/utils/tapable/AsyncParallelBailHook.js";import s from"../../../../../shared/utils/tapable/AsyncSeriesHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";import{AbstractDataHooks as o}from"../../types/pluginType.js";class e extends o{constructor(){super(...arguments),this.dataStart=new a(["config","context"]),this.data=new s(["rowData","context","config"]),this.dataEnd=new a(["config","context"]),this.dataList=new t(["dataList","config"])}}function r(){return{create:function(){return new e}}}export{r as useDataHooks};
1
+ import"../../../../../shared/utils/tapable/SyncHook.js";import"../../../../../shared/utils/tapable/SyncBailHook.js";import t from"../../../../../shared/utils/tapable/SyncWaterfallHook.js";import"../../../../../shared/utils/tapable/SyncLoopHook.js";import a from"../../../../../shared/utils/tapable/AsyncParallelHook.js";import"../../../../../shared/utils/tapable/AsyncParallelBailHook.js";import s from"../../../../../shared/utils/tapable/AsyncSeriesHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../../../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";import{AbstractDataHooks as o}from"../../types/pluginType.js";class e extends o{constructor(){super(...arguments),this.dataStart=new a(["config"]),this.data=new s(["rowData","context","config"]),this.dataEnd=new a(["config"]),this.dataList=new t(["dataList","config"])}}function r(){return{create:function(){return new e}}}export{r as useDataHooks};
@@ -1 +1 @@
1
- import{arrayed as o}from"../../../../shared/utils/index.js";import{isFunction as r}from"lodash-es";import{createTableHooks as e}from"./tapHooks/index.js";function n(){const n=e(),t=new Set;return{use:function e(s,i){return o(s).forEach((({name:o,vxe:e,apply:s})=>{t.has(o)||(t.add(o),r(e)&&e(i),r(s)&&s(n))})),{use:e}}}}function t(o){return o}export{t as defineTablePlugin,n as useTablePlugin};
1
+ import{arrayed as o}from"../../../../shared/utils/index.js";import{isFunction as r}from"lodash-es";import{createTableHooks as t}from"./tapHooks/index.js";function n(){const n=t();return{use:function t(e,s){return o(e).forEach((({vxe:o,apply:t})=>{r(o)&&o(s),r(t)&&t(n)})),{use:t}}}}function e(o){return o}export{e as defineTablePlugin,n as useTablePlugin};
@@ -1 +1 @@
1
- import{createVNode as e,onBeforeUnmount as l}from"vue";import{jsonParse as t,arrayed as i}from"../../../../../shared/utils/index.js";import{isObject as r}from"@vue/shared";import{isArray as o,isString as n,first as u,findLastIndex as d}from"lodash-es";import"../../../index.js";import{useUUIDMap as a,IhoTableRenderHelper as s,isCompatibleColumn as f,createIhoTableFilterMethod as v}from"../../utils/index.js";import c from"./filter.vue.js";import{defineTablePlugin as p}from"../../hooks/useTablePlugin.js";function m(){const m="filterRenderPlugin";return p({name:m,vxe(l){l.renderer.mixin({[m]:{showFilterFooter:!1,renderFilter:(l,t)=>e(c,{payload:t,key:t.column.field},null)}})},apply(e){const{getItemFromUUID:c,setItemFromUUID:p,removeItemFromUUID:g}=a((()=>[]),!1);e.fieldHooks.field.tap(m,((e,l,i,{$table:d})=>{var a,c,p,h,g,b,k,F,x,y;const O=null==(a=e.editRender)?void 0:a.props;if(!r(O))return e;if(!s.hasOptionFilter(O))return e;e.editRender={...e.editRender,props:{...null==(c=e.editRender)?void 0:c.props,sortable:e.sortable}},e.filterRender={name:m};const R=null==(p=d.value)?void 0:p.getColumnByField(e.field),$={};let j;if(R&&o(R.filters)&&R.filters.forEach((e=>{e&&($[`${e.label}_${e.value}`]=e.checked)})),f(O))j=null!=(h=O.options)?h:[];else{const e=null==(b=null==(g=O.settingObj)?void 0:g.showSetting)?void 0:b.reduce(((e,l)=>{var t,i,r;return l&&l.change_text&&null!=(null==(i=null==(t=l.filter)?void 0:t[0])?void 0:i.value)&&e.push({label:l.change_text,value:l.filter[0].value,data:null!=(r=l.filter[0].keyword)?r:l.filter[0].value}),e}),[]);if(null==e?void 0:e.length)j=e;else{j=null!=(x=null==(F=null==(k=(r(O.fieldSetting)?O.fieldSetting:n(O.fieldSetting)?t(O.fieldSetting||""):{}).mapping)?void 0:k.mappingFiled)?void 0:F.reduce(((e,l)=>{var t;const i=u(l.value);return r(i)&&e.push({label:l.key||i.key,value:i.value,data:null!=(t=i.keyword)?t:i.value}),e}),[]))?x:[]}}if(e.filters=j.reduce(((e,l)=>(r(l)&&e.push({...l,checked:!!$[`${l.label}_${l.value}`]}),e)),[]),!e.filterMethod){const l=null==(y=i.treeConfig)?void 0:y.children;e.filterMethod=v(l)}return i.filterConfig={iconMatch:"iho-table--iconfont iho-table-icon-filter",iconNone:"iho-table--iconfont iho-table-icon-filter",...i.filterConfig},e})),e.fieldHooks.fieldList.tap(m,((e,l)=>l.uuid?(p(l.uuid,e),e):e)),e.dataHooks.dataEnd.tapPromise(m,(async({$xeTable:e,$table:l},t)=>{var i;if(!l.value||!t.uuid)return;const r=c(t.uuid);if(null==(i=t.sortConfig)?void 0:i.multiple){const e=r.reduce(((e,t)=>{var i;const r=null==(i=t.editRender)?void 0:i.props;if(!t.sortable)return e;if(r&&h(r.isOrder)){const i=l.value.getColumnByField(t.field);(null==i?void 0:i.order)!==r.isOrder&&e.push({field:t.field,order:(null==i?void 0:i.order)?i.order:r.isOrder})}return e}),[]);if(!e.length)return;await l.value.sort(e)}else d(r,(e=>{var t;const i=null==(t=e.editRender)?void 0:t.props;if(i&&h(i.isOrder))return e&&l.value.sort(e.field,i.isOrder),!0}))})),e.setupHooks.setup.tap(m,((e,t)=>{l((()=>{e.value.uuid&&g(e.value.uuid)}))})),e.exposeHooks.expose.tap(m,((e,l,{$table:t})=>(Object.assign(e,{setSort(e,l){t.value&&t.value.sort(e,l)},setFilter(e,l){if(!t.value)return;const r=t.value.getColumnByField(e);if(!r||!o(r.filters))return;const n=i(l);r.filters.forEach((e=>{e.checked=n.includes(e.value)})),t.value.updateData()}}),e)))}})}function h(e){return["asc","desc",null].includes(e)}export{m as filterRenderPlugin};
1
+ import{createVNode as e}from"vue";import{jsonParse as l,arrayed as i}from"../../../../../shared/utils/index.js";import{isObject as t}from"@vue/shared";import{promiseTimeout as r}from"@vueuse/shared";import{isArray as o,isString as n,first as u,findLastIndex as d}from"lodash-es";import"../../../index.js";import{useUUIDMap as s,IhoTableRenderHelper as a,isCompatibleColumn as f,createIhoTableFilterMethod as v}from"../../utils/index.js";import c from"./filter.vue.js";import{defineTablePlugin as p}from"../../hooks/useTablePlugin.js";function m(){const m="filterRenderPlugin";return p({name:m,vxe(l){l.renderer.mixin({[m]:{showFilterFooter:!1,renderFilter:(l,i)=>e(c,{payload:i,key:i.column.field},null)}})},apply(e){const{getItemFromUUID:c,setItemFromUUID:p,removeItemFromUUID:g}=s((()=>[]),!1);e.fieldHooks.field.tap(m,((e,i,r,{$table:d})=>{var s,c,p,h,g,b,k,y,F,x;const R=null==(s=e.editRender)?void 0:s.props;if(!t(R))return e;if(!a.hasOptionFilter(R))return e;e.editRender={...e.editRender,props:{...null==(c=e.editRender)?void 0:c.props,sortable:e.sortable}},e.filterRender={name:m};const j=null==(p=d.value)?void 0:p.getColumnByField(e.field),C={};let O;if(j&&o(j.filters)&&j.filters.forEach((e=>{e&&(C[`${e.label}_${e.value}`]=e.checked)})),f(R))O=null!=(h=R.options)?h:[];else{const e=null==(b=null==(g=R.settingObj)?void 0:g.showSetting)?void 0:b.reduce(((e,l)=>{var i,t,r;return l&&l.change_text&&null!=(null==(t=null==(i=l.filter)?void 0:i[0])?void 0:t.value)&&e.push({label:l.change_text,value:l.filter[0].value,data:null!=(r=l.filter[0].keyword)?r:l.filter[0].value}),e}),[]);if(null==e?void 0:e.length)O=e;else{O=null!=(F=null==(y=null==(k=(t(R.fieldSetting)?R.fieldSetting:n(R.fieldSetting)?l(R.fieldSetting||""):{}).mapping)?void 0:k.mappingFiled)?void 0:y.reduce(((e,l)=>{var i;const r=u(l.value);return t(r)&&e.push({label:l.key||r.key,value:r.value,data:null!=(i=r.keyword)?i:r.value}),e}),[]))?F:[]}}if(e.filters=O.reduce(((e,l)=>(t(l)&&e.push({...l,checked:!!C[`${l.label}_${l.value}`]}),e)),[]),!e.filterMethod){const l=null==(x=r.treeConfig)?void 0:x.children;e.filterMethod=v(l)}return r.filterConfig={iconMatch:"iho-table--iconfont iho-table-icon-filter",iconNone:"iho-table--iconfont iho-table-icon-filter",...r.filterConfig},e})),e.fieldHooks.fieldList.tap(m,((e,l)=>l.uuid?(p(l.uuid,e),e):e)),e.fieldHooks.fieldEnd.tapPromise(m,(async(e,{$table:l})=>{var i;try{if(!l.value||!e.uuid)return;const t=c(e.uuid);if(null==(i=e.sortConfig)?void 0:i.multiple){const e=t.reduce(((e,i)=>{var t;const r=null==(t=i.editRender)?void 0:t.props;if(!i.sortable)return e;if(r&&h(r.isOrder)){const t=l.value.getColumnByField(i.field);e.push({field:i.field,order:(null==t?void 0:t.order)?t.order:r.isOrder})}return e}),[]);if(!e.length)return;await r(200),await l.value.sort(e)}else d(t,(e=>{var i;const t=null==(i=e.editRender)?void 0:i.props;if(t&&h(t.isOrder))return e&&l.value.sort(e.field,t.isOrder),!0}))}finally{e.uuid&&g(e.uuid)}})),e.exposeHooks.expose.tap(m,((e,l,{$table:t})=>(Object.assign(e,{setSort(e,l){t.value&&t.value.sort(e,l)},setFilter(e,l){if(!t.value)return;const r=t.value.getColumnByField(e);if(!r||!o(r.filters))return;const n=i(l);r.filters.forEach((e=>{e.checked=n.includes(e.value)})),t.value.updateData()}}),e)))}})}function h(e){return["asc","desc",null].includes(e)}export{m as filterRenderPlugin};
@@ -1 +1 @@
1
- export declare function HeaderPlugin(): import("../../../../../components/iho-table").TablePlugin;
1
+ export default function HeaderPlugin(): import("../../../../../components/iho-table").TablePlugin;
@@ -1 +1 @@
1
- import{useAttrs as e,onBeforeUnmount as l,inject as t,createVNode as o,mergeProps as n}from"vue";import{arrayed as i,widthAppend as r}from"../../../../../shared/utils/index.js";import{CodeSlash as s}from"@vicons/ionicons5";import{isObject as a,isString as u,isFunction as d}from"lodash-es";import c from"../../../../annotation-edit/index.js";import"../../../index.js";import{InjectionIhoTableAnnotation as m,InjectionIhoTableConfig as v,InjectionIhoTableXeInstance as f,InjectionIhoTableGlobProps as h}from"../../constants/index.js";import{getLowCodeFieldFromField as p,IhoTableRenderHelper as b}from"../../utils/index.js";import x from"./tooltipMessage.vue.js";import{defineTablePlugin as w}from"../../hooks/useTablePlugin.js";function g(){const g="headerPlugin";return w({name:g,apply(w){let j=null;w.setupHooks.setup.tap(g,(()=>{j=e(),l((()=>{j=null}))})),w.fieldHooks.field.tap(g,((e,l,w)=>{var g;const O=null==(g=e.slots)?void 0:g.header;return e.slots={...e.slots,header:l=>function(e,l,p){var w;const g=t(m),O=t(v),D=t("$xetable"),H=t(f);H&&!(null==H?void 0:H.value)&&(H.value=D);const M=null!=e.column.showHeaderOverflow?0!=e.column.showHeaderOverflow:0!=O.value.showHeaderOverflow,W=e.column||{},y=a(null==g?void 0:g.value)&&!1!==l.annotation,k=b.isEditableColumn(O.value,W),P=b.hasFilter(l),$=b.hasTitlePrefix(e.column),C=u(p)?p:d(p)?p(e):null;let R=null==(w=l.settingObj)?void 0:w.fieldDescDev;if(u(R)&&R){const e=t(h);R=(null==e?void 0:e.developMode)?R:""}let S=!1;if(O.value){const e=O.value.editRules&&O.value.editRules[W.field];e&&(S=i(e).some((e=>e.required)))}const T=O.value.border?Math.max(2,Math.ceil(D.reactData.scrollbarWidth/D.reactData.tableColumn.length)):1,V=r(Math.max(0,W.renderWidth-20-T-(S?14:0)-(y?18:0)-(P?23:0)-(k?22:0)-($?20:0)-(W.sortable?23:0)-(R?20:0)));return o("section",{class:"iho-table__headerWrapper"},[o("section",{style:{width:V}},[null!=C?C:o("div",n({style:M?{maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}:{maxWidth:"100%"}},function(){var e;const t=null==(e=l.settingObj)?void 0:e.fieldDescribe;return t?{title:`${W.title}\n${t}`}:{}}()),[function(){const e=W.title,l=/\\n|\n|\r/g;if(!l.test(e))return e;const t=e.replace(l,"<br>").split("<br>");return t.map(((e,l)=>[e,l===t.length-1?null:o("br",null,null)]))}()])]),R?o(x,{message:R},{trigger:()=>o(s,{style:"width:14px"},null)}):null,y?o(c,{modelValue:g.value[W.field],"onUpdate:modelValue":e=>g.value[W.field]=e,shortcuts:j&&(j["annotation-shortcuts"]||j.annotationShortcuts)||[]},null):null])}(l,p(e),O)},e}))}})}export{g as HeaderPlugin};
1
+ import{useAttrs as e,onBeforeUnmount as l,inject as t,createVNode as o,mergeProps as n}from"vue";import{arrayed as i,widthAppend as r}from"../../../../../shared/utils/index.js";import{CodeSlash as s}from"@vicons/ionicons5";import{isObject as a,isString as u,isFunction as d}from"lodash-es";import c from"../../../../annotation-edit/index.js";import"../../../index.js";import{InjectionIhoTableAnnotation as m,InjectionIhoTableConfig as v,InjectionIhoTableXeInstance as f,InjectionIhoTableGlobProps as h}from"../../constants/index.js";import{getLowCodeFieldFromField as p,IhoTableRenderHelper as b}from"../../utils/index.js";import x from"./tooltipMessage.vue.js";import{defineTablePlugin as w}from"../../hooks/useTablePlugin.js";function g(){const g="headerPlugin";return w({name:g,apply(w){let j=null;w.setupHooks.setup.tap(g,(()=>{j=e(),l((()=>{j=null}))})),w.fieldHooks.field.tap(g,((e,l,w)=>{var g;const O=null==(g=e.slots)?void 0:g.header;return e.slots={...e.slots,header:l=>function(e,l,p){var w;const g=t(m),O=t(v),D=t("$xetable"),H=t(f);H&&!(null==H?void 0:H.value)&&(H.value=D);const M=null!=e.column.showHeaderOverflow?0!=e.column.showHeaderOverflow:0!=O.value.showHeaderOverflow,W=e.column||{},y=a(null==g?void 0:g.value)&&!1!==l.annotation,k=b.isEditableColumn(O.value,W),P=b.hasFilter(l),$=b.hasTitlePrefix(e.column),C=u(p)?p:d(p)?p(e):null;let R=null==(w=l.settingObj)?void 0:w.fieldDescDev;if(u(R)&&R){const e=t(h);R=(null==e?void 0:e.developMode)?R:""}let S=!1;if(O.value){const e=O.value.editRules&&O.value.editRules[W.field];e&&(S=i(e).some((e=>e.required)))}const T=O.value.border?Math.max(2,Math.ceil(D.reactData.scrollbarWidth/D.reactData.tableColumn.length)):1,V=r(Math.max(0,W.renderWidth-20-T-(S?14:0)-(y?18:0)-(P?23:0)-(k?22:0)-($?20:0)-(W.sortable?23:0)-(R?20:0)));return o("section",{class:"iho-table__headerWrapper"},[o("section",{style:{width:V}},[null!=C?C:o("div",n({style:M?{maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}:{maxWidth:"100%"}},function(){var e;const t=null==(e=l.settingObj)?void 0:e.fieldDescribe;return t?{title:`${W.title}\n${t}`}:{}}()),[function(){const e=W.title,l=/\\n|\n|\r/g;if(!l.test(e))return e;const t=e.replace(l,"<br>").split("<br>");return t.map(((e,l)=>[e,l===t.length-1?null:o("br",null,null)]))}()])]),R?o(x,{message:R},{trigger:()=>o(s,{style:"width:14px"},null)}):null,y?o(c,{modelValue:g.value[W.field],"onUpdate:modelValue":e=>g.value[W.field]=e,shortcuts:j&&(j["annotation-shortcuts"]||j.annotationShortcuts)||[]},null):null])}(l,p(e),O)},e}))}})}export{g as default};
@@ -1 +1 @@
1
- import{traverse as o,hex2rgba as r}from"../../../../shared/utils/index.js";import{isFunction as t}from"lodash-es";import"../../index.js";import{useUUIDMap as e,mergeVxeClass as i}from"../utils/index.js";import{defineTablePlugin as n}from"../hooks/useTablePlugin.js";function s(){const s="highLightSetPlugin",{getItemFromUUID:u,removeItemFromUUID:l,setItemFromUUID:a}=e((()=>!1));return n({name:s,apply(e){e.dataHooks.data.tapPromise(s,(async(r,t)=>{if(!t.uuid||u(t.uuid))return;let e=!1;o(r,((o,r)=>{(o.rowColor||o.fontColor)&&(e=!0,r())}),["children","childrenList"]),e&&a(t.uuid,!0)})),e.dataHooks.dataEnd.tap(s,((o,e)=>{if(!e.uuid||!u(e.uuid))return;const n=e.rowStyle;e.rowStyle=function(o){if(o.row.rowColor||o.row.fontColor){const[e,i,s,u]=r(o.row.rowColor||"",.2),l={"--row-background-color":`rgba(${e}, ${i}, ${s}, ${u})`,color:o.row.fontColor};return t(n)?Object.assign(l,n(o)):l}return t(n)?n(o):null};const s=e.rowClassName;e.rowClassName=i((o=>o.row.rowColor?"row--custom":null),s),l(e.uuid)}))}})}export{s as highLightSetPlugin};
1
+ import{traverse as o,hex2rgba as r}from"../../../../shared/utils/index.js";import{isFunction as t}from"lodash-es";import"../../index.js";import{useUUIDMap as e,mergeVxeClass as i}from"../utils/index.js";import{defineTablePlugin as n}from"../hooks/useTablePlugin.js";function s(){const s="highLightSetPlugin",{getItemFromUUID:u,removeItemFromUUID:l,setItemFromUUID:a}=e((()=>!1));return n({name:s,apply(e){e.dataHooks.data.tapPromise(s,(async(r,t)=>{if(!t.uuid||u(t.uuid))return;let e=!1;o(r,((o,r)=>{(o.rowColor||o.fontColor)&&(e=!0,r())}),["children","childrenList"]),e&&a(t.uuid,!0)})),e.dataHooks.dataEnd.tap(s,(o=>{if(!o.uuid||!u(o.uuid))return;const e=o.rowStyle;o.rowStyle=function(o){if(o.row.rowColor||o.row.fontColor){const[i,n,s,u]=r(o.row.rowColor||"",.2),l={"--row-background-color":`rgba(${i}, ${n}, ${s}, ${u})`,color:o.row.fontColor};return t(e)?Object.assign(l,e(o)):l}return t(e)?e(o):null};const n=o.rowClassName;o.rowClassName=i((o=>o.row.rowColor?"row--custom":null),n),l(o.uuid)}))}})}export{s as highLightSetPlugin};
@@ -1,81 +1,3 @@
1
1
  import { TablePlugin } from '../../../../components/iho-table';
2
- import { anchorPlugin } from './anchorPlugin/index';
3
- import { bindEventSettingPlugin } from './bindEventSettingPlugin';
4
- import { colorAndIconPlugin } from './colorAndIconPlugin';
5
- import { copyPastePlugin } from './copyPastePlugin';
6
- import { crossHeaderPlugin } from './crossHeaderPlugin';
7
- import { defaultConfigPlugin } from './defaultConfigPlugin';
8
- import { defaultValuePlugin } from './defaultValuePlugin';
9
- import { dragScrollPlugin } from './dragScrollPlugin';
10
- import { dynamicFilterRenderPlugin } from './dynamicFilterRenderPlugin/index';
11
- import { filterDaterangeRenderPlugin } from './filterDaterangeRenderPlugin/index';
12
- import { filterRemoteSearchPlugin } from './filterRemoteSearchPlugin/index';
13
- import { filterRenderPlugin } from './filterRenderPlugin/index';
14
- import { filterTextRenderPlugin } from './filterTextPlugin/index';
15
- import { filterVisibleEventPlugin } from './filterVisibleEventPlugin';
16
- import { forceArrowKeyPlugin } from './forceArrowKeyPlugin';
17
- import { HeaderPlugin } from './headerPlugin/index';
18
- import { highLightSetPlugin } from './highLightSetPlugin';
19
- import { keyboardEventPlugin } from './keyboardEventPlugin';
20
- import { lowCodeFieldAdaptorPlugin } from './lowCodeFieldAdaptorPlugin';
21
- import { maxCheckSizePlugin } from './maxCheckSizePlugin';
22
- import { operationalFormPlugin } from './operationalFormPlugin';
23
- import { pagerScrollPlugin } from './pagerScrollPlugin/index';
24
- import { rowClickPlugin } from './rowClickPlugin';
25
- import { rowDragPlugin } from './rowDragPlugin';
26
- import { rowGroupSettingPlugin } from './rowGroupSettingPlugin/index';
27
- import { stickyFixedPlugin } from './stickyFixedPlugin';
28
- import { variableHeightRendererPlugin } from './varialbleHeightPlugin';
29
- import { verticalTablePlugin } from './verticalTablePlugin/index';
30
- import { virtualTreePlugin } from './virtualTreePlugin';
31
- import { wordbookSettingPlugin } from './wordbookSettingPlugin';
32
- export declare const commonPlugins: {
33
- anchorPlugin: typeof anchorPlugin;
34
- bindEventSettingPlugin: typeof bindEventSettingPlugin;
35
- colorAndIconPlugin: typeof colorAndIconPlugin;
36
- copyPastePlugin: typeof copyPastePlugin;
37
- crossHeaderPlugin: typeof crossHeaderPlugin;
38
- defaultConfigPlugin: typeof defaultConfigPlugin;
39
- defaultValuePlugin: typeof defaultValuePlugin;
40
- dragScrollPlugin: typeof dragScrollPlugin;
41
- dynamicFilterRenderPlugin: typeof dynamicFilterRenderPlugin;
42
- filterDaterangeRenderPlugin: typeof filterDaterangeRenderPlugin;
43
- filterRemoteSearchPlugin: typeof filterRemoteSearchPlugin;
44
- filterRenderPlugin: typeof filterRenderPlugin;
45
- filterTextRenderPlugin: typeof filterTextRenderPlugin;
46
- filterVisibleEventPlugin: typeof filterVisibleEventPlugin;
47
- forceArrowKeyPlugin: typeof forceArrowKeyPlugin;
48
- HeaderPlugin: typeof HeaderPlugin;
49
- highLightSetPlugin: typeof highLightSetPlugin;
50
- keyboardEventPlugin: typeof keyboardEventPlugin;
51
- lowCodeFieldAdaptorPlugin: typeof lowCodeFieldAdaptorPlugin;
52
- maxCheckSizePlugin: typeof maxCheckSizePlugin;
53
- operationalFormPlugin: typeof operationalFormPlugin;
54
- pagerScrollPlugin: typeof pagerScrollPlugin;
55
- rowClickPlugin: typeof rowClickPlugin;
56
- rowDragPlugin: typeof rowDragPlugin;
57
- rowGroupSettingPlugin: typeof rowGroupSettingPlugin;
58
- stickyFixedPlugin: typeof stickyFixedPlugin;
59
- variableHeightRendererPlugin: typeof variableHeightRendererPlugin;
60
- verticalTablePlugin: typeof verticalTablePlugin;
61
- virtualTreePlugin: typeof virtualTreePlugin;
62
- wordbookSettingPlugin: typeof wordbookSettingPlugin;
63
- };
64
2
  declare const _default: Record<string, () => TablePlugin>;
65
3
  export default _default;
66
- export { dateRendererPlugin } from './rendererPlugins/editableWidgets/dateRendererPlugin/index';
67
- export { inputRendererPlugin } from './rendererPlugins/editableWidgets/inputRendererPlugin';
68
- export { levelSearchCascadePlugin } from './rendererPlugins/editableWidgets/levelSearchCascadePlugin/index';
69
- export { numberRendererPlugin } from './rendererPlugins/editableWidgets/numberRendererPlugin';
70
- export { radioRendererPlugin } from './rendererPlugins/editableWidgets/radioRendererPlugin';
71
- export { selectRendererPlugin } from './rendererPlugins/editableWidgets/selectRendererPlugin/index';
72
- export { separateRendererPlugins } from './rendererPlugins/editableWidgets/separateRendererPlugin/index';
73
- export { switchRendererPlugin } from './rendererPlugins/editableWidgets/switchRendererPlugin';
74
- export { timeRendererPlugin } from './rendererPlugins/editableWidgets/timeRendererPlugin/index';
75
- export { checkRendererPlugin } from './rendererPlugins/widgets/checkRendererPlugin';
76
- export { colorRendererPlugin } from './rendererPlugins/widgets/colorRendererPlugin';
77
- export { defaultRendererPlugin } from './rendererPlugins/widgets/defaultRendererPlugin';
78
- export { htmlRendererPlugin } from './rendererPlugins/widgets/htmlRendererPlugin';
79
- export { labelRendererPlugin } from './rendererPlugins/widgets/labelRendererPlugin';
80
- export { pictureRendererPlugin } from './rendererPlugins/widgets/pictureRendererPlugin';
81
- export { seqRendererPlugin } from './rendererPlugins/widgets/seqRendererPlugin';
@@ -1 +1 @@
1
- import*as e from"./anchorPlugin/index.js";import{anchorPlugin as r}from"./anchorPlugin/index.js";import*as i from"./bindEventSettingPlugin.js";import{bindEventSettingPlugin as n}from"./bindEventSettingPlugin.js";import*as l from"./colorAndIconPlugin.js";import{colorAndIconPlugin as t}from"./colorAndIconPlugin.js";import*as s from"./copyPastePlugin.js";import{copyPastePlugin as g}from"./copyPastePlugin.js";import*as d from"./crossHeaderPlugin.js";import{crossHeaderPlugin as o}from"./crossHeaderPlugin.js";import*as u from"./defaultConfigPlugin.js";import{defaultConfigPlugin as P}from"./defaultConfigPlugin.js";import*as a from"./defaultValuePlugin.js";import{defaultValuePlugin as m}from"./defaultValuePlugin.js";import*as f from"./dragScrollPlugin.js";import{dragScrollPlugin as p}from"./dragScrollPlugin.js";import*as x from"./dynamicFilterRenderPlugin/index.js";import{dynamicFilterRenderPlugin as c}from"./dynamicFilterRenderPlugin/index.js";import*as j from"./filterDaterangeRenderPlugin/index.js";import{filterDaterangeRenderPlugin as R}from"./filterDaterangeRenderPlugin/index.js";import*as b from"./filterRemoteSearchPlugin/index.js";import{filterRemoteSearchPlugin as w}from"./filterRemoteSearchPlugin/index.js";import*as h from"./filterRenderPlugin/index.js";import{filterRenderPlugin as S}from"./filterRenderPlugin/index.js";import*as v from"./filterTextPlugin/index.js";import{filterTextRenderPlugin as k}from"./filterTextPlugin/index.js";import*as W from"./filterVisibleEventPlugin.js";import{filterVisibleEventPlugin as y}from"./filterVisibleEventPlugin.js";import*as C from"./forceArrowKeyPlugin.js";import{forceArrowKeyPlugin as F}from"./forceArrowKeyPlugin.js";import*as A from"./headerPlugin/index.js";import{HeaderPlugin as E}from"./headerPlugin/index.js";import*as T from"./highLightSetPlugin.js";import{highLightSetPlugin as H}from"./highLightSetPlugin.js";import*as V from"./keyboardEventPlugin.js";import{keyboardEventPlugin as D}from"./keyboardEventPlugin.js";import*as z from"./lowCodeFieldAdaptorPlugin.js";import{lowCodeFieldAdaptorPlugin as I}from"./lowCodeFieldAdaptorPlugin.js";import*as K from"./maxCheckSizePlugin.js";import{maxCheckSizePlugin as L}from"./maxCheckSizePlugin.js";import*as q from"./operationalFormPlugin.js";import{operationalFormPlugin as G}from"./operationalFormPlugin.js";import*as O from"./pagerScrollPlugin/index.js";import{pagerScrollPlugin as B}from"./pagerScrollPlugin/index.js";import*as J from"./rendererPlugins/editableWidgets/dateRendererPlugin/index.js";export{dateRendererPlugin}from"./rendererPlugins/editableWidgets/dateRendererPlugin/index.js";import*as M from"./rendererPlugins/editableWidgets/inputRendererPlugin.js";export{inputRendererPlugin}from"./rendererPlugins/editableWidgets/inputRendererPlugin.js";import*as N from"./rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.js";export{levelSearchCascadePlugin}from"./rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.js";import*as Q from"./rendererPlugins/editableWidgets/numberRendererPlugin.js";export{numberRendererPlugin}from"./rendererPlugins/editableWidgets/numberRendererPlugin.js";import*as U from"./rendererPlugins/editableWidgets/radioRendererPlugin.js";export{radioRendererPlugin}from"./rendererPlugins/editableWidgets/radioRendererPlugin.js";import*as X from"./rendererPlugins/editableWidgets/selectRendererPlugin/index.js";export{selectRendererPlugin}from"./rendererPlugins/editableWidgets/selectRendererPlugin/index.js";import*as Y from"./rendererPlugins/editableWidgets/separateRendererPlugin/index.js";export{separateRendererPlugins}from"./rendererPlugins/editableWidgets/separateRendererPlugin/index.js";import*as Z from"./rendererPlugins/editableWidgets/switchRendererPlugin.js";export{switchRendererPlugin}from"./rendererPlugins/editableWidgets/switchRendererPlugin.js";import*as $ from"./rendererPlugins/editableWidgets/timeRendererPlugin/index.js";export{timeRendererPlugin}from"./rendererPlugins/editableWidgets/timeRendererPlugin/index.js";import*as _ from"./rendererPlugins/widgets/checkRendererPlugin.js";export{checkRendererPlugin}from"./rendererPlugins/widgets/checkRendererPlugin.js";import*as ee from"./rendererPlugins/widgets/colorRendererPlugin.js";export{colorRendererPlugin}from"./rendererPlugins/widgets/colorRendererPlugin.js";import*as re from"./rendererPlugins/widgets/defaultRendererPlugin.js";export{defaultRendererPlugin}from"./rendererPlugins/widgets/defaultRendererPlugin.js";import*as ie from"./rendererPlugins/widgets/htmlRendererPlugin.js";export{htmlRendererPlugin}from"./rendererPlugins/widgets/htmlRendererPlugin.js";import*as ne from"./rendererPlugins/widgets/labelRendererPlugin.js";export{labelRendererPlugin}from"./rendererPlugins/widgets/labelRendererPlugin.js";import*as le from"./rendererPlugins/widgets/pictureRendererPlugin.js";export{pictureRendererPlugin}from"./rendererPlugins/widgets/pictureRendererPlugin.js";import*as te from"./rendererPlugins/widgets/seqRendererPlugin.js";export{seqRendererPlugin}from"./rendererPlugins/widgets/seqRendererPlugin.js";import*as se from"./rowClickPlugin.js";import{rowClickPlugin as ge}from"./rowClickPlugin.js";import*as de from"./rowDragPlugin.js";import{rowDragPlugin as oe}from"./rowDragPlugin.js";import*as ue from"./rowGroupSettingPlugin/index.js";import{rowGroupSettingPlugin as Pe}from"./rowGroupSettingPlugin/index.js";import*as ae from"./stickyFixedPlugin.js";import{stickyFixedPlugin as me}from"./stickyFixedPlugin.js";import*as fe from"./varialbleHeightPlugin.js";import{variableHeightRendererPlugin as pe}from"./varialbleHeightPlugin.js";import*as xe from"./verticalTablePlugin/index.js";import{verticalTablePlugin as ce}from"./verticalTablePlugin/index.js";import*as je from"./virtualTreePlugin.js";import{virtualTreePlugin as Re}from"./virtualTreePlugin.js";import*as be from"./wordbookSettingPlugin.js";import{wordbookSettingPlugin as we}from"./wordbookSettingPlugin.js";import{separateMetaModule as he}from"../../../../shared/utils/index.js";const Se={anchorPlugin:r,bindEventSettingPlugin:n,colorAndIconPlugin:t,copyPastePlugin:g,crossHeaderPlugin:o,defaultConfigPlugin:P,defaultValuePlugin:m,dragScrollPlugin:p,dynamicFilterRenderPlugin:c,filterDaterangeRenderPlugin:R,filterRemoteSearchPlugin:w,filterRenderPlugin:S,filterTextRenderPlugin:k,filterVisibleEventPlugin:y,forceArrowKeyPlugin:F,HeaderPlugin:E,highLightSetPlugin:H,keyboardEventPlugin:D,lowCodeFieldAdaptorPlugin:I,maxCheckSizePlugin:L,operationalFormPlugin:G,pagerScrollPlugin:B,rowClickPlugin:ge,rowDragPlugin:oe,rowGroupSettingPlugin:Pe,stickyFixedPlugin:me,variableHeightRendererPlugin:pe,verticalTablePlugin:ce,virtualTreePlugin:Re,wordbookSettingPlugin:we};var ve=he(Object.assign({"./anchorPlugin/index.tsx":e,"./bindEventSettingPlugin.ts":i,"./colorAndIconPlugin.ts":l,"./copyPastePlugin.ts":s,"./crossHeaderPlugin.ts":d,"./defaultConfigPlugin.ts":u,"./defaultValuePlugin.ts":a,"./dragScrollPlugin.ts":f,"./dynamicFilterRenderPlugin/index.tsx":x,"./filterDaterangeRenderPlugin/index.tsx":j,"./filterRemoteSearchPlugin/index.tsx":b,"./filterRenderPlugin/index.tsx":h,"./filterTextPlugin/index.tsx":v,"./filterVisibleEventPlugin.ts":W,"./forceArrowKeyPlugin.ts":C,"./headerPlugin/index.tsx":A,"./highLightSetPlugin.tsx":T,"./keyboardEventPlugin.ts":V,"./lowCodeFieldAdaptorPlugin.tsx":z,"./maxCheckSizePlugin.ts":K,"./operationalFormPlugin.ts":q,"./pagerScrollPlugin/index.ts":O,"./rendererPlugins/editableWidgets/dateRendererPlugin/index.tsx":J,"./rendererPlugins/editableWidgets/inputRendererPlugin.tsx":M,"./rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.tsx":N,"./rendererPlugins/editableWidgets/numberRendererPlugin.tsx":Q,"./rendererPlugins/editableWidgets/radioRendererPlugin.tsx":U,"./rendererPlugins/editableWidgets/selectRendererPlugin/index.tsx":X,"./rendererPlugins/editableWidgets/separateRendererPlugin/index.tsx":Y,"./rendererPlugins/editableWidgets/switchRendererPlugin.tsx":Z,"./rendererPlugins/editableWidgets/timeRendererPlugin/index.tsx":$,"./rendererPlugins/widgets/checkRendererPlugin.tsx":_,"./rendererPlugins/widgets/colorRendererPlugin.tsx":ee,"./rendererPlugins/widgets/defaultRendererPlugin.tsx":re,"./rendererPlugins/widgets/htmlRendererPlugin.tsx":ie,"./rendererPlugins/widgets/labelRendererPlugin.tsx":ne,"./rendererPlugins/widgets/pictureRendererPlugin.tsx":le,"./rendererPlugins/widgets/seqRendererPlugin.tsx":te,"./rowClickPlugin.ts":se,"./rowDragPlugin.ts":de,"./rowGroupSettingPlugin/index.ts":ue,"./stickyFixedPlugin.tsx":ae,"./varialbleHeightPlugin.tsx":fe,"./verticalTablePlugin/index.ts":xe,"./virtualTreePlugin.ts":je,"./wordbookSettingPlugin.ts":be}));export{Se as commonPlugins,ve as default};
1
+ import*as e from"./anchorPlugin/index.js";import*as r from"./bindEventSettingPlugin.js";import*as i from"./colorAndIconPlugin.js";import*as n from"./copyPastePlugin.js";import*as s from"./crossHeaderPlugin.js";import*as t from"./defaultConfigPlugin.js";import*as l from"./defaultValuePlugin.js";import*as d from"./dragScrollPlugin.js";import*as g from"./dynamicFilterRenderPlugin/index.js";import*as o from"./filterDaterangeRenderPlugin/index.js";import*as u from"./filterRemoteSearchPlugin/index.js";import*as a from"./filterRenderPlugin/index.js";import*as P from"./filterTextPlugin/index.js";import*as m from"./filterVisibleEventPlugin.js";import*as f from"./forceArrowKeyPlugin.js";import*as x from"./headerPlugin/index.js";import*as p from"./highLightSetPlugin.js";import*as j from"./keyboardEventPlugin.js";import*as c from"./lowCodeFieldAdaptorPlugin.js";import*as R from"./maxCheckSizePlugin.js";import*as b from"./operationalFormPlugin.js";import*as w from"./pagerScrollPlugin/index.js";import*as h from"./rendererPlugins/editableWidgets/dateRendererPlugin/index.js";import*as S from"./rendererPlugins/editableWidgets/inputRendererPlugin.js";import*as W from"./rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.js";import*as v from"./rendererPlugins/editableWidgets/numberRendererPlugin.js";import*as k from"./rendererPlugins/editableWidgets/radioRendererPlugin.js";import*as y from"./rendererPlugins/editableWidgets/selectRendererPlugin/index.js";import*as C from"./rendererPlugins/editableWidgets/separateRendererPlugin/index.js";import*as F from"./rendererPlugins/editableWidgets/switchRendererPlugin.js";import*as A from"./rendererPlugins/editableWidgets/timeRendererPlugin/index.js";import*as E from"./rendererPlugins/widgets/checkRendererPlugin.js";import*as T from"./rendererPlugins/widgets/colorRendererPlugin.js";import*as D from"./rendererPlugins/widgets/defaultRendererPlugin.js";import*as H from"./rendererPlugins/widgets/htmlRendererPlugin.js";import*as V from"./rendererPlugins/widgets/labelRendererPlugin.js";import*as q from"./rendererPlugins/widgets/pictureRendererPlugin.js";import*as z from"./rendererPlugins/widgets/seqRendererPlugin.js";import*as G from"./rowClickPlugin.js";import*as I from"./rowDragPlugin.js";import*as K from"./rowGroupSettingPlugin/index.js";import*as L from"./stickyFixedPlugin.js";import*as O from"./varialbleHeightPlugin.js";import*as B from"./verticalTablePlugin/index.js";import*as J from"./virtualTreePlugin.js";import*as M from"./wordbookSettingPlugin.js";import{separateMetaModule as N}from"../../../../shared/utils/index.js";var Q=N(Object.assign({"./anchorPlugin/index.tsx":e,"./bindEventSettingPlugin.ts":r,"./colorAndIconPlugin.ts":i,"./copyPastePlugin.ts":n,"./crossHeaderPlugin.ts":s,"./defaultConfigPlugin.ts":t,"./defaultValuePlugin.ts":l,"./dragScrollPlugin.ts":d,"./dynamicFilterRenderPlugin/index.tsx":g,"./filterDaterangeRenderPlugin/index.tsx":o,"./filterRemoteSearchPlugin/index.tsx":u,"./filterRenderPlugin/index.tsx":a,"./filterTextPlugin/index.tsx":P,"./filterVisibleEventPlugin.ts":m,"./forceArrowKeyPlugin.ts":f,"./headerPlugin/index.tsx":x,"./highLightSetPlugin.tsx":p,"./keyboardEventPlugin.ts":j,"./lowCodeFieldAdaptorPlugin.tsx":c,"./maxCheckSizePlugin.ts":R,"./operationalFormPlugin.ts":b,"./pagerScrollPlugin/index.ts":w,"./rendererPlugins/editableWidgets/dateRendererPlugin/index.tsx":h,"./rendererPlugins/editableWidgets/inputRendererPlugin.tsx":S,"./rendererPlugins/editableWidgets/levelSearchCascadePlugin/index.tsx":W,"./rendererPlugins/editableWidgets/numberRendererPlugin.tsx":v,"./rendererPlugins/editableWidgets/radioRendererPlugin.tsx":k,"./rendererPlugins/editableWidgets/selectRendererPlugin/index.tsx":y,"./rendererPlugins/editableWidgets/separateRendererPlugin/index.tsx":C,"./rendererPlugins/editableWidgets/switchRendererPlugin.tsx":F,"./rendererPlugins/editableWidgets/timeRendererPlugin/index.tsx":A,"./rendererPlugins/widgets/checkRendererPlugin.tsx":E,"./rendererPlugins/widgets/colorRendererPlugin.tsx":T,"./rendererPlugins/widgets/defaultRendererPlugin.tsx":D,"./rendererPlugins/widgets/htmlRendererPlugin.tsx":H,"./rendererPlugins/widgets/labelRendererPlugin.tsx":V,"./rendererPlugins/widgets/pictureRendererPlugin.tsx":q,"./rendererPlugins/widgets/seqRendererPlugin.tsx":z,"./rowClickPlugin.ts":G,"./rowDragPlugin.ts":I,"./rowGroupSettingPlugin/index.ts":K,"./stickyFixedPlugin.tsx":L,"./varialbleHeightPlugin.tsx":O,"./verticalTablePlugin/index.ts":B,"./virtualTreePlugin.ts":J,"./wordbookSettingPlugin.ts":M}));export{Q as default};
@@ -1,11 +1,4 @@
1
1
  import { AnyObject } from '../../../../../../../shared/types';
2
2
  import { VxeTableConstructor } from 'vxe-table';
3
- import { IhoTableFieldItem } from '../../../../../../../components/iho-table';
4
3
  export declare const selectOptionsMap: Map<string, Record<string, AnyObject[]>>;
5
- export declare const selectColumnMap: {
6
- uuidMap: Map<string, Record<string, IhoTableFieldItem[]>>;
7
- getItemFromUUID: (uuid: string) => Record<string, IhoTableFieldItem[]>;
8
- setItemFromUUID: (uuid: string, value: Record<string, IhoTableFieldItem[]>) => void;
9
- removeItemFromUUID: (uuid: string) => void;
10
- };
11
4
  export declare function getSelectOptions(uuid: string, field: string, row?: AnyObject, $table?: VxeTableConstructor): AnyObject[];
@@ -1 +1 @@
1
- import{reactive as e}from"vue";import{useUUIDMap as t}from"../../../../utils/index.js";const r=e(new Map),i=t((()=>({})));function n(e,t,n,o){var f;if(!e||!t)return[];if(o&&n){const o=null==(f=i.getItemFromUUID(e)[t])?void 0:f[0];if(o&&n[o.field])return r.get(e)[`${t}__${o.field}-${n[o.field]}`]}return r.get(e)[t]}export{n as getSelectOptions,i as selectColumnMap,r as selectOptionsMap};
1
+ import{reactive as e}from"vue";const n=e(new Map);function t(e,t,i,l){if(!e||!t)return[];if(l&&i){const{tableColumn:r}=l.reactData,o=r.find((e=>{var n,i;const l=null==(n=e.editRender)?void 0:n.props,r=null==(i=(null==l?void 0:l.connectField)||"")?void 0:i.split(",");return null==r?void 0:r.includes(t)}));if(o&&i[o.field])return n.get(e)[`${t}__${o.field}-${i[o.field]}`]}return n.get(e)[t]}export{t as getSelectOptions,n as selectOptionsMap};
@@ -1 +1 @@
1
- import{reactive as e,inject as o,createVNode as l,mergeProps as n,onBeforeUnmount as t}from"vue";import{arrayed as i}from"../../../../../../../shared/utils/index.js";import"../../../../../index.js";import{EDITABLE_WIDGET_TYPE as r,InjectionIhoTableUUID as d}from"../../../../constants/index.js";import{useAutoFocus as s}from"../hooks/useAutoFocus.js";import{getTitle as u,IhoTableRenderHelper as c,getLowCodeFieldFromField as a,IhoTableUtils as p}from"../../../../utils/index.js";import f from"./editSelect.js";import{getDefaultValue as m,getArray as v}from"./selectUtils.js";import{getSelectOptions as w,selectOptionsMap as h,selectColumnMap as g}from"../hooks/useSelectOption.js";import{isString as C,isFunction as y,isEqual as b}from"lodash-es";import{defineTablePlugin as F}from"../../../../hooks/useTablePlugin.js";function E(){const E="selectRendererPlugin",P=e(new Map);function x(e){return!0===e||"1"===e}return F({name:E,vxe(e){e.renderer.add(r.SELECT,{renderCell({props:e},{row:n,column:t,$table:r}){var s,c,a,p,f,v;const h=o(d),g=w(h,t.field,n,r);if(e&&e.labelToValue&&g.length){const o=x(null!=(c=null==(s=e.componentProps)?void 0:s.allowModify)?c:e.allowModify),l=x(null!=(p=null==(a=e.componentProps)?void 0:a.allowCreate)?p:e.allowCreate)||o,i=n[t.field];if(!o&&!l&&null!=i&&""!==i){const{aliasField:o="",labelField:l="label",valueField:r="value"}=e.componentProps||{};if(!g.find((e=>e[r]===i))){const e=g.find((e=>e[l]===i||e[o]===i));e?n[t.field]=e[r]:Reflect.deleteProperty(n,t.field)}}}const C=m(n,e,g),y=i(C).join(","),b=e&&(null==(f=e.componentProps)?void 0:f.multiple)&&(x(e.variableHeight)||(null==(v=e.componentProps)?void 0:v.indexedText));return[l("span",{title:u(t,y),class:"iho-table__colorAndIcon"},[b?i(C).reduce(((e,o)=>(null!=o&&e.push([o,";",l("br",null,null)]),e)),[]):y])]},renderEdit:c.createRenderEdit((({fieldItem:e,emitFormClick:t,row:i,column:r,$rowIndex:s,$table:u})=>{var c,a,p,m;const v=o(d),h=w(v,r.field,i,u),g=x(null!=(a=null==(c=e.componentProps)?void 0:c.allowModify)?a:e.allowModify),C=x(null!=(m=null==(p=e.componentProps)?void 0:p.allowCreate)?m:e.allowCreate)||g;return[l(f,n({queryOptions:e.queryOptions},e.componentProps,{options:h,column:r,row:i,"row-index":s,value:i[r.field],"onUpdate:value":e=>i[r.field]=e,allowModify:g,allowCreate:C,onClick:t}),null)]}))})},apply(e){async function o(e,o={}){var l,n,t;const i=null==(l=e.editRender)?void 0:l.props;if(!i)return[];let r=v(i.options)||v(null==(n=i.componentProps)?void 0:n.options)||[];if(i.queryOptions)try{const l={column:e,isFullData:!0,...o};r=await(null==(t=i.queryOptions)?void 0:t.call(i,l))}catch(e){console.log(`获取${i.field}_options错误`)}return r}function l(e){return e&&p.getCellType(e)===r.SELECT}s(e).bindAutoFocusConfig(E,r.SELECT,".n-base-selection-input,.n-base-selection-tags"),e.fieldHooks.fieldList.tap(E,((e,{uuid:n})=>{if(n){h.get(n)||h.set(n,{}),P.set(n,e);const t={};e.forEach((e=>{t[e.field]=e})),g.setItemFromUUID(n,{});const i=g.getItemFromUUID(n);e.forEach((e=>{const o=a(e);if(!o||!o.connectField||!C(o.connectField))return;o.connectField.split(",").forEach((o=>{i[o]=i[o]||[],i[o].push(e)}))}));const r=h.get(n);e.forEach((async e=>{var n,t;const d=null==(n=e.editRender)?void 0:n.props;if(e.field&&d&&l(d)&&!(null==(t=i[e.field])?void 0:t.length)){if(y(d.queryOptions)&&r[e.field])return;r[e.field]=[],r[e.field]=await o(e)}}))}return e})),e.dataHooks.data.tap(E,((e,{uuid:n},t)=>{if(!n)return;const i=P.get(n);if(!i||!i.length)return;const r=h.get(n);i.forEach((async n=>{var t;const d=null==(t=n.editRender)?void 0:t.props;if(n.field&&d&&l(d)&&(null==d?void 0:d.connectField)){const l=d.connectField.split(","),t=e[d.columnName];l.forEach((async l=>{const s=null==i?void 0:i.find((e=>e.field===l));if(!s)return;const u=t?`${l}__${d.columnName}-${t}`:l;r[u]||(r[u]=[],r[u]=await o(s,{row:e,connectColumn:n}))}))}}))})),e.setupHooks.setup.tap(E,(e=>{t((()=>{var o;const l=null==(o=e.value)?void 0:o.uuid;l&&(h.delete(l),g.removeItemFromUUID(l),P.delete(l))}))})),e.eventHooks.onCellDblclick.tap(E,((e,o,{emits:n})=>{var t,i,r;const{$table:d,row:s,column:u}=e,c=Reflect.get(e,"verticalState");let{column:a,row:p}=d.reactData.editStore.actived;if(!(a&&p||(c&&(a=null==(t=c.editCell)?void 0:t.column,p=null==(i=c.editCell)?void 0:i.row),a&&p)))return;c&&(a=u,p=s);const f=null==(r=a.editRender)?void 0:r.props,{cellDblclickSelectable:m=!1,multiple:v=!1,valueField:h="value"}=f.componentProps||{};if(!m||!l(f))return;const g=o.uuid&&w(o.uuid,a.field,p,d);if(1!==(null==g?void 0:g.length))return;const C=v?[g[0][h]]:g[0][h],y=p[a.field];d.clearEdit(),b(C,y)||(p[a.field]=C,n("formChange",{column:a,row:p,oldValue:y,value:C,index:d.getRowIndex(p),$table:d,option:g[0]}),c&&(c.editCell=null))}))}})}export{E as selectRendererPlugin};
1
+ import{reactive as e,inject as l,createVNode as o,mergeProps as n,onBeforeUnmount as t}from"vue";import{arrayed as i}from"../../../../../../../shared/utils/index.js";import"../../../../../index.js";import{EDITABLE_WIDGET_TYPE as r,InjectionIhoTableUUID as d}from"../../../../constants/index.js";import{useAutoFocus as u}from"../hooks/useAutoFocus.js";import{getTitle as s,IhoTableRenderHelper as a,IhoTableUtils as c}from"../../../../utils/index.js";import p from"./editSelect.js";import{getDefaultValue as f,isConnectField as m,getArray as v}from"./selectUtils.js";import{getSelectOptions as w,selectOptionsMap as C}from"../hooks/useSelectOption.js";import{cloneDeep as y,isFunction as b,isEqual as g}from"lodash-es";import{defineTablePlugin as h}from"../../../../hooks/useTablePlugin.js";function P(){const P="selectRendererPlugin",x=e(new Map);function E(e){return!0===e||"1"===e}return h({name:P,vxe(e){e.renderer.add(r.SELECT,{renderCell({props:e},{row:n,column:t,$table:r}){var u,a,c,p,m,v;const C=l(d),y=w(C,t.field,n,r);if(e&&e.labelToValue&&y.length){const l=E(null!=(a=null==(u=e.componentProps)?void 0:u.allowModify)?a:e.allowModify),o=E(null!=(p=null==(c=e.componentProps)?void 0:c.allowCreate)?p:e.allowCreate)||l,i=n[t.field];if(!l&&!o&&null!=i&&""!==i){const{aliasField:l="",labelField:o="label",valueField:r="value"}=e.componentProps||{};if(!y.find((e=>e[r]===i))){const e=y.find((e=>e[o]===i||e[l]===i));e?n[t.field]=e[r]:Reflect.deleteProperty(n,t.field)}}}const b=f(n,e,y),g=i(b).join(","),h=e&&(null==(m=e.componentProps)?void 0:m.multiple)&&(E(e.variableHeight)||(null==(v=e.componentProps)?void 0:v.indexedText));return[o("span",{title:s(t,g),class:"iho-table__colorAndIcon"},[h?i(b).reduce(((e,l)=>(null!=l&&e.push([l,";",o("br",null,null)]),e)),[]):g])]},renderEdit:a.createRenderEdit((({fieldItem:e,emitFormClick:t,row:i,column:r,$rowIndex:u,$table:s})=>{var a,c,f,m;const v=l(d),C=w(v,r.field,i,s),y=E(null!=(c=null==(a=e.componentProps)?void 0:a.allowModify)?c:e.allowModify),b=E(null!=(m=null==(f=e.componentProps)?void 0:f.allowCreate)?m:e.allowCreate)||y;return[o(p,n({queryOptions:e.queryOptions},e.componentProps,{options:C,column:r,row:i,"row-index":u,value:i[r.field],"onUpdate:value":e=>i[r.field]=e,allowModify:y,allowCreate:b,onClick:t}),null)]}))})},apply(e){async function l(e,l={}){var o,n,t;const i=null==(o=e.editRender)?void 0:o.props;if(!i)return[];let r=v(i.options)||v(null==(n=i.componentProps)?void 0:n.options)||[];if(i.queryOptions)try{const o={column:e,isFullData:!0,...l};r=await(null==(t=i.queryOptions)?void 0:t.call(i,o))}catch(e){console.log(`获取${i.field}_options错误`)}return r}function o(e){return e&&c.getCellType(e)===r.SELECT}u(e).bindAutoFocusConfig(P,r.SELECT,".n-base-selection-input,.n-base-selection-tags"),e.fieldHooks.fieldList.tap(P,((e,{uuid:n})=>{if(n){C.get(n)||C.set(n,{}),x.set(n,y(e));const t=C.get(n);e.forEach((async n=>{var i;const r=null==(i=n.editRender)?void 0:i.props;if(n.field&&r&&o(r)&&!m(e,n.field)){if(b(r.queryOptions)&&t[n.field])return;t[n.field]=[],t[n.field]=await l(n)}}))}return e})),e.dataHooks.data.tap(P,((e,{uuid:n},t)=>{if(!n)return;const i=x.get(n);if(!i||!i.length)return;const r=C.get(n);i.forEach((async n=>{var t;const d=null==(t=n.editRender)?void 0:t.props;if(n.field&&d&&o(d)&&(null==d?void 0:d.connectField)){const o=d.connectField.split(","),t=e[d.columnName];o.forEach((async o=>{const u=null==i?void 0:i.find((e=>e.field===o));if(!u)return;const s=t?`${o}__${d.columnName}-${t}`:o;r[s]||(r[s]=[],r[s]=await l(u,{row:e,connectColumn:n}))}))}}))})),e.setupHooks.setup.tap(P,(e=>{t((()=>{var l;const o=null==(l=e.value)?void 0:l.uuid;o&&(C.delete(o),x.delete(o))}))})),e.eventHooks.onCellDblclick.tap(P,((e,l,{emits:n})=>{var t,i,r;const{$table:d,row:u,column:s}=e,a=Reflect.get(e,"verticalState");let{column:c,row:p}=d.reactData.editStore.actived;if(!(c&&p||(a&&(c=null==(t=a.editCell)?void 0:t.column,p=null==(i=a.editCell)?void 0:i.row),c&&p)))return;a&&(c=s,p=u);const f=null==(r=c.editRender)?void 0:r.props,{cellDblclickSelectable:m=!1,multiple:v=!1,valueField:C="value"}=f.componentProps||{};if(!m||!o(f))return;const y=l.uuid&&w(l.uuid,c.field,p,d);if(1!==(null==y?void 0:y.length))return;const b=v?[y[0][C]]:y[0][C],h=p[c.field];d.clearEdit(),g(b,h)||(p[c.field]=b,n("formChange",{column:c,row:p,oldValue:h,value:b,index:d.getRowIndex(p),$table:d,option:y[0]}),a&&(a.editCell=null))}))}})}export{P as selectRendererPlugin};
@@ -1,4 +1,5 @@
1
1
  import { AnyObject } from '../../../../../../../shared/types';
2
- import { LowCodeTableFieldItem } from '../../../../../../../components/iho-table/src/types';
2
+ import { LowCodeTableFieldItem, IhoTableFieldItem } from '../../../../../../../components/iho-table/src/types';
3
3
  export declare function getDefaultValue(row: AnyObject, item: LowCodeTableFieldItem | any, options?: AnyObject[]): any;
4
4
  export declare function getArray(list: AnyObject[] | undefined): AnyObject[] | null | undefined;
5
+ export declare function isConnectField(columns: IhoTableFieldItem[], field: string): boolean;
@@ -1 +1 @@
1
- function l(l,r,u=[]){const{aliasField:e="",labelField:i="label",valueField:o="value"}=(null==r?void 0:r.componentProps)||{},a=l[r.columnName];return Array.isArray(a)?a.map((l=>t(l))):t(a);function t(l){var r,a,t;const d=null==(r=n(u))?void 0:r.find((n=>n[o]==l));return null!=(t=null!=(a=null==d?void 0:d[e])?a:null==d?void 0:d[i])?t:l}}function n(l){return Array.isArray(l)&&!l.length?null:l}export{n as getArray,l as getDefaultValue};
1
+ function l(l,r,e=[]){const{aliasField:u="",labelField:i="label",valueField:o="value"}=(null==r?void 0:r.componentProps)||{},t=l[r.columnName];return Array.isArray(t)?t.map((l=>a(l))):a(t);function a(l){var r,t,a;const d=null==(r=n(e))?void 0:r.find((n=>n[o]==l));return null!=(a=null!=(t=null==d?void 0:d[u])?t:null==d?void 0:d[i])?a:l}}function n(l){return Array.isArray(l)&&!l.length?null:l}function r(l,n){return l.some((l=>{var r,e;return((null==(e=null==(r=l.editRender)?void 0:r.props)?void 0:e.connectField)||"").split(",").includes(n)}))}export{n as getArray,l as getDefaultValue,r as isConnectField};
@@ -1 +1 @@
1
- import{createVNode as e,defineComponent as l,inject as o,computed as t}from"vue";import{isNumber as n,constant as i,isString as c}from"lodash-es";import"../../../../index.js";import{NCheckbox as a}from"naive-ui";import{defineTablePlugin as d}from"../../../hooks/useTablePlugin.js";function r(){const l="checkRendererPlugin";return d({name:l,apply(o){o.fieldHooks.field.tap(l,((o,{index:t,insertBefore:c},a)=>{if(0===t&&a.selectType&&["checkbox","radio"].includes(a.selectType)){const{radioConfig:o,checkboxConfig:t={}}=a,d={width:45,align:"center",fixed:"left",..."radio"===a.selectType?o:t,field:l,type:a.selectType,annotation:!1};t.disableHeader&&(d.slots={header:()=>e("span",{class:"checkbox-cell--disable"},null),...d.slots}),t.useNCheckbox&&(d.slots={checkbox:e=>s(e,t),header:n(t.maxCheckSize)?i([]):e=>s(e,t),...d.slots}),c(d)}return o}))}})}function s(l,o){return[e(p,{payload:l,checkboxConfig:o},null)]}const p=l({name:"IhoTableNCheckbox",props:{payload:{type:Object,default:()=>({})},checkboxConfig:{type:Object,default:()=>({})}},setup(l){const n=o("$xetable");function i(e,o){var t,i,c,a;if(o.stopPropagation(),"header"===(null==(t=l.payload)?void 0:t.type))if(null==(i=l.checkboxConfig)?void 0:i.checkStrictly){const l=null==(a=null==(c=null==n?void 0:n.getComputeMaps())?void 0:c.computeCheckboxOpts)?void 0:a.value;if(!l)return;l.checkStrictly=!1,null==n||n.triggerCheckAllEvent(o,e),l.checkStrictly=!0}else null==n||n.triggerCheckAllEvent(o,e);else null==n||n.triggerCheckRowEvent(o,l.payload,e)}const d=t((()=>{var e,o;return c(null==(e=l.checkboxConfig)?void 0:e.indeterminateField)?null==(o=l.payload.row)?void 0:o[l.checkboxConfig.indeterminateField]:l.payload.indeterminate}));return()=>!1===l.payload.visible?null:e(a,{checked:l.payload.checked,"onUpdate:checked":e=>l.payload.checked=e,indeterminate:d.value,disabled:l.payload.disabled,onUpdateChecked:i},null)}});export{r as checkRendererPlugin};
1
+ import{createVNode as e,defineComponent as o,inject as l,computed as n}from"vue";import{isNumber as t,constant as a,isString as i}from"lodash-es";import"../../../../index.js";import{NCheckbox as d}from"naive-ui";import{defineTablePlugin as c}from"../../../hooks/useTablePlugin.js";function r(){const o="checkRendererPlugin";return c({name:o,apply(l){l.fieldHooks.field.tap(o,((l,{index:n,insertBefore:i},d)=>{if(0===n&&d.selectType&&["checkbox","radio"].includes(d.selectType)){const{radioConfig:l,checkboxConfig:n={}}=d,c={width:45,align:"center",fixed:"left",..."radio"===d.selectType?l:n,field:o,type:d.selectType,annotation:!1};n.disableHeader&&(c.slots={header:()=>e("span",{class:"checkbox-cell--disable"},null),...c.slots}),n.useNCheckbox&&(c.slots={checkbox:e=>s(e,n),header:t(n.maxCheckSize)?a([]):e=>s(e,n),...c.slots}),i(c)}return l}))}})}function s(o,l){return[e(p,{payload:o,checkboxConfig:l},null)]}const p=o({name:"IhoTableNCheckbox",props:{payload:{type:Object,default:()=>({})},checkboxConfig:{type:Object,default:()=>({})}},setup(o){const t=l("$xetable");function a(e,l){var n;l.stopPropagation(),"header"===(null==(n=o.payload)?void 0:n.type)?null==t||t.triggerCheckAllEvent(l,e):null==t||t.triggerCheckRowEvent(l,o.payload,e)}const c=n((()=>{var e,l;return i(null==(e=o.checkboxConfig)?void 0:e.indeterminateField)?null==(l=o.payload.row)?void 0:l[o.checkboxConfig.indeterminateField]:o.payload.indeterminate}));return()=>!1===o.payload.visible?null:e(d,{checked:o.payload.checked,"onUpdate:checked":e=>o.payload.checked=e,indeterminate:c.value,disabled:o.payload.disabled,onUpdateChecked:a},null)}});export{r as checkRendererPlugin};
@@ -1 +1 @@
1
- import{onBeforeUnmount as e,createVNode as l,defineComponent as t,inject as i,computed as r,watch as d,onMounted as o}from"vue";import{traverse as u}from"../../../../shared/utils/index.js";import{promiseTimeout as n}from"@vueuse/shared";import{last as a,first as s}from"lodash-es";import"../../index.js";import{LOWEST_PRIORITY as f,InjectionIhoTableConfig as h,InjectionIhoTableXeInstance as c}from"../constants/index.js";import{useUUIDMap as v,mergeVxeStyle as g,mergeVxeClass as m}from"../utils/index.js";import{defineTablePlugin as x}from"../hooks/useTablePlugin.js";function p(){const p="stickyFixedPlugin";return x({name:p,apply(x){const{getItemFromUUID:y,removeItemFromUUID:b}=v((()=>({$xeTable:null,left:[],noFixed:[],right:[]}))),{getItemFromUUID:B,removeItemFromUUID:L}=v((()=>({tableBody:null,tableHeader:null,leftBorderLeftEle:null,leftBorderTopEle:null,leftShadowEle:null,rightBorderLeftEle:null,rightBorderTopEle:null})),!1);function E(e){const l=B(e),{leftShadowEle:t,rightBorderLeftEle:i,tableBody:r}=l;r&&(t&&(r.scrollLeft>0?t.classList.add("scrolling--middle"):null==t||t.classList.remove("scrolling--middle")),i&&(Math.ceil(r.scrollLeft)<r.scrollWidth-r.clientWidth?i.classList.add("scrolling--middle"):null==i||i.classList.remove("scrolling--middle")))}function F(e){const l=B(e),{tableBody:t,leftBorderLeftEle:i,leftShadowEle:r,leftBorderTopEle:d,rightBorderTopEle:o,rightBorderLeftEle:u,tableHeader:n}=l;if(!t||!n)return;const{$xeTable:f,left:h,right:c}=y(e);if(i&&d&&r)if(f){const e=h.map((e=>f.getColumnByField(e.field))).reduce(((e,l)=>e+((null==l?void 0:l.resizeWidth)||(null==l?void 0:l.renderWidth)||40)),0);r.style.left=e-4+"px",d.style.width=e-1+"px"}else{const e=a(null==n?void 0:n.querySelectorAll("th.iho-table--fixed-left"));e&&(r.style.left=e.offsetLeft+e.clientWidth-4+"px",d.style.width=e.offsetLeft+e.clientWidth-1+"px")}if(o&&u){const e=t.scrollHeight>t.clientHeight;if(f){const l=c.map((e=>f.getColumnByField(e.field))).reduce(((e,l)=>e+((null==l?void 0:l.resizeWidth)||(null==l?void 0:l.renderWidth)||40)),0);u.style.right=l-3+(e?10:0)+"px",o.style.width=l+(e?10:0)+"px",e&&o.style.setProperty("--c-header-height",n.clientHeight-2+"px")}else{const l=s(null==n?void 0:n.querySelectorAll("th.iho-table--fixed-right"));l&&(u.style.right=10+t.clientWidth-l.offsetLeft-(e?0:10)+"px",o.style.width=t.clientWidth-l.offsetLeft+(e?10:0)+"px",e&&o.style.setProperty("--c-header-height",n.clientHeight-2+"px"))}}}x.configHooks.config.tap(p,((e,{$table:l})=>{var t;if(!(null==(t=e.stickyFixedConfig)?void 0:t.enable)||!e.uuid)return e;const i=e=>{if(!l.value)return{left:0,right:0};return{left:l.value.getColumns().slice(0,e).reduce(((e,l)=>e+(l.resizeWidth||l.renderWidth)),0),right:l.value.getColumns().slice(e+1).reduce(((e,l)=>e+(l.resizeWidth||l.renderWidth)),0)}},r=y(e.uuid);function d(e){return r.left.some((l=>l.field===e.field))||r.right.some((l=>l.field===e.field))}return e.cellStyle=g((({_columnIndex:e,column:l})=>{if(d(l))return{"--iho-table-fixed-left":i(e).left,"--iho-table-fixed-right":i(e).right}}),e.cellStyle),e.headerCellStyle=g((({_columnIndex:e,column:l})=>{if(d(l))return{"--iho-table-fixed-left":i(e).left,"--iho-table-fixed-right":i(e).right}}),e.headerCellStyle),e})),x.fieldHooks.fieldList.tap({name:p,stage:f},((e,l)=>{var t;if(!(null==(t=l.stickyFixedConfig)?void 0:t.enable)||!l.uuid)return e;const i=y(l.uuid);return i.left=[],i.noFixed=[],i.right=[],u(e,(e=>{e.fixed?(i[e.fixed].push(e),e.className=m(e.className,`iho-table--fixed-${e.fixed}`),e.headerClassName=m(e.headerClassName,`iho-table--fixed-${e.fixed}`)):i.noFixed.push(e),e.fixed=void 0})),[...i.left||[],...i.noFixed||[],...i.right||[]]})),x.setupHooks.setup.tap(p,(l=>{e((()=>{var e;(null==(e=l.value)?void 0:e.uuid)&&(L(l.value.uuid),b(l.value.uuid))}))})),x.dataHooks.dataEnd.tap(p,(async(e,l)=>{var t;(null==(t=l.stickyFixedConfig)?void 0:t.enable)&&l.uuid&&(await n(100),F(l.uuid))})),x.eventHooks.onScroll.tap(p,(({isX:e},l)=>{var t;e&&(null==(t=l.stickyFixedConfig)?void 0:t.enable)&&l.uuid&&E(l.uuid)})),x.eventHooks.onResizableChange.tap(p,((e,l)=>{var t;(null==(t=l.stickyFixedConfig)?void 0:t.enable)&&l.uuid&&E(l.uuid)}));const k=t({setup(){const e=i(h),t=i(c),u=r((()=>{const l=y(e.value.uuid);return!(!l.left||!l.left.length)})),a=r((()=>{const l=y(e.value.uuid);return!(!l.right||!l.right.length)})),s=l=>{B(e.value.uuid).leftBorderLeftEle=l},f=l=>{B(e.value.uuid).leftBorderTopEle=l},v=l=>{B(e.value.uuid).leftShadowEle=l},g=l=>{B(e.value.uuid).rightBorderLeftEle=l},m=l=>{B(e.value.uuid).rightBorderTopEle=l};function x(){if(y(e.value.uuid).$xeTable=t.value,!t.value||!e.value.uuid)return;const{refTableBody:l,refTableHeader:i}=t.value.getRefMaps();if(!l.value)return;const r=B(e.value.uuid);r.tableBody=l.value.$el,r.tableHeader=i.value.$el,E(e.value.uuid),F(e.value.uuid)}return d([()=>y(e.value.uuid).left,()=>y(e.value.uuid).right],x),o((async()=>{await n(100),x()})),()=>[u.value?[l("div",{class:"iho-table__fixedLeftBorderLeft",ref:s},null),l("div",{class:"iho-table__fixedLeftBorderTop",ref:f},null),l("div",{class:"iho-table__fixedLeftShadow",ref:v},null)]:null,a.value?[l("div",{class:"iho-table__fixedRightBorderLeft",ref:g},null),l("div",{class:"iho-table__fixedRightBorderTop",ref:m},null)]:null]}}),C=t({setup(){const e=i(h);return()=>{var t,i;return(null==(i=null==(t=e.value)?void 0:t.stickyFixedConfig)?void 0:i.enable)?l(k,null,null):null}}});x.domInsertHooks.header.tap(p,(e=>(e.push(l(C,null,null)),e)))}})}export{p as stickyFixedPlugin};
1
+ import{onBeforeUnmount as e,createVNode as l,defineComponent as t,inject as i,computed as r,watch as d,onMounted as o}from"vue";import{traverse as u}from"../../../../shared/utils/index.js";import{promiseTimeout as n}from"@vueuse/shared";import{last as a,first as s}from"lodash-es";import"../../index.js";import{LOWEST_PRIORITY as f,InjectionIhoTableConfig as h,InjectionIhoTableXeInstance as c}from"../constants/index.js";import{useUUIDMap as v,mergeVxeStyle as g,mergeVxeClass as m}from"../utils/index.js";import{defineTablePlugin as x}from"../hooks/useTablePlugin.js";function p(){const p="stickyFixedPlugin";return x({name:p,apply(x){const{getItemFromUUID:y,removeItemFromUUID:b}=v((()=>({$xeTable:null,left:[],noFixed:[],right:[]}))),{getItemFromUUID:B,removeItemFromUUID:L}=v((()=>({tableBody:null,tableHeader:null,leftBorderLeftEle:null,leftBorderTopEle:null,leftShadowEle:null,rightBorderLeftEle:null,rightBorderTopEle:null})),!1);function E(e){const l=B(e),{leftShadowEle:t,rightBorderLeftEle:i,tableBody:r}=l;r&&(t&&(r.scrollLeft>0?t.classList.add("scrolling--middle"):null==t||t.classList.remove("scrolling--middle")),i&&(Math.ceil(r.scrollLeft)<r.scrollWidth-r.clientWidth?i.classList.add("scrolling--middle"):null==i||i.classList.remove("scrolling--middle")))}function F(e){const l=B(e),{tableBody:t,leftBorderLeftEle:i,leftShadowEle:r,leftBorderTopEle:d,rightBorderTopEle:o,rightBorderLeftEle:u,tableHeader:n}=l;if(!t||!n)return;const{$xeTable:f,left:h,right:c}=y(e);if(i&&d&&r)if(f){const e=h.map((e=>f.getColumnByField(e.field))).reduce(((e,l)=>e+((null==l?void 0:l.resizeWidth)||(null==l?void 0:l.renderWidth)||40)),0);r.style.left=e-4+"px",d.style.width=e-1+"px"}else{const e=a(null==n?void 0:n.querySelectorAll("th.iho-table--fixed-left"));e&&(r.style.left=e.offsetLeft+e.clientWidth-4+"px",d.style.width=e.offsetLeft+e.clientWidth-1+"px")}if(o&&u){const e=t.scrollHeight>t.clientHeight;if(f){const l=c.map((e=>f.getColumnByField(e.field))).reduce(((e,l)=>e+((null==l?void 0:l.resizeWidth)||(null==l?void 0:l.renderWidth)||40)),0);u.style.right=l-3+(e?10:0)+"px",o.style.width=l+(e?10:0)+"px",e&&o.style.setProperty("--c-header-height",n.clientHeight-2+"px")}else{const l=s(null==n?void 0:n.querySelectorAll("th.iho-table--fixed-right"));l&&(u.style.right=10+t.clientWidth-l.offsetLeft-(e?0:10)+"px",o.style.width=t.clientWidth-l.offsetLeft+(e?10:0)+"px",e&&o.style.setProperty("--c-header-height",n.clientHeight-2+"px"))}}}x.configHooks.config.tap(p,((e,{$table:l})=>{var t;if(!(null==(t=e.stickyFixedConfig)?void 0:t.enable)||!e.uuid)return e;const i=e=>{if(!l.value)return{left:0,right:0};return{left:l.value.getColumns().slice(0,e).reduce(((e,l)=>e+(l.resizeWidth||l.renderWidth)),0),right:l.value.getColumns().slice(e+1).reduce(((e,l)=>e+(l.resizeWidth||l.renderWidth)),0)}},r=y(e.uuid);function d(e){return r.left.some((l=>l.field===e.field))||r.right.some((l=>l.field===e.field))}return e.cellStyle=g((({_columnIndex:e,column:l})=>{if(d(l))return{"--iho-table-fixed-left":i(e).left,"--iho-table-fixed-right":i(e).right}}),e.cellStyle),e.headerCellStyle=g((({_columnIndex:e,column:l})=>{if(d(l))return{"--iho-table-fixed-left":i(e).left,"--iho-table-fixed-right":i(e).right}}),e.headerCellStyle),e})),x.fieldHooks.fieldList.tap({name:p,stage:f},((e,l)=>{var t;if(!(null==(t=l.stickyFixedConfig)?void 0:t.enable)||!l.uuid)return e;const i=y(l.uuid);return i.left=[],i.noFixed=[],i.right=[],u(e,(e=>{e.fixed?(i[e.fixed].push(e),e.className=m(e.className,`iho-table--fixed-${e.fixed}`),e.headerClassName=m(e.headerClassName,`iho-table--fixed-${e.fixed}`)):i.noFixed.push(e),e.fixed=void 0})),[...i.left||[],...i.noFixed||[],...i.right||[]]})),x.setupHooks.setup.tap(p,(l=>{e((()=>{var e;(null==(e=l.value)?void 0:e.uuid)&&(L(l.value.uuid),b(l.value.uuid))}))})),x.dataHooks.dataEnd.tap(p,(async e=>{var l;(null==(l=e.stickyFixedConfig)?void 0:l.enable)&&e.uuid&&(await n(100),F(e.uuid))})),x.eventHooks.onScroll.tap(p,(({isX:e},l)=>{var t;e&&(null==(t=l.stickyFixedConfig)?void 0:t.enable)&&l.uuid&&E(l.uuid)})),x.eventHooks.onResizableChange.tap(p,((e,l)=>{var t;(null==(t=l.stickyFixedConfig)?void 0:t.enable)&&l.uuid&&E(l.uuid)}));const k=t({setup(){const e=i(h),t=i(c),u=r((()=>{const l=y(e.value.uuid);return!(!l.left||!l.left.length)})),a=r((()=>{const l=y(e.value.uuid);return!(!l.right||!l.right.length)})),s=l=>{B(e.value.uuid).leftBorderLeftEle=l},f=l=>{B(e.value.uuid).leftBorderTopEle=l},v=l=>{B(e.value.uuid).leftShadowEle=l},g=l=>{B(e.value.uuid).rightBorderLeftEle=l},m=l=>{B(e.value.uuid).rightBorderTopEle=l};function x(){if(y(e.value.uuid).$xeTable=t.value,!t.value||!e.value.uuid)return;const{refTableBody:l,refTableHeader:i}=t.value.getRefMaps();if(!l.value)return;const r=B(e.value.uuid);r.tableBody=l.value.$el,r.tableHeader=i.value.$el,E(e.value.uuid),F(e.value.uuid)}return d([()=>y(e.value.uuid).left,()=>y(e.value.uuid).right],x),o((async()=>{await n(100),x()})),()=>[u.value?[l("div",{class:"iho-table__fixedLeftBorderLeft",ref:s},null),l("div",{class:"iho-table__fixedLeftBorderTop",ref:f},null),l("div",{class:"iho-table__fixedLeftShadow",ref:v},null)]:null,a.value?[l("div",{class:"iho-table__fixedRightBorderLeft",ref:g},null),l("div",{class:"iho-table__fixedRightBorderTop",ref:m},null)]:null]}}),C=t({setup(){const e=i(h);return()=>{var t,i;return(null==(i=null==(t=e.value)?void 0:t.stickyFixedConfig)?void 0:i.enable)?l(k,null,null):null}}});x.domInsertHooks.header.tap(p,(e=>(e.push(l(C,null,null)),e)))}})}export{p as stickyFixedPlugin};
@@ -1 +1 @@
1
- import{unref as e,onBeforeUnmount as t,shallowReactive as o,createVNode as l,defineComponent as n,inject as r,ref as a,computed as s,provide as i,watch as u,onMounted as c,h as d}from"vue";import{traverse as p,widthAppend as f}from"../../../../shared/utils/index.js";import{doAnimation as m}from"../../../../shared/utils/anime.js";import{useThrottleFn as h}from"@vueuse/core";import{promiseTimeout as g}from"@vueuse/shared";import{last as v,isFunction as x,isNumber as y}from"lodash-es";import"../../index.js";import{InjectionIhoTableUUID as b}from"../constants/index.js";import{useUUIDMap as I,isVariableHeightColumn as w}from"../utils/index.js";import{defineTablePlugin as T}from"../hooks/useTablePlugin.js";class D{constructor(){this.records={},this.maxRecords=o(new Map)}set(e,t,o){if(this.records[e]||(this.records[e]={}),this.records[e][t]===o)return;this.records[e][t]=o;const l=Math.max(...Object.values(this.records[e]),0);this.maxRecords.get(e)!==l&&this.maxRecords.set(e,l)}getMax(e){return this.maxRecords.get(e)||0}}const{getItemFromUUID:R,removeItemFromUUID:M}=I((()=>new D),!0),{getItemFromUUID:S,removeItemFromUUID:H,setItemFromUUID:U}=I((()=>null)),{getItemFromUUID:C,removeItemFromUUID:$,setItemFromUUID:k}=I((()=>{}));let F={};function j(t,o,{scrollTop:l=0}){var n,r;const{uuid:a,rowConfig:s={}}=o;if(!a)return;const i=R(a),{oSize:u=0,gt:c=100}=null!=(n=C(a))?n:{},{internalData:d,reactData:p}=t,{scrollYStore:f,elemStore:m,afterFullData:h,fullDataRowIdData:g}=d;if(c>h.length)return;const y=null!=(r=s.height)?r:36,b=m["main-body-wrapper"],I=b?e(b):null;let w=I?Math.max(8,Math.ceil(I.clientHeight/y)+2+u):8;const T=[0];let D=0;if(l&&h.find(((e,o)=>{const n=t.getRowSeq(e),r=(v(T)||0)+Math.max(y,i.getMax(n));if(T.push(r),r>l)return D=Math.max(0,o-u),w+=Math.min(D,u),!0})),D>0&&x(o.spanMethod)){const{spanMethod:e}=o,l={rowspan:1,colspan:1};for(;D>0;){if(!t.getColumns().some(((t,o)=>{const{rowspan:n,colspan:r}=e({column:t,columnIndex:o,$columnIndex:o,row:h[D],rowIndex:D,$rowIndex:D,_rowIndex:D,isHidden:!t.visible,fixed:t.fixed,type:t.type,visibleData:h})||l;if(0===n&&0===r)return D--,!0})))break}}const M=`${T[D]}px`,S=`${h.reduce(((e,o)=>{const l=t.getRowSeq(o);return e+Math.max(y,i.getMax(l))}),0)}px`;["main","left","right"].forEach((t=>{const o=m[`${t}-body-table`],n=o?e(o):null;n&&(n.style.marginTop=M,n.scrollTop=l),["header","body","footer"].forEach((o=>{const l=m[`${t}-${o}-ySpace`],n=l?e(l):null;n&&(n.style.height=S)}))}));const H=Math.min(h.length,D+w);if(f.startIndex===D&&f.endIndex===H)return;f.startIndex=D,f.endIndex=H;const U=h.slice(f.startIndex,f.endIndex);U.forEach(((e,o)=>{const l=t.getRowid(e),n=g[l];n&&(n.$index=o)})),p.tableData.length=0,p.tableData.push(...U)}const Y=h(j,300);function E(){const o="variableHeightRendererPlugin";return T({name:o,vxe(e){F=n({props:{payload:{type:Object,required:!0}},setup(t){const o=r(b),n=r("$xetable"),p=a(),m=R(o),h=s((()=>t.payload.row[t.payload.column.field]));function v(){const{row:e,column:o}=t.payload,l=n.getRowSeq(e);if(!m||null==l||!p.value)return;const r=p.value.clientHeight;m.set(l,o.field,r)}i("updateCellHeight",v),u([()=>t.payload.rowIndex,()=>t.payload.column.field,h,()=>t.payload.column.renderWidth],(async()=>{await g(0),v()})),c((()=>{n&&!S(o)&&U(o,n),v()}));const I=s((()=>{var o,l,n,r,a;const s=null!=(l=null==(o=t.payload.column.editRender)?void 0:o.props)?l:{},i=null!=(r=null==(n=s.slots)?void 0:n.default)?r:s.slotFn;if(x(i))return i;const u=null==(a=t.payload.column.editRender)?void 0:a.name;if(u){const o=e.renderer.get(u);if(null==o?void 0:o.renderCell)return()=>o.renderCell(t.payload.column.editRender,t.payload)}return()=>h.value})),w=s((()=>{if(t.payload.column.treeNode)return"";const e=t.payload.column.renderWidth;return y(e)&&e>0?f(e-20-2):""}));return()=>l("div",{ref:p,style:{padding:"7px 0",width:w.value,overflow:"hidden"}},[d(I.value,t.payload)])}})},apply(n){function r(t){const o=S(t.uuid);if(!o)return;t.scrollY={enabled:!1},o.reactData.scrollYLoad=!1;const l=function(t){const o=t.internalData.elemStore["main-body-wrapper"];return o?e(o):null}(o);l&&j(o,t,{scrollTop:l.scrollTop})}function a(e){if(!e.uuid)return;const t=C(e.uuid);t&&(e.scrollY=t),setTimeout((()=>r(e)),300)}function s(e){return l(F,{payload:e},null)}n.dataHooks.dataStart.tap(o,((e,t)=>a(t))),n.eventHooks.onFilterChange.tap(o,((e,t)=>a(t))),n.eventHooks.onSortChange.tap(o,((e,t)=>a(t))),n.eventHooks.onToggleTreeExpand.tap(o,((e,t)=>a(t))),n.eventHooks.onResizableChange.tap(o,(async({column:e},t)=>{e.editRender&&e.editRender.props&&w(e.editRender.props)&&a(t)})),n.eventHooks.onScroll.tap(o,h(((e,t)=>{if(e.isX)return;const{uuid:o}=t;if(!o)return;const l=S(o);l&&j(l,t,e)}),100,!0,!0)),n.fieldHooks.field.tap(o,(e=>{if(w(e)){e.slots={...e.slots,default:s};const t=e.className,o="variable-height";e.className=t?function(e){return x(t)?[t(e),o]:[t,o]}:o}return e})),n.fieldHooks.fieldList.tap(o,((t,o,{$table:l})=>(o.uuid&&p(t,((t,n)=>{var a,s;if(w(t)){const t=null!=(s=null==(a=o.rowConfig)?void 0:a.height)?s:36,i=R(o.uuid),u=o.cellStyle;if(o.cellStyle=function(e){const o={};if(l.value){const n=Math.max(t,i.getMax(l.value.getRowSeq(e.row)));o.height=`${n}px`}return Object.assign(o,u?x(u)?u(e):u:null)},o.sortableConfig&&o.sortableConfig.enable){const t=o.sortableConfig.onEnd;o.sortableConfig.onEnd=function(l){const n=S(o.uuid);if(n){const{internalData:{elemStore:t}}=n,l=t["main-table-body"];l&&e(l)&&j(n,o,{scrollTop:e(l).scrollTop})}x(t)&&t(l)}}o.scrollY={...o.scrollY,mode:"default"},o.onWheel=function(t){let o=null,l=0,n=!0;return function(r){if(!t.uuid)return;const a=S(t.uuid);if(!a)return;const{internalData:s}=a,{isHover:i}=t.rowConfig||{},{deltaX:u,deltaY:c}=r,{refTableLeftBody:d,refTableRightBody:p,refTableBody:f}=a.getRefMaps(),h=c,g=u,v=h<0,x=e(f),y=x?x.$el:null;if(!y)return;if(v?y.scrollTop<=0:y.scrollTop>=y.scrollHeight-y.clientHeight)return;const b=y.scrollTop+h,I=y.scrollLeft+g;if(b===s.lastScrollTop)return;r.preventDefault(),s.lastScrollTop=b,s.lastScrollLeft=I,s.lastScrollTime=Date.now(),i&&a.clearHoverRow();const w=d.value,T=p.value,D=w?w.$el:null,R=T?T.$el:null,M=Math.min(100,Math.abs(Math.floor(h/2)));n&&(l=y.scrollTop,n=!1),l+=M*(v?-1:1),o&&o(),o=m(y.scrollTop,l,400,(e=>{y.scrollTop=e,D&&(D.scrollTop=e),R&&(R.scrollTop=e)}),"easeOutCubic",(()=>{l=y.scrollTop,n=!0})),Y(a,t,y)}}(o),setTimeout((()=>{k(o.uuid,o.scrollY),r(o)}),300),n()}})),t))),n.setupHooks.setup.tap(o,(e=>{t((()=>{e.value.uuid&&(M(e.value.uuid),H(e.value.uuid),$(e.value.uuid))}))}))}})}export{E as variableHeightRendererPlugin};
1
+ import{unref as e,onBeforeUnmount as t,shallowReactive as o,createVNode as l,defineComponent as n,inject as r,ref as a,computed as s,provide as i,watch as u,onMounted as c,h as d}from"vue";import{traverse as p,widthAppend as f}from"../../../../shared/utils/index.js";import{doAnimation as m}from"../../../../shared/utils/anime.js";import{useThrottleFn as h}from"@vueuse/core";import{promiseTimeout as g}from"@vueuse/shared";import{last as v,isFunction as x,isNumber as y}from"lodash-es";import"../../index.js";import{InjectionIhoTableUUID as b}from"../constants/index.js";import{useUUIDMap as I,isVariableHeightColumn as w}from"../utils/index.js";import{defineTablePlugin as T}from"../hooks/useTablePlugin.js";class D{constructor(){this.records={},this.maxRecords=o(new Map)}set(e,t,o){if(this.records[e]||(this.records[e]={}),this.records[e][t]===o)return;this.records[e][t]=o;const l=Math.max(...Object.values(this.records[e]),0);this.maxRecords.get(e)!==l&&this.maxRecords.set(e,l)}getMax(e){return this.maxRecords.get(e)||0}}const{getItemFromUUID:R,removeItemFromUUID:M}=I((()=>new D),!0),{getItemFromUUID:S,removeItemFromUUID:H,setItemFromUUID:U}=I((()=>null)),{getItemFromUUID:C,removeItemFromUUID:$,setItemFromUUID:k}=I((()=>{}));let F={};function j(t,o,{scrollTop:l=0}){var n,r;const{uuid:a,rowConfig:s={}}=o;if(!a)return;const i=R(a),{oSize:u=0,gt:c=100}=null!=(n=C(a))?n:{},{internalData:d,reactData:p}=t,{scrollYStore:f,elemStore:m,afterFullData:h,fullDataRowIdData:g}=d;if(c>h.length)return;const y=null!=(r=s.height)?r:36,b=m["main-body-wrapper"],I=b?e(b):null;let w=I?Math.max(8,Math.ceil(I.clientHeight/y)+2+u):8;const T=[0];let D=0;if(l&&h.find(((e,o)=>{const n=t.getRowSeq(e),r=(v(T)||0)+Math.max(y,i.getMax(n));if(T.push(r),r>l)return D=Math.max(0,o-u),w+=Math.min(D,u),!0})),D>0&&x(o.spanMethod)){const{spanMethod:e}=o,l={rowspan:1,colspan:1};for(;D>0;){if(!t.getColumns().some(((t,o)=>{const{rowspan:n,colspan:r}=e({column:t,columnIndex:o,$columnIndex:o,row:h[D],rowIndex:D,$rowIndex:D,_rowIndex:D,isHidden:!t.visible,fixed:t.fixed,type:t.type,visibleData:h})||l;if(0===n&&0===r)return D--,!0})))break}}const M=`${T[D]}px`,S=`${h.reduce(((e,o)=>{const l=t.getRowSeq(o);return e+Math.max(y,i.getMax(l))}),0)}px`;["main","left","right"].forEach((t=>{const o=m[`${t}-body-table`],n=o?e(o):null;n&&(n.style.marginTop=M,n.scrollTop=l),["header","body","footer"].forEach((o=>{const l=m[`${t}-${o}-ySpace`],n=l?e(l):null;n&&(n.style.height=S)}))}));const H=Math.min(h.length,D+w);if(f.startIndex===D&&f.endIndex===H)return;f.startIndex=D,f.endIndex=H;const U=h.slice(f.startIndex,f.endIndex);U.forEach(((e,o)=>{const l=t.getRowid(e),n=g[l];n&&(n.$index=o)})),p.tableData.length=0,p.tableData.push(...U)}const Y=h(j,300);function E(){const o="variableHeightRendererPlugin";return T({name:o,vxe(e){F=n({props:{payload:{type:Object,required:!0}},setup(t){const o=r(b),n=r("$xetable"),p=a(),m=R(o),h=s((()=>t.payload.row[t.payload.column.field]));function v(){const{row:e,column:o}=t.payload,l=n.getRowSeq(e);if(!m||null==l||!p.value)return;const r=p.value.clientHeight;m.set(l,o.field,r)}i("updateCellHeight",v),u([()=>t.payload.rowIndex,()=>t.payload.column.field,h,()=>t.payload.column.renderWidth],(async()=>{await g(0),v()})),c((()=>{n&&!S(o)&&U(o,n),v()}));const I=s((()=>{var o,l,n,r,a;const s=null!=(l=null==(o=t.payload.column.editRender)?void 0:o.props)?l:{},i=null!=(r=null==(n=s.slots)?void 0:n.default)?r:s.slotFn;if(x(i))return i;const u=null==(a=t.payload.column.editRender)?void 0:a.name;if(u){const o=e.renderer.get(u);if(null==o?void 0:o.renderCell)return()=>o.renderCell(t.payload.column.editRender,t.payload)}return()=>h.value})),w=s((()=>{if(t.payload.column.treeNode)return"";const e=t.payload.column.renderWidth;return y(e)&&e>0?f(e-20-2):""}));return()=>l("div",{ref:p,style:{padding:"7px 0",width:w.value,overflow:"hidden"}},[d(I.value,t.payload)])}})},apply(n){function r(t){const o=S(t.uuid);if(!o)return;t.scrollY={enabled:!1},o.reactData.scrollYLoad=!1;const l=function(t){const o=t.internalData.elemStore["main-body-wrapper"];return o?e(o):null}(o);l&&j(o,t,{scrollTop:l.scrollTop})}function a(e){if(!e.uuid)return;const t=C(e.uuid);t&&(e.scrollY=t),setTimeout((()=>r(e)),300)}function s(e){return l(F,{payload:e},null)}n.dataHooks.dataStart.tap(o,a),n.eventHooks.onFilterChange.tap(o,((e,t)=>a(t))),n.eventHooks.onSortChange.tap(o,((e,t)=>a(t))),n.eventHooks.onToggleTreeExpand.tap(o,((e,t)=>a(t))),n.eventHooks.onResizableChange.tap(o,(async({column:e},t)=>{e.editRender&&e.editRender.props&&w(e.editRender.props)&&a(t)})),n.eventHooks.onScroll.tap(o,h(((e,t)=>{if(e.isX)return;const{uuid:o}=t;if(!o)return;const l=S(o);l&&j(l,t,e)}),100,!0,!0)),n.fieldHooks.field.tap(o,(e=>{if(w(e)){e.slots={...e.slots,default:s};const t=e.className,o="variable-height";e.className=t?function(e){return x(t)?[t(e),o]:[t,o]}:o}return e})),n.fieldHooks.fieldList.tap(o,((t,o,{$table:l})=>(o.uuid&&p(t,((t,n)=>{var a,s;if(w(t)){const t=null!=(s=null==(a=o.rowConfig)?void 0:a.height)?s:36,i=R(o.uuid),u=o.cellStyle;if(o.cellStyle=function(e){const o={};if(l.value){const n=Math.max(t,i.getMax(l.value.getRowSeq(e.row)));o.height=`${n}px`}return Object.assign(o,u?x(u)?u(e):u:null)},o.sortableConfig&&o.sortableConfig.enable){const t=o.sortableConfig.onEnd;o.sortableConfig.onEnd=function(l){const n=S(o.uuid);if(n){const{internalData:{elemStore:t}}=n,l=t["main-table-body"];l&&e(l)&&j(n,o,{scrollTop:e(l).scrollTop})}x(t)&&t(l)}}o.scrollY={...o.scrollY,mode:"default"},o.onWheel=function(t){let o=null,l=0,n=!0;return function(r){if(!t.uuid)return;const a=S(t.uuid);if(!a)return;const{internalData:s}=a,{isHover:i}=t.rowConfig||{},{deltaX:u,deltaY:c}=r,{refTableLeftBody:d,refTableRightBody:p,refTableBody:f}=a.getRefMaps(),h=c,g=u,v=h<0,x=e(f),y=x?x.$el:null;if(!y)return;if(v?y.scrollTop<=0:y.scrollTop>=y.scrollHeight-y.clientHeight)return;const b=y.scrollTop+h,I=y.scrollLeft+g;if(b===s.lastScrollTop)return;r.preventDefault(),s.lastScrollTop=b,s.lastScrollLeft=I,s.lastScrollTime=Date.now(),i&&a.clearHoverRow();const w=d.value,T=p.value,D=w?w.$el:null,R=T?T.$el:null,M=Math.min(100,Math.abs(Math.floor(h/2)));n&&(l=y.scrollTop,n=!1),l+=M*(v?-1:1),o&&o(),o=m(y.scrollTop,l,400,(e=>{y.scrollTop=e,D&&(D.scrollTop=e),R&&(R.scrollTop=e)}),"easeOutCubic",(()=>{l=y.scrollTop,n=!0})),Y(a,t,y)}}(o),setTimeout((()=>{k(o.uuid,o.scrollY),r(o)}),300),n()}})),t))),n.setupHooks.setup.tap(o,(e=>{t((()=>{e.value.uuid&&(M(e.value.uuid),H(e.value.uuid),$(e.value.uuid))}))}))}})}export{E as variableHeightRendererPlugin};
@@ -1 +1 @@
1
- import{traverse as e,findAncestor as n,getStringWidth as t}from"../../../../../../shared/utils/index.js";import{isString as r,isNumber as o,constant as i,isFunction as a,noop as l,range as d,property as u}from"lodash-es";import{IhoTableRenderHelper as c}from"../../../utils/index.js";import{VERTICAL_CELL_TYPE as f}from"./constants.js";function s(e){var n;return!!(null==(n=e.verticalConfig)?void 0:n.enable)}function p(e){return!!r(e)&&e.startsWith("header_")}function h(e){return!!r(e)&&e.startsWith("body_")}function _(e){var n;return r(e)?+(null!=(n=e.split("_")[1])?n:-1):-1}function m(n,t){const r=[];return e(n,((n,o,i)=>{n.parent=i,n.children||(!function(n,t){if(!n.parent)return n[`header_${t}`]=n.title,void d(t+1).forEach((e=>{n[`header_${e}_colspan`]=e===t?t+1:0,n[`header_${e}_rowspan`]=e===t?1:0}));let r=0,o=n;const i=[n];for(;o.parent;)r++,o=o.parent,i.unshift(o);d(t+1).forEach((o=>{var a,l;const d=i[o];if(!d)return n[`header_${o}`]="",n[`header_${o}_colspan`]=0,void(n[`header_${o}_rowspan`]=0);n[`header_${o}`]=null!=(l=null==(a=i[o])?void 0:a.title)?l:"",n[`header_${o}_colspan`]=o<r?1:t-r+1,n[`header_${o}_rowspan`]=function(n){if(!n.children)return 1;let t=0;return e(n.children,(e=>{e.children||t++})),t}(d)}))}(n,t),r.push(n))})),r.forEach(((e,n)=>{const o=r[n-1];o&&Object.entries(e).forEach((([n,r])=>{n.match(/^header_(\d+)$/)&&r===o[n]&&r&&n!==`header_${t}`&&(e[`${n}_colspan`]=0,e[`${n}_rowspan`]=0)}))})),r}const g=Object.freeze({rowspan:1,colspan:1});function w(e,n,t){var r,o;if(!p(e.column.field)){if(!n||!t)return g;const r=n(j(e,t));return r?{rowspan:r.colspan,colspan:r.rowspan}:g}return{rowspan:null!=(r=e.row[e.column.field+"_rowspan"])?r:1,colspan:null!=(o=e.row[e.column.field+"_colspan"])?o:1}}const x=({cell:e,row:n}={})=>{const t=e&&e.querySelector("input,.n-input__input-el,.n-input__textarea-el");if(t){const e=n?y(n):void 0;"INPUT"===(null==e?void 0:e.editRender.name)?t.focus():t.click()}return t};function v(n,r){let o=120;return e(r,((e,r,i,a)=>{a===n&&(o=Math.max(o,t(e.title||"")+20+(c.hasTitlePrefix(e)?20:0)))})),Math.ceil(o)}function $(e,n,t){const r=D(t);let u=r.getTableConfig("verticalConfig.headerWidth");u="auto"===u?v:o(u)?i(u):a(u)?u:v;let c=r.getTableConfig("verticalConfig.bodyWidth");c=o(c)?i(c):a(c)?c:l;let s=r.getTableConfig("verticalConfig.bodyMinWidth");return s=o(s)?i(s):a(s)?s:i(120),[...d(n+1).map((e=>({field:`header_${e}`,title:`header_${e}`,width:u(e,t.originalFieldList),fixed:"left",editRender:{name:f,props:{},enable:!1}}))),...e.map(((e,n)=>({field:`body_${n}`,title:`body_${n}`,minWidth:s(n),width:c(n),editRender:{name:f,props:{},enable:!0,autofocus:x}})))]}function b(e){const t=n(e.target,(e=>"TD"===e.tagName||"TH"===e.tagName));if(!t)return;const r=t.className.match(/(body|header)_(\d+)/);if(!r)return;const[o,i,a]=r;return{fieldKey:o,type:i,sequence:+a}}function y(e){return e.originalField}function I(e,n){var t;return null==(t=e.originalData)?void 0:t[n]}function C(e,n){const t=_(n.field),r=y(e);return{row:I(e,t),rowIndex:t,$rowIndex:t,column:r,fixed:r.fixed,type:r.type}}function T(n){const t=[];return e(n,(e=>{"left"===e.fixed&&t.push(e)})),t}function D(e){return{getOriginDataByColumn(n){var t;return null==(t=e.originalData)?void 0:t[_(n.field)]},getTableConfig:n=>u(n)(e.originalTableConfig)}}function W(e,n){return new Proxy({},{get(t,r){var o;if("originalField"===r)return e;if("originalData"===r)return a(n)?n():n;if(p(r))return e[r];if(h(r)){const t=_(r);return"seq"===e.type?t+1:null==(o=n[t])?void 0:o[e.field]}return t[r]},set(t,r,o){if(!p(r)){const t=_(r);t>=0&&n[t]&&(n[t][e.field]=o)}return!0}})}function j({$columnIndex:e,$rowIndex:n,column:t,columnIndex:r,row:o,rowIndex:i,type:a,_columnIndex:l,_rowIndex:d},u){var c;if(t){const f=a;if(a=p(t.field)?"header":"body",o){const s=_(t.field);t=y(o),o="header"===a?void 0:I(o,s),l=r=e="header"===f?n||0:((null==(c=u.fixedLeftVerticalData)?void 0:c.length)||0)+(n||0),d=i=n="header"===a?-1:s}}return{column:t,row:o,_columnIndex:l,_rowIndex:d,columnIndex:r,rowIndex:i,$columnIndex:e,$rowIndex:n,type:a}}x.toString=()=>"input,.n-input__input-el";export{j as basicParamsConvert,m as bindHeaderInfoAndFlatten,W as createDataProxy,$ as createVerticalFieldList,D as createVerticalStateHandler,T as findFixedLeftFields,_ as getHeaderDepthByField,C as getOriginBasePayload,y as getOriginFieldFromRowData,I as getOriginRowFromRowData,w as getSpanInfo,b as getVerticalInfoFromEvent,h as isVerticalBody,p as isVerticalHeader,s as isVerticalTable};
1
+ import{traverse as e,findAncestor as n,getStringWidth as t}from"../../../../../../shared/utils/index.js";import{isString as r,isNumber as i,constant as o,isFunction as a,noop as l,range as d,property as u}from"lodash-es";import{IhoTableRenderHelper as c}from"../../../utils/index.js";import{VERTICAL_CELL_TYPE as f}from"./constants.js";function s(e){var n;return!!(null==(n=e.verticalConfig)?void 0:n.enable)}function p(e){return!!r(e)&&e.startsWith("header_")}function h(e){return!!r(e)&&e.startsWith("body_")}function _(e){var n;return r(e)?+(null!=(n=e.split("_")[1])?n:-1):-1}function m(n,t){const r=[];return e(n,((n,i,o)=>{n.parent=o,n.children||(!function(n,t){if(!n.parent)return n[`header_${t}`]=n.title,void d(t+1).forEach((e=>{n[`header_${e}_colspan`]=e===t?t+1:0,n[`header_${e}_rowspan`]=e===t?1:0}));let r=0,i=n;const o=[n];for(;i.parent;)r++,i=i.parent,o.unshift(i);d(t+1).forEach((i=>{var a,l;const d=o[i];if(!d)return n[`header_${i}`]="",n[`header_${i}_colspan`]=0,void(n[`header_${i}_rowspan`]=0);n[`header_${i}`]=null!=(l=null==(a=o[i])?void 0:a.title)?l:"",n[`header_${i}_colspan`]=i<r?1:t-r+1,n[`header_${i}_rowspan`]=function(n){if(!n.children)return 1;let t=0;return e(n.children,(e=>{e.children||t++})),t}(d)}))}(n,t),r.push(n))})),r.forEach(((e,n)=>{const i=r[n-1];i&&Object.entries(e).forEach((([n,r])=>{n.match(/^header_(\d+)$/)&&r===i[n]&&r&&n!==`header_${t}`&&(e[`${n}_colspan`]=0,e[`${n}_rowspan`]=0)}))})),r}const g=Object.freeze({rowspan:1,colspan:1});function x(e,n,t){var r,i;if(!p(e.column.field)){if(!n||!t)return g;const r=n(j(e,t));return r?{rowspan:r.colspan,colspan:r.rowspan}:g}return{rowspan:null!=(r=e.row[e.column.field+"_rowspan"])?r:1,colspan:null!=(i=e.row[e.column.field+"_colspan"])?i:1}}const w=({cell:e}={})=>{const n=e&&e.querySelector("input,.n-input__input-el,.n-input__textarea-el");return n&&n.click(),n};function $(n,r){let i=120;return e(r,((e,r,o,a)=>{a===n&&(i=Math.max(i,t(e.title||"")+20+(c.hasTitlePrefix(e)?20:0)))})),Math.ceil(i)}function v(e,n,t){const r=D(t);let u=r.getTableConfig("verticalConfig.headerWidth");u="auto"===u?$:i(u)?o(u):a(u)?u:$;let c=r.getTableConfig("verticalConfig.bodyWidth");c=i(c)?o(c):a(c)?c:l;let s=r.getTableConfig("verticalConfig.bodyMinWidth");return s=i(s)?o(s):a(s)?s:o(120),[...d(n+1).map((e=>({field:`header_${e}`,title:`header_${e}`,width:u(e,t.originalFieldList),fixed:"left",editRender:{name:f,props:{},enable:!1}}))),...e.map(((e,n)=>({field:`body_${n}`,title:`body_${n}`,minWidth:s(n),width:c(n),editRender:{name:f,props:{},enable:!0,autofocus:w}})))]}function b(e){const t=n(e.target,(e=>"TD"===e.tagName||"TH"===e.tagName));if(!t)return;const r=t.className.match(/(body|header)_(\d+)/);if(!r)return;const[i,o,a]=r;return{fieldKey:i,type:o,sequence:+a}}function y(e){return e.originalField}function I(e,n){var t;return null==(t=e.originalData)?void 0:t[n]}function C(e,n){const t=_(n.field),r=y(e);return{row:I(e,t),rowIndex:t,$rowIndex:t,column:r,fixed:r.fixed,type:r.type}}function T(n){const t=[];return e(n,(e=>{"left"===e.fixed&&t.push(e)})),t}function D(e){return{getOriginDataByColumn(n){var t;return null==(t=e.originalData)?void 0:t[_(n.field)]},getTableConfig:n=>u(n)(e.originalTableConfig)}}function W(e,n){return new Proxy({},{get(t,r){var i;if("originalField"===r)return e;if("originalData"===r)return a(n)?n():n;if(p(r))return e[r];if(h(r)){const t=_(r);return"seq"===e.type?t+1:null==(i=n[t])?void 0:i[e.field]}return t[r]},set(t,r,i){if(!p(r)){const t=_(r);t>=0&&n[t]&&(n[t][e.field]=i)}return!0}})}function j({$columnIndex:e,$rowIndex:n,column:t,columnIndex:r,row:i,rowIndex:o,type:a,_columnIndex:l,_rowIndex:d},u){var c;if(t){const f=a;if(a=p(t.field)?"header":"body",i){const s=_(t.field);t=y(i),i="header"===a?void 0:I(i,s),l=r=e="header"===f?n||0:((null==(c=u.fixedLeftVerticalData)?void 0:c.length)||0)+(n||0),d=o=n="header"===a?-1:s}}return{column:t,row:i,_columnIndex:l,_rowIndex:d,columnIndex:r,rowIndex:o,$columnIndex:e,$rowIndex:n,type:a}}w.toString=()=>"input,.n-input__input-el";export{j as basicParamsConvert,m as bindHeaderInfoAndFlatten,W as createDataProxy,v as createVerticalFieldList,D as createVerticalStateHandler,T as findFixedLeftFields,_ as getHeaderDepthByField,C as getOriginBasePayload,y as getOriginFieldFromRowData,I as getOriginRowFromRowData,x as getSpanInfo,b as getVerticalInfoFromEvent,h as isVerticalBody,p as isVerticalHeader,s as isVerticalTable};
@@ -216,7 +216,6 @@ export type LowCodeTableFieldItem = {
216
216
  colWidth: VxeTableDefines.ColumnInfo['width'];
217
217
  settingObj: IhoTableLowCodeField.SettingObj;
218
218
  treeNode: boolean;
219
- connectField: string;
220
219
  isShow: MaybeString<0 | 1>;
221
220
  isSort: MaybeString<0 | 1>;
222
221
  isOrder: MaybeString<0> | VxeTablePropTypes.SortOrder;
@@ -151,9 +151,9 @@ type DataHookContext = {
151
151
  };
152
152
  export type WithTableDataContext<T> = [...WithTableConfig<T>, DataHookContext];
153
153
  export declare abstract class AbstractDataHooks {
154
- abstract readonly dataStart: AsyncParallelHook<WithTableConfig<IhoTableHandlerContext>>;
154
+ abstract readonly dataStart: AsyncParallelHook<WithTableConfig>;
155
155
  abstract readonly data: AsyncSeriesHook<WithTableDataContext<[AnyObject]>>;
156
- abstract readonly dataEnd: AsyncParallelHook<WithTableConfig<IhoTableHandlerContext>>;
156
+ abstract readonly dataEnd: AsyncParallelHook<WithTableConfig>;
157
157
  abstract readonly dataList: SyncWaterfallHook<WithTableConfig<[AnyObject[]]>>;
158
158
  }
159
159
  export declare abstract class AbstractSetupHooks {