cnhis-design-vue 3.1.42-release.2 → 3.1.42-release.3

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 (85) hide show
  1. package/README.md +87 -87
  2. package/es/components/base-search/index.d.ts +2 -2
  3. package/es/components/base-search/src/index.vue.d.ts +2 -2
  4. package/es/components/bpmn-workflow/index.d.ts +12 -0
  5. package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
  6. package/es/components/bpmn-workflow/src/BpmnWorkflow.vue.d.ts +12 -0
  7. package/es/components/bpmn-workflow/src/BpmnWorkflow.vue.js +1 -1
  8. package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
  9. package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
  10. package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
  11. package/es/components/button-print/src/ButtonPrint.vue2.js +1 -1
  12. package/es/components/date-picker/index.d.ts +4 -0
  13. package/es/components/date-picker/src/DatePicker.vue.d.ts +4 -0
  14. package/es/components/date-picker/src/DatePicker.vue.js +1 -1
  15. package/es/components/fabric-chart/src/hooks/useBirthProcess.d.ts +1 -0
  16. package/es/components/fabric-chart/src/hooks/useBirthProcess.js +1 -1
  17. package/es/components/fabric-chart/src/hooks/useBirthProcessChart.js +1 -1
  18. package/es/components/fabric-chart/src/hooks/useCenter.js +1 -1
  19. package/es/components/fabric-chart/src/hooks/useLeft.js +1 -1
  20. package/es/components/fabric-chart/src/hooks/useScaleColumn.d.ts +16 -0
  21. package/es/components/fabric-chart/src/hooks/useScaleColumn.js +1 -0
  22. package/es/components/fabric-chart/src/utils/index.d.ts +6823 -0
  23. package/es/components/form-config/index.d.ts +6 -1
  24. package/es/components/form-config/src/FormConfig.vue.d.ts +6 -1
  25. package/es/components/form-config/src/FormConfig.vue.js +1 -1
  26. package/es/components/form-config/src/components/FormConfigCreator.vue.d.ts +1 -0
  27. package/es/components/form-config/src/components/FormConfigEdit.vue.d.ts +3 -1
  28. package/es/components/form-config/src/components/FormConfigEdit.vue.js +1 -1
  29. package/es/components/form-config/src/components/renderer/DefaultNode.vue.js +1 -1
  30. package/es/components/form-config/src/constants/index.d.ts +12 -1
  31. package/es/components/form-config/src/constants/index.js +1 -1
  32. package/es/components/form-config/src/hooks/useConfigurationField.js +1 -1
  33. package/es/components/form-config/src/types/index.d.ts +1 -0
  34. package/es/components/form-render/index.d.ts +1 -0
  35. package/es/components/form-render/src/FormRender.vue.d.ts +1 -0
  36. package/es/components/form-render/src/FormRender.vue.js +1 -1
  37. package/es/components/form-render/src/FormRenderWrapper.vue.d.ts +1 -0
  38. package/es/components/form-render/src/components/renderer/combination.js +1 -1
  39. package/es/components/form-render/src/components/renderer/jsonCombination/index.js +1 -1
  40. package/es/components/iho-table/index.d.ts +4 -1522
  41. package/es/components/iho-table/src/IhoTable.vue.d.ts +4 -1522
  42. package/es/components/iho-table/src/IhoTable.vue.js +1 -1
  43. package/es/components/iho-table/src/hooks/tapHooks/index.d.ts +4 -4
  44. package/es/components/iho-table/src/hooks/tapHooks/index.js +1 -1
  45. package/es/components/iho-table/src/hooks/tapHooks/useConfigHooks.d.ts +22 -21
  46. package/es/components/iho-table/src/hooks/tapHooks/useConfigHooks.js +1 -1
  47. package/es/components/iho-table/src/plugins/filterRenderPlugin/index.js +1 -1
  48. package/es/components/iho-table/src/plugins/highLightSetPlugin.d.ts +1 -0
  49. package/es/components/iho-table/src/plugins/highLightSetPlugin.js +1 -0
  50. package/es/components/iho-table/src/plugins/index.js +1 -1
  51. package/es/components/iho-table/src/plugins/lowCodeFieldAdaptorPlugin/index.js +1 -1
  52. package/es/components/iho-table/src/plugins/maxCheckSizePlugin.d.ts +1 -0
  53. package/es/components/iho-table/src/plugins/maxCheckSizePlugin.js +1 -0
  54. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/dateRendererPlugin/editDate.vue.d.ts +4 -0
  55. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +1 -1
  56. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/index.js +1 -1
  57. package/es/components/iho-table/src/plugins/rendererPlugins/widgets/defaultRendererPlugin.js +1 -1
  58. package/es/components/iho-table/src/plugins/varialbleHeightPlugin/index.js +1 -1
  59. package/es/components/iho-table/src/types/index.d.ts +2 -1
  60. package/es/components/iho-table/src/types/pluginType.d.ts +6 -3
  61. package/es/components/iho-table/src/utils/index.d.ts +2 -0
  62. package/es/components/iho-table/src/utils/index.js +1 -1
  63. package/es/components/iho-table/style/index.css +1 -1
  64. package/es/components/index.css +1 -1
  65. package/es/components/info-header/index.d.ts +2 -0
  66. package/es/components/info-header/src/InfoHeader.vue.d.ts +2 -0
  67. package/es/components/info-header/src/components/infoDescription/HiddenContent.vue.js +1 -1
  68. package/es/components/info-header/src/components/infoDescription/index.vue.d.ts +1 -0
  69. package/es/components/info-header/src/components/patientInfo/index.vue.d.ts +1 -0
  70. package/es/components/scale-view/index.d.ts +25 -66
  71. package/es/components/scale-view/src/ScaleView.vue.d.ts +25 -66
  72. package/es/components/scale-view/src/ScaleView.vue.js +1 -1
  73. package/es/components/scale-view/style/index.css +1 -1
  74. package/es/components/select-label/src/LabelFormContent.vue.js +1 -1
  75. package/es/components/shortcut-setter/index.d.ts +1 -0
  76. package/es/components/shortcut-setter/src/ShortcutSetter.vue.d.ts +1 -0
  77. package/es/components/table-filter/src/types/index.d.ts +2 -2
  78. package/es/env.d.ts +24 -24
  79. package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
  80. package/es/shared/hooks/useDateTime.d.ts +2 -2
  81. package/es/shared/hooks/useDateTime.js +1 -1
  82. package/es/shared/utils/tapable/index.d.ts +139 -0
  83. package/package.json +2 -2
  84. package/es/components/scale-view/src/hooks/scaleview-props.d.ts +0 -115
  85. package/es/components/scale-view/src/hooks/scaleview-props.js +0 -1
@@ -1 +1 @@
1
- import{fabric as t}from"../utils/index.js";import{defaultBorderStyle as e,defaultTextStyle as i,defaultStyle as n,drawPoint as o,drawTextGroup as l,defaultRectStyle as r}from"./useDraw.js";import{getType as s,isOneLine as u}from"../utils/utils.js";function h(h,a,c,g,p,f,d,y,w,v,S,b){var m,Y;const{getEqualXTypes:x,repeatTip:X}=b,{originY:T,endY:N,originX:L,endX:M,xCellWidth:V,yCellHeight:C,left:j,vitalSignsOriginY:k,painOriginY:E,painHeight:I,iconsWidth:G,itemList:H,painIndex:O,right:W,canvasWidth:A,canvasHeight:R,getRightInfo:_}=a;function B(e,n,o,l){const{position:r}=n;return new t.Text(String(e),{...i,originX:"left"==r?"right":"right"==r?"left":"center",left:o,top:l,...n.style})}function J(t="center",e,i){let n=e+i/2,o=[n-4.5,n+4.5],l=[n-2.5,n+2.5],r=n;return"right"===t&&(n=e,o=[n,n+9],l=[n,n+5],r=o[1]),"left"===t&&(n=e+i,o=[n-9,n],l=[n-5,n],r=o[0]),{lineXMain:o,lineXSub:l,textLeft:r}}function $(o){var s;if(!(null==o?void 0:o.length))return;const{layout:u}=o[0];let a=G,c=L;"right"===u&&(a=M,c=M+(null!=(s=null==W?void 0:W.width)?s:0));const g=[],p=I&&"right"!==u?o.length-1:o.length,f=(c-a)/p,d=f+(c-a)%p;o.forEach(((o,s)=>{var c,p;if("pain"===o.type)return void function(n){const o=l({width:L-G,height:I,...r},{value:`${n.title}`,...i,...n.style||{}},{left:G,top:E.originY}),s=[];if(n.showScale||n.showNumber){const{lineXMain:i,textLeft:o}=J(n.position,G,L-G),l=n.list.length;n.list.forEach(((r,u)=>{let h=E.endY-u*C*n.spaceGridNumber;0===u&&(h=N-5);const a=0===u||u===l-1;if(!n.showNumber||a&&!n.showMaxMinNumber||s.push(B(r,n,o,h)),n.showScale&&0!==u){const[o,l]=i,r=new t.Line([o,h,l,h],{...e,...n.style});s.push(r)}}))}h.value.add(o,...s),o.sendToBack()}(o);const y=[];function w(i){const n=new t.Line(i,{...e,...o.style});y.push(n)}const v=0===s?d:f,S=0===s?a:d+a+(s-1)*f,b="right"===u?0:k.originY,m="right"===u?R:k.endY,Y=s>0?new t.Line([S,b,S,m],{...e}):null;Y&&y.push(Y);const x=S+v/2,X=o.spaceGridNumber||5;if(o.showScale||o.showNumber){const t=X*C/5,e=o.position||"center",{lineXMain:i,lineXSub:n,textLeft:l}=J(o.position,S,v),r=null==(c=o.list)?void 0:c.length;null==(p=null==o?void 0:o.list)||p.forEach(((s,u)=>{const h=k.endY-u*C*X,a=0===u||u===r-1;if(o.showNumber&&(!a||o.showMaxMinNumber)){const t=0==u?h-5:h,e=B(s,o,l,t),i=k.originY+e.height/2;t<i&&e.set({top:i}),y.push(e)}if(o.showScale&&u!==r-1)for(let l=0;l<5;l++)if(l>0||!o.showNumber||"center"!==e){const e=0==l?i[0]:n[0],o=0==l?i[1]:n[1],s=h-l*t;s>k.originY&&(w([e,s,o,s]),u==r-2&&4==l&&w([i[0],s-t,i[1],s-t]))}}))}let T=o.title||"";o.unit&&(T+="\n"+o.unit),T&&y.push(new t.Text(String(T),{...i,left:x,top:k.originY+C*X/2,textAlign:"center",...o.style}));const M=new t.Group(y,{...n,objectCaching:!1});g.push(M)}));const y=g.length>0?new t.Group([...g],{...n,objectCaching:!1}):null;y&&h.value.add(y),y&&y.sendToBack()}function q(t){return t.left>=L&&t.left<M&&t.top>=T&&t.top<=N}G&&function(){const e=JSON.parse(JSON.stringify(H));let i=N;const l=G-j.icons.marginRight;e.reverse().forEach((e=>{i-=10;let r=e.title.replace(/(.{2})/g,"$1\n");r.endsWith("\n")&&(r=r.slice(0,r.length-1));const f=new t.Text(String(r),{...n,objectCaching:!1,...e.titleStyle||{},originX:"right",originY:"bottom",left:l-(e.pointAttr.width||10)-5,top:i,lineHeight:1,fontSize:12}),d=o(e.type,{left:l,top:i-(f.height||30)/2-1,...e.pointAttr,originY:"center",originX:"right",origin:{title:e.title,unit:e.unit,type:s(e.bigType),_type:e.bigType,dataIndex:e.dataIndex,key:e.key,isMenu:!0},originLeft:l,originTop:i-(f.height||30)/2-1,...a.event});var b;i-=f.height||30,(b=d).on("moving",(()=>{b.set("originX","center"),function(t){if(t.left>=L&&t.left<=M){t.setCoords();const e="pain"===t.origin.type?E:k;t.top<e.originY&&t.set("top",e.originY),t.top>e.endY&&t.set("top",e.endY)}}(b),q(b)?g(b):p.show=!1})),b.on("mouseup:before",(t=>{if(p.show=!1,0===t.e.button&&q(b)){const t=x(b.left,"_type",V).includes(b.origin._type),e=v(b.left);if(!e||t)t&&e&&X();else{const t={data:{time:y(b.left),value:w(b.origin.type,b.top),...u(b.origin.type)?{key:b.origin.key}:{}},...b.origin};c("add",t),S(t)}}!function(t){t.setCoords().set({originX:"right",left:t.originLeft,top:t.originTop})}(b)})),h.value.add(f,d)}))}();const z=j.yScaleValue.filter((t=>"left"===t.layout&&"pain"!==t.type&&t.show));if((null==W?void 0:W.width)&&"left"===(null==(m=null==W?void 0:W.yScaleValue)?void 0:m.layout)&&(null==(Y=null==W?void 0:W.yScaleValue)?void 0:Y.show)&&z.push(_),O>0&&j.yScaleValue[O].show){const t=j.yScaleValue[O];0===O&&j.yScaleValue.length>1&&z.unshift(t),O==j.yScaleValue.length-1&&z.push(t)}const D=z.findIndex((t=>"pulse"===t.type&&t.show&&t.doubleShow)),F=z[D];return D>-1&&z.splice(D,0,{...F,title:(null==F?void 0:F.doubleTitle)||(null==F?void 0:F.title)}),$(z),h.value.add(new t.Rect({left:G,top:0,width:A-G-1,height:R-1,fill:"transparent",...e})),{drawScaleValue:$}}export{h as useLeft};
1
+ import{fabric as t}from"../utils/index.js";import{defaultBorderStyle as e,defaultTextStyle as i,defaultStyle as n,drawPoint as o,drawTextGroup as l,defaultRectStyle as r}from"./useDraw.js";import{getScaleInfo as s,drawScaleNumber as u,drawScaleLine as a}from"./useScaleColumn.js";import{getType as h,isOneLine as g}from"../utils/utils.js";function c(c,p,d,f,y,w,v,m,S,Y,b,x){var T,X;const{getEqualXTypes:C,repeatTip:N}=x,{originY:V,endY:j,originX:L,endX:M,xCellWidth:k,yCellHeight:E,left:I,vitalSignsOriginY:G,painOriginY:H,painHeight:O,iconsWidth:W,itemList:A,painIndex:R,right:_,canvasWidth:B,canvasHeight:J,getRightInfo:$}=p;function q(o){var h;if(!(null==o?void 0:o.length))return;const{layout:g}=o[0];let p=W,d=L;"right"===g&&(p=M,d=M+(null!=(h=null==_?void 0:_.width)?h:0));const f=[],y=O&&"right"!==g?o.length-1:o.length,w=(d-p)/y,v=w+(d-p)%y;o.forEach(((o,h)=>{if("pain"===o.type)return void function(n){const{list:o=[],spaceGridNumber:a=5,showScale:h,showNumber:g,position:p,showMaxMinNumber:d,style:f,title:y}=n,w=l({width:L-W,height:O,...r},{value:`${y}`,...i,...f||{}},{left:W,top:H.originY}),v=[];if(h||g){const{lineXMain:i,textLeft:l}=s(p,W,L-W),r=o.length;o.forEach(((o,s)=>{let c=H.endY-s*E*a;if(0===s&&(c=j-5),!g||(0===s||s===r-1)&&!d||v.push(u(o,n,l,c)),h&&0!==s){const[n,o]=i,l=new t.Line([n,c,o,c],{...e,...f});v.push(l)}}))}c.value.add(w,...v),w.sendToBack()}(o);const d=[],y=0===h?v:w,m=0===h?p:v+p+(h-1)*w,S="right"===g?0:G.originY,Y="right"===g?J:G.endY,b=h>0?new t.Line([m,S,m,Y],{...e}):null;b&&d.push(b);const x=m+y/2,{list:T=[],spaceGridNumber:X=5,showScale:C,showNumber:N,position:V,showMaxMinNumber:M}=o;if(C||N){const{lineXMain:t,lineXSub:e,textLeft:i}=s(V,m,y),n=T.length;T.forEach(((l,r)=>{const s=G.endY-r*E*X;if(N&&(!(0===r||r===n-1)||M)){const t=0==r?s-5:s,e=u(l,o,i,t),n=G.originY+e.height/2;t<n&&e.set({top:n}),d.push(e)}d.push(...a(o,r,t,e,s,E,G.originY))}))}let k=o.title||"";o.unit&&(k+="\n"+o.unit),k&&d.push(new t.Text(String(k),{...i,left:x,top:G.originY+E*X/2,textAlign:"center",...o.style}));const I=new t.Group(d,{...n,objectCaching:!1});f.push(I)}));const m=f.length>0?new t.Group([...f],{...n,objectCaching:!1}):null;m&&c.value.add(m),m&&m.sendToBack()}function z(t){return t.left>=L&&t.left<M&&t.top>=V&&t.top<=j}W&&function(){const e=JSON.parse(JSON.stringify(A));let i=j;const l=W-I.icons.marginRight;e.reverse().forEach((e=>{i-=10;let r=e.title.replace(/(.{2})/g,"$1\n");r.endsWith("\n")&&(r=r.slice(0,r.length-1));const s=new t.Text(String(r),{...n,objectCaching:!1,...e.titleStyle||{},originX:"right",originY:"bottom",left:l-(e.pointAttr.width||10)-5,top:i,lineHeight:1,fontSize:12}),u=o(e.type,{left:l,top:i-(s.height||30)/2-1,...e.pointAttr,originY:"center",originX:"right",origin:{title:e.title,unit:e.unit,type:h(e.bigType),_type:e.bigType,dataIndex:e.dataIndex,key:e.key,isMenu:!0},originLeft:l,originTop:i-(s.height||30)/2-1,...p.event});var a;i-=s.height||30,(a=u).on("moving",(()=>{a.set("originX","center"),function(t){if(t.left>=L&&t.left<=M){t.setCoords();const e="pain"===t.origin.type?H:G;t.top<e.originY&&t.set("top",e.originY),t.top>e.endY&&t.set("top",e.endY)}}(a),z(a)?f(a):y.show=!1})),a.on("mouseup:before",(t=>{if(y.show=!1,0===t.e.button&&z(a)){const t=C(a.left,"_type",k).includes(a.origin._type),e=Y(a.left);if(!e||t)t&&e&&N();else{const t={data:{time:m(a.left),value:S(a.origin.type,a.top),...g(a.origin.type)?{key:a.origin.key}:{}},...a.origin};d("add",t),b(t)}}!function(t){t.setCoords().set({originX:"right",left:t.originLeft,top:t.originTop})}(a)})),c.value.add(s,u)}))}();const D=I.yScaleValue.filter((t=>"left"===t.layout&&"pain"!==t.type&&t.show));if((null==_?void 0:_.width)&&"left"===(null==(T=null==_?void 0:_.yScaleValue)?void 0:T.layout)&&(null==(X=null==_?void 0:_.yScaleValue)?void 0:X.show)&&D.push($),R>0&&I.yScaleValue[R].show){const t=I.yScaleValue[R];0===R&&I.yScaleValue.length>1&&D.unshift(t),R==I.yScaleValue.length-1&&D.push(t)}const F=D.findIndex((t=>"pulse"===t.type&&t.show&&t.doubleShow)),K=D[F];return F>-1&&D.splice(F,0,{...K,title:(null==K?void 0:K.doubleTitle)||(null==K?void 0:K.title)}),q(D),c.value.add(new t.Rect({left:W,top:0,width:B-W-1,height:J-1,fill:"transparent",...e})),{drawScaleValue:q}}export{c as useLeft};
@@ -0,0 +1,16 @@
1
+ import { fabric } from '../utils';
2
+ import { AnyObject } from '../../../../../es/shared/types';
3
+ /**
4
+ * @description 获取一些刻度坐标信息
5
+ * @param position {'left'|'center'|'right'} 刻度位置
6
+ * @param x {number} 绘制刻度空间矩形的left坐标值
7
+ * @param width {number} 会子刻度空间矩形的宽度值
8
+ * @return { lineXMain, lineXSub, textLeft } {主刻度线的x1、x2坐标值, 副刻度线的x1、x2坐标值, 刻度数值的left坐标值}
9
+ */
10
+ export declare function getScaleInfo(position: string | undefined, x: number, width: number): {
11
+ lineXMain: number[];
12
+ lineXSub: number[];
13
+ textLeft: number;
14
+ };
15
+ export declare function drawScaleNumber(text: string | number, item: AnyObject, left: number, top: number): fabric.Text;
16
+ export declare function drawScaleLine(item: AnyObject, i: number, lineXMain: number[], lineXSub: number[], baseTop: number, yCellHeight: number, originY: number, _listLen?: number): Array<fabric.Object | fabric.Line>;
@@ -0,0 +1 @@
1
+ import{fabric as t}from"../utils/index.js";import{defaultTextStyle as e,defaultBorderStyle as n}from"./useDraw.js";function i(t="center",e,n){let i=e+n/2,r=[i-4.5,i+4.5],o=[i-2.5,i+2.5],l=i;return"right"===t&&(i=e,r=[i,i+9],o=[i,i+5],l=r[1]),"left"===t&&(i=e+n,r=[i-9,i],o=[i-5,i],l=r[0]),{lineXMain:r,lineXSub:o,textLeft:l}}function r(n,i,r,o){const{position:l,style:s,scaleNumberStyle:c}=i;return new t.Text(String(n),{...e,originX:"left"==l?"right":"right"==l?"left":"center",left:r,top:o,...s||c||{}})}function o(e,i,r){const o=new t.Line(i,{...n,...e.style||e.scaleLineStyle||{}});r.push(o)}function l(t,e,n,i,r,l,s,c){var u;const f=[],p=c||(null==(u=t.list)?void 0:u.length),a=t.position||"center",h=(t.spaceGridNumber||(c?1:5))*l/5;if(t.showScale&&e!==p-1)for(let l=0;l<5;l++)if(l>0||!t.showNumber||"center"!==a){const c=0==l?n[0]:i[0],u=0==l?n[1]:i[1],a=r-l*h;a>s&&(o(t,[c,a,u,a],f),e==p-2&&4==l&&o(t,[n[0],a-h,n[1],a-h],f))}return f}export{l as drawScaleLine,r as drawScaleNumber,i as getScaleInfo};