cnhis-design-vue 3.1.56 → 3.1.57-release.0

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 (69) hide show
  1. package/README.md +87 -87
  2. package/es/components/audio-sdk/src/audioSDK.js +1 -1
  3. package/es/components/button-print/src/utils/print.d.ts +3 -0
  4. package/es/components/button-print/src/utils/print.js +1 -1
  5. package/es/components/classification/index.d.ts +19 -16
  6. package/es/components/classification/src/components/search-filter/index.vue2.js +1 -1
  7. package/es/components/classification/src/components/set-classification/index.vue.d.ts +0 -15
  8. package/es/components/classification/src/components/table-modal/index.vue.d.ts +3 -15
  9. package/es/components/classification/src/components/table-modal/index.vue2.js +1 -1
  10. package/es/components/classification/src/index.vue.d.ts +45 -38
  11. package/es/components/classification/src/index.vue2.js +1 -1
  12. package/es/components/classification/style/index.css +1 -1
  13. package/es/components/expand-field/src/components/form.vue2.js +1 -1
  14. package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogram.js +1 -1
  15. package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogramChart.js +1 -1
  16. package/es/components/fabric-chart/src/hooks/electrocardiogram/useMeasureInstrument.js +1 -1
  17. package/es/components/form-config/index.d.ts +9 -7
  18. package/es/components/form-config/src/FormConfig.vue.d.ts +9 -7
  19. package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +3 -3
  20. package/es/components/form-config/src/components/FormConfigEventSetting.vue.d.ts +1 -0
  21. package/es/components/form-render/src/components/renderer/switch.d.ts +16 -2
  22. package/es/components/form-render/src/components/renderer/switch.js +1 -1
  23. package/es/components/form-render/src/hooks/useComplexOptions.d.ts +1 -1
  24. package/es/components/form-render/src/hooks/useComplexOptions.js +1 -1
  25. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -1
  26. package/es/components/form-render/src/hooks/useLowCodeReactions.js +1 -1
  27. package/es/components/form-render/src/types/fieldItem.d.ts +3 -8
  28. package/es/components/iho-table/src/constants/index.d.ts +1 -0
  29. package/es/components/iho-table/src/constants/index.js +1 -1
  30. package/es/components/iho-table/src/plugins/index.js +1 -1
  31. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.d.ts +48 -10
  32. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue2.js +1 -1
  33. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/radioRendererPlugin.js +1 -1
  34. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/switchRendererPlugin.d.ts +1 -0
  35. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/switchRendererPlugin.js +1 -0
  36. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin/editTime.vue2.js +1 -1
  37. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/checkRendererPlugin.js +1 -1
  38. package/es/components/iho-table/src/types/index.d.ts +3 -0
  39. package/es/components/index.css +1 -1
  40. package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
  41. package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
  42. package/es/components/select-person/src/SearchMultiple.vue.d.ts +6 -0
  43. package/es/components/shortcut-setter/index.d.ts +1 -1
  44. package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +1 -1
  45. package/es/components/table-export-field/src/components/ExportModal.vue.d.ts +0 -3
  46. package/es/components/table-filter/src/types/index.d.ts +3 -1
  47. package/es/env.d.ts +25 -25
  48. package/es/shared/assets/img/failure.png.js +1 -1
  49. package/es/shared/assets/img/no-permission.png.js +1 -1
  50. package/es/shared/assets/img/nodata.png.js +1 -1
  51. package/es/shared/assets/img/notfound.png.js +1 -1
  52. package/es/shared/assets/img/qr.png.js +1 -1
  53. package/es/shared/assets/img/success.png.js +1 -1
  54. package/es/shared/assets/img/video.png.js +1 -1
  55. package/es/shared/assets/img/video_default_cover.png.js +1 -1
  56. package/es/shared/assets/img/xb_big.png.js +1 -1
  57. package/es/shared/assets/img/xb_small.png.js +1 -1
  58. package/es/shared/hooks/selectHooks/useSelectRenders.d.ts +1 -1
  59. package/es/shared/hooks/selectHooks/useSelectRenders.js +1 -1
  60. package/es/shared/package.json.js +1 -1
  61. package/es/shared/types/business.d.ts +6 -0
  62. package/package.json +2 -2
  63. package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
  64. package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +0 -1
  65. package/es/components/bpmn-workflow/types/ModelingModule.d.ts +0 -1
  66. package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +0 -1
  67. package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +0 -86
  68. package/es/shared/utils/fabricjs/index.d.ts +0 -6823
  69. package/es/shared/utils/tapable/index.d.ts +0 -139
@@ -1 +1 @@
1
- import{defineComponent as e,useAttrs as t,inject as r,ref as a,computed as i,openBlock as o,createBlock as s,unref as n,mergeProps as l,isRef as u}from"vue";import{generateTimeFormat as m}from"../../../../../../../shared/utils/index.js";import{isFunction as d}from"lodash-es";import{useIhoTableFormEvent as p}from"../../../../utils/index.js";import f from"../../../../../../date-picker/index.js";var w=e({__name:"editDate",props:{value:{type:String,default:void 0},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0}},emits:["update:value"],setup(e,{emit:w}){const c=e,D=t(),v=r("$xetable"),{emitFormChangeWithParams:b}=p({...c,$table:v}),y=a(),g=i({get:()=>c.value?c.value:null,set(e){const t=c.value;t!==e&&(w("update:value",e),b({oldValue:t}))}}),$=i((()=>{const e=D.valueFormat||"yyyy-MM-dd HH:mm:ss";return{valueFormat:e,format:e,timePickerProps:{format:m(e)}}})),{isStartDate:T=!1,isEndDate:h=!1}=D,x=D.connectField||"",j=(e,t)=>T&&x?e>t:!(!h||!x)&&e<t,F=e=>{const t=new Date(c.row[x]),r=new Date(e),{h:a,m:i,s:o}=S(t),s=(e,t,r,a)=>!(h&&r>a)&&(!(T&&r<a)&&j(e,t));return{isHourDisabled:t=>{if(!c.row[x])return!1;const i=new Date(`${c.row[x].split(" ")[0]} 00:00:00`).getTime(),{m:o,s:n}=S(r);return s(t,a,e-60*t*60*1e3-60*o*1e3-1e3*n,i)},isMinuteDisabled:t=>{if(!c.row[x])return!1;const o=new Date(`${c.row[x].split(" ")[0]} ${a}:00:00`).getTime(),{s:n}=S(r);return s(t,i,e-60*t*1e3-1e3*n,o)},isSecondDisabled:t=>{if(!c.row[x])return!1;const r=new Date(`${c.row[x].split(" ")[0]} ${a}:${i}:00`).getTime();return s(t,o,e-1e3*t,r)}}},H={type:D.type||"datetime",clearable:!0,allowedInvalidValue:"-",...D,...$.value,isDateDisabled:M(D.isDateDisabled)||(e=>!!c.row[x]&&j(e,h?new Date(`${c.row[x].split(" ")[0]} 00:00:00`).getTime():new Date(c.row[x]).getTime()))};function M(e){return d(e)?t=>e(t,c.row):null}function S(e){return{h:e.getHours(),m:e.getMinutes(),s:e.getSeconds()}}return H.type.includes("time")&&(H.isTimeDisabled=M(D.isTimeDisabled)||F),(e,t)=>(o(),s(n(f),l({ref_key:"formRef",ref:y},n(H),{"formatted-value":n(g),"onUpdate:formatted-value":t[0]||(t[0]=e=>u(g)?g.value=e:null)}),null,16,["formatted-value"]))}});export{w as default};
1
+ import{defineComponent as e,useAttrs as t,inject as i,ref as n,computed as r,openBlock as l,createBlock as o,unref as a,mergeProps as s,isRef as u}from"vue";import{generateTimeFormat as d}from"../../../../../../../shared/utils/index.js";import{isFunction as c}from"lodash-es";import{useIhoTableFormEvent as m}from"../../../../utils/index.js";import D from"../../../../../../date-picker/index.js";var f=e({__name:"editDate",props:{value:{type:String,default:null},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0},isStartDate:{type:Boolean,default:!1},isEndDate:{type:Boolean,default:!1},connectField:{type:String,default:"-_-"}},emits:["update:value"],setup(e,{emit:f}){const p=e,w=t(),v=i("$xetable"),{emitFormChangeWithParams:b}=m({...p,$table:v}),F=n(),g=r({get:()=>p.value?p.value:null,set(e){const t=p.value;if(t===e)return;const{isDateDisabled:i,isTimeDisabled:n}=y.value;if(e){const t=Date.parse(e);if(i(t))return;const{isHourDisabled:r,isMinuteDisabled:l,isSecondDisabled:o}=(null==n?void 0:n(t))||{},{h:a,m:s,s:u}=x(new Date(e)),d=null==r?void 0:r(a),c=null==l?void 0:l(s,a),m=null==o?void 0:o(u,s,a);if(d||c||m)return}f("update:value",e),b({oldValue:t})}}),y=r((()=>{const{valueFormat:e,format:t,type:i="datetime"}=w;return{type:i,clearable:!0,allowedInvalidValue:"-",...w,timePickerProps:{format:d(e||t)},isDateDisabled:h(w.isDateDisabled)||S,isTimeDisabled:(null==i?void 0:i.includes("time"))?h(w.isTimeDisabled)||T:void 0}}));function $(e,t){return p.isStartDate&&p.connectField?e>t:!(!p.isEndDate||!p.connectField)&&e<t}function S(e){return!!p.row[p.connectField]&&$(e,p.isEndDate?new Date(`${p.row[p.connectField].split(" ")[0]} 00:00:00`).getTime():new Date(p.row[p.connectField]).getTime())}function T(e){const t=new Date(p.row[p.connectField]),i=new Date(e),{h:n,m:r,s:l}=x(t),o=(e,t,i,n)=>!(p.isEndDate&&i>n)&&(!(p.isStartDate&&i<n)&&$(e,t));return{isHourDisabled:t=>{if(!p.row[p.connectField])return!1;const r=new Date(`${p.row[p.connectField].split(" ")[0]} 00:00:00`).getTime(),{m:l,s:a}=x(i);return o(t,n,e-60*t*60*1e3-60*l*1e3-1e3*a,r)},isMinuteDisabled:t=>{if(!p.row[p.connectField])return!1;const l=new Date(`${p.row[p.connectField].split(" ")[0]} ${n}:00:00`).getTime(),{s:a}=x(i);return o(t,r,e-60*t*1e3-1e3*a,l)},isSecondDisabled:t=>{if(!p.row[p.connectField])return!1;const i=new Date(`${p.row[p.connectField].split(" ")[0]} ${n}:${r}:00`).getTime();return o(t,l,e-1e3*t,i)}}}function h(e){return c(e)?t=>e(t,p.row):null}function x(e){return{h:e.getHours(),m:e.getMinutes(),s:e.getSeconds()}}return(e,t)=>(l(),o(a(D),s({ref_key:"formRef",ref:F},a(y),{"formatted-value":a(g),"onUpdate:formatted-value":t[0]||(t[0]=e=>u(g)?g.value=e:null)}),null,16,["formatted-value"]))}});export{f as default};
@@ -1 +1 @@
1
- import{computed as e,createVNode as t,mergeProps as o}from"vue";import{NRadio as n}from"naive-ui";import"../../../../index.js";import{EDITABLE_WIDGET_TYPE as r}from"../../../constants/index.js";import{IhoTableRenderHelper as i,getLowCodeFieldFromField as l,IhoTableUtils as d}from"../../../utils/index.js";import{defineTablePlugin as a}from"../../../hooks/useTablePlugin.js";function u(){const u="radioRendererPlugin";return a({name:u,vxe(l){l.renderer.add(r.RADIO,{renderCell:i.createRenderEdit((({fieldItem:r,emitFormChangeWithParams:i,row:l,column:d,$table:a})=>{const u=e({get:()=>l[d.field],set(){const{fullData:e}=a.getTableData();null==e||e.forEach((e=>e[d.field]=!1)),l[d.field]=!0,i({oldValue:!1})}}),f=(null==r?void 0:r.componentProps)||{};return[l.$__SEPARATE?"":t(n,o({checked:u.value,"onUpdate:checked":e=>u.value=e},f),null)]}))})},apply(e){function t(e){return d.getCellType(e)===r.RADIO}e.fieldHooks.field.tap(u,((e,o,n)=>{var r;const i=l(e);if(!i)return e;if(t(i)){const e=null==(r=n.editConfig)?void 0:r.beforeEditMethod;n.editConfig={...n.editConfig,beforeEditMethod:o=>{const{column:n}=o;return!t(l(n))&&(!e||e(o))}}}return e}))}})}export{u as radioRendererPlugin};
1
+ import{computed as e,createVNode as o,mergeProps as r}from"vue";import{NRadio as t}from"naive-ui";import"../../../../index.js";import{EDITABLE_WIDGET_TYPE as n}from"../../../constants/index.js";import{IhoTableRenderHelper as i,IhoTableUtils as l}from"../../../utils/index.js";import{isFunction as d}from"lodash-es";import{defineTablePlugin as a}from"../../../hooks/useTablePlugin.js";function u(){const u="radioRendererPlugin";return a({name:u,vxe(l){l.renderer.add(n.RADIO,{renderCell:i.createRenderEdit((({fieldItem:n,emitFormChangeWithParams:i,row:l,column:d,$table:a})=>{const u=e({get:()=>l[d.field],set(){const{fullData:e}=a.getTableData();null==e||e.forEach((e=>e[d.field]=!1)),l[d.field]=!0,i({oldValue:!1})}}),m=(null==n?void 0:n.componentProps)||{};return[l.$__SEPARATE?"":o(t,r({checked:u.value,"onUpdate:checked":e=>u.value=e},m),null)]}))})},apply(e){e.configHooks.editConfig.tap(u,((e={},o)=>{const r=e.beforeEditMethod;return e.beforeEditMethod=(...e)=>{var o;const{row:t,column:i}=e[0];return!function(e){return!!e&&l.getCellType(e)===n.RADIO}(null==(o=i.editRender)?void 0:o.props)&&(!d(r)||r(...e))},e}))}})}export{u as radioRendererPlugin};
@@ -0,0 +1 @@
1
+ export declare function switchRendererPlugin(): import("../../../../../../components/iho-table").TablePlugin;
@@ -0,0 +1 @@
1
+ import{computed as e,createVNode as i}from"vue";import{traverse as o}from"../../../../../../shared/utils/index.js";import{NSwitch as r,NCheckbox as t}from"naive-ui";import"../../../../index.js";import{EDITABLE_WIDGET_TYPE as d}from"../../../constants/index.js";import{IhoTableRenderHelper as n}from"../../../utils/index.js";import{defineTablePlugin as l}from"../../../hooks/useTablePlugin.js";function a(){const a="switchRendererPlugin";return l({name:a,vxe(o){o.renderer.add(d.SWITCH,{renderCell:n.createRenderEdit((({fieldItem:o,emitFormChangeWithParams:d,row:n,column:l})=>{var a,u;const{open:s={},close:c={},show_mode:m="SWITCH"}=o,f=null==(a=s.value)||a,v=null!=(u=c.value)&&u,p=e({get:()=>n[l.field]===f,set(e){const i=n[l.field];n[l.field]=e?f:v,d({oldValue:i})}});return[n.$__SEPARATE?"":"SWITCH"===m?i(r,{value:p.value,"onUpdate:value":e=>p.value=e},{checked:()=>s.describe,unchecked:()=>c.describe}):i(t,{checked:p.value,"onUpdate:checked":e=>p.value=e},{default:()=>s.describe})]}))})},apply(e){e.fieldHooks.fieldList.tap(a,((e,i)=>{var r;let t=!1;if(o(e,((e,i)=>{var o;(null==(o=e.editRender)?void 0:o.name)===d.SWITCH&&(t=!0,i())})),t){const e=null==(r=i.editConfig)?void 0:r.beforeEditMethod;i.editConfig={...i.editConfig,beforeEditMethod(i){var o;const{column:r}=i;return(null==(o=r.editRender)?void 0:o.name)!==d.SWITCH&&(!e||e(i))}}}return e}))}})}export{a as switchRendererPlugin};
@@ -1 +1 @@
1
- import{defineComponent as e,useAttrs as l,inject as t,ref as a,computed as r,reactive as u,watch as o,nextTick as i,openBlock as n,createBlock as d,unref as c,withCtx as v,createVNode as m,mergeProps as s,isRef as f,createElementBlock as p,Fragment as h,renderList as y,createTextVNode as k,toDisplayString as b,createCommentVNode as w}from"vue";import{NPopover as _,NInput as g,NSpace as V,NScrollbar as C,NButton as F}from"naive-ui";import{useIhoTableFormEvent as x}from"../../../../utils/index.js";import D from"../../../../../../time-picker/index.js";import{parse as q,isValid as O,getHours as j,getMinutes as S,getSeconds as $,format as A}from"date-fns";var H=e({__name:"editTime",props:{formattedValue:{type:String},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0},shortcutOptions:{type:Array,default:()=>[]}},emits:["update:formattedValue","click"],setup(e,{emit:H}){const I=e,P=l(),R=t("$xetable"),{emitFormChangeWithParams:E}=x({...I,$table:R}),M=a(null),U=a(!1),z=a(),K=a(),N=r((()=>K.value&&L(K.value)?{style:"text-decoration: line-through"}:{})),T=r({get(){if(!K.value)return null;const e=q(K.value,G.valueFormat,new Date);return O(e)?K.value:I.formattedValue?I.formattedValue:null},set(e){J(e)}}),{placeholder:W="请选择",valueFormat:B="HH:mm"}=P,G=u({...P,placeholder:W,valueFormat:B,format:B});function J(e){if(K.value=e||"",e&&L(e))return;const l=I.formattedValue;l!==e&&(H("update:formattedValue",e),E({oldValue:l}))}function L(e){var l,t,a;const r=q(e,G.format,new Date),u=j(r),o=S(r),i=$(r),n=null==(l=G.isHourDisabled)?void 0:l.call(G,u),d=null==(t=G.isMinuteDisabled)?void 0:t.call(G,o,u),c=null==(a=G.isSecondDisabled)?void 0:a.call(G,i,o,u);return!!n||(!!d||!!c)}function Q(){[G.valueFormat.replace(/[^\w]/g,""),G.valueFormat].some((e=>{const l=q(K.value,e,new Date);if(!K.value||O(l)){return J(K.value?A(l,G.valueFormat):null),!0}return!1}))}function X(e){var l;const{key:t}=e;"Enter"===t&&(null==(l=M.value)||l.blur(),U.value=!1)}return o((()=>I.formattedValue),(e=>{if(!e)return"";K.value=e}),{immediate:!0}),o((()=>U.value),(async e=>{var l,t,a,r,u;e&&(await i(),null==(u=null==(r=null==(a=null==(t=null==(l=z.value)?void 0:l.$timePicker)?void 0:t.panelInstRef)?void 0:a.$el)?void 0:r.querySelectorAll(".n-time-picker-col"))||u.forEach((e=>{var l,t;return null==(t=null==(l=null==e?void 0:e.querySelector)?void 0:l.call(e,".n-time-picker-col__item--active"))?void 0:t.scrollIntoView()})))})),(l,t)=>(n(),d(c(_),{show:U.value,trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"},onClickoutside:t[4]||(t[4]=()=>U.value=!1)},{trigger:v((()=>[m(c(g),{ref_key:"formRef",ref:M,clearable:"",placeholder:c(W),value:K.value,"onUpdate:value":t[0]||(t[0]=e=>K.value=e),valueModifiers:{trim:!0},"input-props":c(N),onClick:t[1]||(t[1]=()=>U.value=!0),onChange:Q,onKeydown:X},null,8,["placeholder","value","input-props"])])),default:v((()=>[m(c(V),null,{default:v((()=>[m(c(D),s({ref_key:"timePickerRef",ref:z,show:""},c(G),{class:"iho-table__time-picker",to:!1,"formatted-value":c(T),"onUpdate:formatted-value":t[2]||(t[2]=e=>f(T)?T.value=e:null),onConfirm:t[3]||(t[3]=()=>U.value=!1)}),null,16,["formatted-value"]),m(c(C),{class:"iho-table__scrollbar"},{default:v((()=>[e.shortcutOptions.length?(n(),d(c(V),{key:0,vertical:"",wrap:!1},{default:v((()=>[(n(!0),p(h,null,y(e.shortcutOptions,(e=>(n(),d(c(F),{size:"tiny",key:e,disabled:L(e),onClick:l=>function(e){J(e),U.value=!1}(e)},{default:v((()=>[k(b(e),1)])),_:2},1032,["disabled","onClick"])))),128))])),_:1})):w("v-if",!0)])),_:1})])),_:1})])),_:1},8,["show"]))}});export{H as default};
1
+ import{defineComponent as e,useAttrs as l,inject as t,ref as a,computed as r,reactive as u,watch as o,nextTick as i,openBlock as n,createBlock as d,unref as c,withCtx as v,createVNode as m,mergeProps as s,isRef as f,createElementBlock as p,Fragment as h,renderList as y,createTextVNode as k,toDisplayString as b,createCommentVNode as w}from"vue";import{NPopover as _,NInput as g,NSpace as V,NScrollbar as C,NButton as F}from"naive-ui";import{useIhoTableFormEvent as x}from"../../../../utils/index.js";import D from"../../../../../../time-picker/index.js";import{parse as q,isValid as O,getHours as j,getMinutes as S,getSeconds as $,format as A}from"date-fns";var H=e({__name:"editTime",props:{formattedValue:{type:String},column:{type:Object,required:!0},row:{type:Object,required:!0},rowIndex:{type:Number,required:!0},shortcutOptions:{type:Array,default:()=>[]}},emits:["update:formattedValue","click"],setup(e,{emit:H}){const I=e,P=l(),R=t("$xetable"),{emitFormChangeWithParams:E}=x({...I,$table:R}),M=a(null),U=a(!1),z=a(),K=a(),N=r((()=>K.value&&L(K.value)?{style:"text-decoration: line-through"}:{})),T=r({get(){if(!K.value)return null;const e=q(K.value,G.valueFormat,new Date);return O(e)?K.value:I.formattedValue?I.formattedValue:null},set(e){J(e)}}),{placeholder:W="请选择",valueFormat:B="HH:mm"}=P,G=u({...P,placeholder:W,valueFormat:B,format:B});function J(e){if(K.value=e||"",e&&L(e))return;const l=I.formattedValue;l!==e&&(H("update:formattedValue",e),E({oldValue:l}))}function L(e){var l,t,a;const r=q(e,G.format,new Date),u=j(r),o=S(r),i=$(r),n=null==(l=G.isHourDisabled)?void 0:l.call(G,u),d=null==(t=G.isMinuteDisabled)?void 0:t.call(G,o,u),c=null==(a=G.isSecondDisabled)?void 0:a.call(G,i,o,u);return n||d||c}function Q(){[G.valueFormat.replace(/[^\w]/g,""),G.valueFormat].some((e=>{const l=q(K.value,e,new Date);if(!K.value||O(l)){return J(K.value?A(l,G.valueFormat):null),!0}return!1}))}function X(e){var l;const{key:t}=e;"Enter"===t&&(null==(l=M.value)||l.blur(),U.value=!1)}return o((()=>I.formattedValue),(e=>{if(!e)return"";K.value=e}),{immediate:!0}),o((()=>U.value),(async e=>{var l,t,a,r,u;e&&(await i(),null==(u=null==(r=null==(a=null==(t=null==(l=z.value)?void 0:l.$timePicker)?void 0:t.panelInstRef)?void 0:a.$el)?void 0:r.querySelectorAll(".n-time-picker-col"))||u.forEach((e=>{var l,t;return null==(t=null==(l=null==e?void 0:e.querySelector)?void 0:l.call(e,".n-time-picker-col__item--active"))?void 0:t.scrollIntoView()})))})),(l,t)=>(n(),d(c(_),{show:U.value,trigger:"click",showArrow:!1,placement:"bottom-start",style:{padding:"0"},onClickoutside:t[4]||(t[4]=()=>U.value=!1)},{trigger:v((()=>[m(c(g),{ref_key:"formRef",ref:M,clearable:"",placeholder:c(W),value:K.value,"onUpdate:value":t[0]||(t[0]=e=>K.value=e),valueModifiers:{trim:!0},"input-props":c(N),onClick:t[1]||(t[1]=()=>U.value=!0),onChange:Q,onKeydown:X},null,8,["placeholder","value","input-props"])])),default:v((()=>[m(c(V),null,{default:v((()=>[m(c(D),s({ref_key:"timePickerRef",ref:z,show:""},c(G),{class:"iho-table__time-picker",to:!1,"formatted-value":c(T),"onUpdate:formatted-value":t[2]||(t[2]=e=>f(T)?T.value=e:null),onConfirm:t[3]||(t[3]=()=>U.value=!1)}),null,16,["formatted-value"]),m(c(C),{class:"iho-table__scrollbar"},{default:v((()=>[e.shortcutOptions.length?(n(),d(c(V),{key:0,vertical:"",wrap:!1},{default:v((()=>[(n(!0),p(h,null,y(e.shortcutOptions,(e=>(n(),d(c(F),{size:"tiny",key:e,disabled:L(e),onClick:l=>function(e){J(e),U.value=!1}(e)},{default:v((()=>[k(b(e),1)])),_:2},1032,["disabled","onClick"])))),128))])),_:1})):w("v-if",!0)])),_:1})])),_:1})])),_:1},8,["show"]))}});export{H as default};
@@ -1 +1 @@
1
- import{createVNode as e,defineComponent as n,inject as t}from"vue";import"../../../../index.js";import{NCheckbox as a}from"naive-ui";import{defineTablePlugin as o}from"../../../hooks/useTablePlugin.js";function s(){const n="checkRendererPlugin";return o({name:n,apply(t){t.fieldHooks.field.tap(n,((t,{index:a,insertBefore:o},s)=>{if(0===a&&s.selectType&&["checkbox","radio"].includes(s.selectType)){const{radioConfig:t,checkboxConfig:a={}}=s,r={width:45,align:"center",fixed:"left",..."radio"===s.selectType?t:a,field:n,type:s.selectType,annotation:!1};a.disableHeader&&(r.slots={header:()=>e("span",{class:"checkbox-cell--disable"},null),...r.slots}),a.useNCheckbox&&(r.slots={header:n=>[e(l,{style:"margin-left: -1px",params:n},null)],checkbox:n=>[e(l,{params:n},null)],...r.slots}),o(r)}return t}))}})}const l=n({name:"Checkbox",props:{params:{type:Object,default:()=>({})}},setup(n){const o=t("$xetable");function s(e){var t;"header"===(null==(t=n.params)?void 0:t.type)?null==o||o.triggerCheckAllEvent(new MouseEvent("mouse-down"),e):null==o||o.triggerCheckRowEvent(new MouseEvent("mouse-down"),n.params,e)}return()=>e(a,{checked:n.params.checked,"onUpdate:checked":e=>n.params.checked=e,indeterminate:n.params.indeterminate,disabled:n.params.disabled,onUpdateChecked:s},null)}});export{s as checkRendererPlugin};
1
+ import{createVNode as e,defineComponent as a,inject as o}from"vue";import"../../../../index.js";import{NCheckbox as t}from"naive-ui";import{defineTablePlugin as l}from"../../../hooks/useTablePlugin.js";function s(){const a="checkRendererPlugin";return l({name:a,apply(o){o.fieldHooks.field.tap(a,((o,{index:t,insertBefore:l},s)=>{if(0===t&&s.selectType&&["checkbox","radio"].includes(s.selectType)){const{radioConfig:o,checkboxConfig:t={}}=s,r={width:45,align:"center",fixed:"left",..."radio"===s.selectType?o:t,field:a,type:s.selectType,annotation:!1};t.disableHeader&&(r.slots={header:()=>e("span",{class:"checkbox-cell--disable"},null),...r.slots}),t.useNCheckbox&&(r.slots={...t.showHeader?{header:a=>[e(n,{style:"margin-left: -1px",params:a},null)]}:{},checkbox:a=>[e(n,{params:a},null)],...r.slots}),l(r)}return o}))}})}const n=a({name:"Checkbox",props:{params:{type:Object,default:()=>({})}},setup(a){const l=o("$xetable");function s(e,o){var t;o.stopPropagation(),"header"===(null==(t=a.params)?void 0:t.type)?null==l||l.toggleAllCheckboxRow():null==l||l.toggleCheckboxRow(a.params.row)}return()=>e(t,{checked:a.params.checked,"onUpdate:checked":e=>a.params.checked=e,indeterminate:a.params.indeterminate,disabled:a.params.disabled,onUpdateChecked:s},null)}});export{s as checkRendererPlugin};
@@ -160,6 +160,9 @@ export declare type LowCodeTableFieldItem = {
160
160
  autograph: string;
161
161
  wordbook: LowCodeTypes.wordbook;
162
162
  requestCache: boolean;
163
+ open: LowCodeTypes.switchProperty;
164
+ close: LowCodeTypes.switchProperty;
165
+ show_mode: LowCodeTypes.showModeType;
163
166
  lazyRequest: boolean;
164
167
  }> & Partial<VxeTableDefines.ColumnInfo>;
165
168
  export declare type IhoTableFormChangePayload = {