cnhis-design-vue 3.4.0-beta.58 → 3.4.0-beta.59
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/components/fabric-chart/src/constants/index.d.ts +0 -1
- package/es/components/fabric-chart/src/constants/index.js +0 -1
- package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogram.js +6 -5
- package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogramChart.js +13 -10
- package/es/components/field-set/src/FieldColor.vue.d.ts +1 -1
- package/es/components/field-set/src/FieldFilter.vue.d.ts +1 -1
- package/es/components/field-set/src/FieldSet.vue.d.ts +1 -1
- package/es/components/field-set/src/components/table-row.vue.d.ts +1 -1
- package/es/shared/package.json.js +1 -1
- package/package.json +2 -2
|
@@ -82,7 +82,6 @@ const OVERLAP = {
|
|
|
82
82
|
};
|
|
83
83
|
var ECG = /* @__PURE__ */ ((ECG2) => {
|
|
84
84
|
ECG2[ECG2["SMALLCELLNUMBER"] = 5] = "SMALLCELLNUMBER";
|
|
85
|
-
ECG2[ECG2["MAXLINENUMBER"] = 13] = "MAXLINENUMBER";
|
|
86
85
|
ECG2[ECG2["DEFAULTMAINXCELLVALUE"] = 0.2] = "DEFAULTMAINXCELLVALUE";
|
|
87
86
|
return ECG2;
|
|
88
87
|
})(ECG || {});
|
|
@@ -36,7 +36,8 @@ function useElectrocardiogram(canvas, propItems, flag) {
|
|
|
36
36
|
titleStyle,
|
|
37
37
|
titleOffset,
|
|
38
38
|
config,
|
|
39
|
-
calibrationLineHeight
|
|
39
|
+
calibrationLineHeight,
|
|
40
|
+
maxLineNumber
|
|
40
41
|
} = propItems;
|
|
41
42
|
const gridPoints = /* @__PURE__ */ new Set();
|
|
42
43
|
const fixedPointsCache = /* @__PURE__ */ new Set();
|
|
@@ -66,17 +67,17 @@ function useElectrocardiogram(canvas, propItems, flag) {
|
|
|
66
67
|
function drawPolyLine(startIdx = 0) {
|
|
67
68
|
const overflowIsScroll = config.overflow === "scroll";
|
|
68
69
|
dataList.forEach((lineItem, idx) => {
|
|
69
|
-
if (idx ===
|
|
70
|
+
if (idx === maxLineNumber - 1 && arguments.length && !overflowIsScroll)
|
|
70
71
|
return;
|
|
71
72
|
const { x, y, rowIdx, limitX } = lineItem.origin;
|
|
72
73
|
const lineLength = lineItem.data.length;
|
|
73
|
-
const showLength = idx <
|
|
74
|
+
const showLength = idx < maxLineNumber - 1 ? getShowLength(lineItem.data) : lineLength;
|
|
74
75
|
const points = [];
|
|
75
76
|
let pointIndex = 0;
|
|
76
77
|
for (let _idx = startIdx; _idx <= startIdx + showLength && _idx < lineLength; _idx++) {
|
|
77
78
|
const value = lineItem.data[_idx];
|
|
78
79
|
const point = { x: computedX(pointIndex + 1), y: computedY(-+value) + y };
|
|
79
|
-
if (idx <
|
|
80
|
+
if (idx < maxLineNumber - 1 && point.x > limitX) {
|
|
80
81
|
break;
|
|
81
82
|
}
|
|
82
83
|
points.push(point);
|
|
@@ -107,7 +108,7 @@ function useElectrocardiogram(canvas, propItems, flag) {
|
|
|
107
108
|
detailRadius: 370,
|
|
108
109
|
beforeEvent: () => flag.value && Promise.reject()
|
|
109
110
|
});
|
|
110
|
-
if (idx <
|
|
111
|
+
if (idx < maxLineNumber - 1 || overflowIsScroll) {
|
|
111
112
|
gridPoints.add(polyline);
|
|
112
113
|
} else {
|
|
113
114
|
fixedPointsCache.add(polyline);
|
|
@@ -33,6 +33,7 @@ function useElectrocardiogramChart(canvas, props, emits, canvasRef, pointTipProp
|
|
|
33
33
|
const list = cloneDeep(dataList);
|
|
34
34
|
const matchItem = list.find((item) => config.lastDataKey && item.key === config.lastDataKey);
|
|
35
35
|
const __dataList = matchItem ? [...list, matchItem] : list;
|
|
36
|
+
const maxLineNumber = list.length + 1;
|
|
36
37
|
const { grid } = props.data;
|
|
37
38
|
const totalLength = (_c = (_b = (_a = last(__dataList)) == null ? void 0 : _a.data) == null ? void 0 : _b.length) != null ? _c : 0;
|
|
38
39
|
const totalSeconds = totalLength / config.hz;
|
|
@@ -47,9 +48,9 @@ function useElectrocardiogramChart(canvas, props, emits, canvasRef, pointTipProp
|
|
|
47
48
|
const xCellWidth = (endX - originX) / gridXNumber;
|
|
48
49
|
const yCellHeight = (endY - originY) / gridYNumber;
|
|
49
50
|
const event = ((_e = props.data.grid) == null ? void 0 : _e.event) || { selectable: true, evented: true };
|
|
50
|
-
const
|
|
51
|
-
const
|
|
52
|
-
const rowSpace =
|
|
51
|
+
const columnNumber = +(props.data.columnNumber || 2);
|
|
52
|
+
const rowNumber = Math.ceil(list.length / columnNumber);
|
|
53
|
+
const rowSpace = ~~(gridYNumber / (rowNumber + (totalLineLength === maxLineNumber ? 1 : 0)));
|
|
53
54
|
const columnWidth = props.data.width / columnNumber;
|
|
54
55
|
const baseYCellNumber = Math.ceil(rowSpace / 2);
|
|
55
56
|
function getFirstRowLineMaxHeight() {
|
|
@@ -60,10 +61,10 @@ function useElectrocardiogramChart(canvas, props, emits, canvasRef, pointTipProp
|
|
|
60
61
|
if (columnNumber !== 2) {
|
|
61
62
|
return data1MaxHeight;
|
|
62
63
|
}
|
|
63
|
-
const
|
|
64
|
-
const
|
|
65
|
-
const
|
|
66
|
-
return Math.max(data1MaxHeight,
|
|
64
|
+
const halfIndexData = __dataList[rowNumber].data;
|
|
65
|
+
const halfIndexDataMax = Math.max(...halfIndexData);
|
|
66
|
+
const halfIndexDataMaxHeight = computedY(halfIndexDataMax);
|
|
67
|
+
return Math.max(data1MaxHeight, halfIndexDataMaxHeight);
|
|
67
68
|
function computedY(value) {
|
|
68
69
|
const currentMV = valueUnit === "uv" ? value * 1e-3 : valueUnit === "v" ? value * 1e3 : value;
|
|
69
70
|
return currentMV / mainYCellValue2 * yCellHeight;
|
|
@@ -74,8 +75,9 @@ function useElectrocardiogramChart(canvas, props, emits, canvasRef, pointTipProp
|
|
|
74
75
|
const baseY = columnNumber === 1 || _baseY < firstRowLineMaxHeight ? yCellHeight * Math.ceil(firstRowLineMaxHeight / yCellHeight) : _baseY;
|
|
75
76
|
const baseX = xCellWidth;
|
|
76
77
|
const derivedDataList = __dataList.map((item, idx) => {
|
|
77
|
-
const
|
|
78
|
-
const
|
|
78
|
+
const isLastLine = maxLineNumber === totalLineLength && idx === totalLineLength - 1;
|
|
79
|
+
const itemRowIdx = isLastLine ? rowNumber : idx % rowNumber;
|
|
80
|
+
const itemColumnIdx = isLastLine ? 0 : ~~(idx / rowNumber);
|
|
79
81
|
return {
|
|
80
82
|
...item,
|
|
81
83
|
origin: {
|
|
@@ -111,7 +113,8 @@ function useElectrocardiogramChart(canvas, props, emits, canvasRef, pointTipProp
|
|
|
111
113
|
columnNumber,
|
|
112
114
|
rowNumber,
|
|
113
115
|
config: props.data.config,
|
|
114
|
-
calibrationLineHeight
|
|
116
|
+
calibrationLineHeight,
|
|
117
|
+
maxLineNumber
|
|
115
118
|
};
|
|
116
119
|
}
|
|
117
120
|
const propItems = reactive(buildDerived());
|
|
@@ -553,9 +553,9 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
553
553
|
hide: boolean;
|
|
554
554
|
}>;
|
|
555
555
|
draggable: boolean;
|
|
556
|
-
isHighlightRow: boolean;
|
|
557
556
|
idx: number;
|
|
558
557
|
isHighlight: boolean;
|
|
558
|
+
isHighlightRow: boolean;
|
|
559
559
|
isFieldSet: boolean;
|
|
560
560
|
fieldDescribeMode: "column" | "tooltip";
|
|
561
561
|
hideExpressionOption: AnyObject[];
|
|
@@ -594,9 +594,9 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
594
594
|
hide: boolean;
|
|
595
595
|
}>;
|
|
596
596
|
draggable: boolean;
|
|
597
|
-
isHighlightRow: boolean;
|
|
598
597
|
idx: number;
|
|
599
598
|
isHighlight: boolean;
|
|
599
|
+
isHighlightRow: boolean;
|
|
600
600
|
isFieldSet: boolean;
|
|
601
601
|
fieldDescribeMode: "column" | "tooltip";
|
|
602
602
|
hideExpressionOption: AnyObject[];
|
|
@@ -773,9 +773,9 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
773
773
|
hide: boolean;
|
|
774
774
|
}>;
|
|
775
775
|
draggable: boolean;
|
|
776
|
-
isHighlightRow: boolean;
|
|
777
776
|
idx: number;
|
|
778
777
|
isHighlight: boolean;
|
|
778
|
+
isHighlightRow: boolean;
|
|
779
779
|
isFieldSet: boolean;
|
|
780
780
|
fieldDescribeMode: "column" | "tooltip";
|
|
781
781
|
hideExpressionOption: AnyObject[];
|
|
@@ -384,9 +384,9 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
384
384
|
hide: boolean;
|
|
385
385
|
}>;
|
|
386
386
|
draggable: boolean;
|
|
387
|
-
isHighlightRow: boolean;
|
|
388
387
|
idx: number;
|
|
389
388
|
isHighlight: boolean;
|
|
389
|
+
isHighlightRow: boolean;
|
|
390
390
|
isFieldSet: boolean;
|
|
391
391
|
fieldDescribeMode: "column" | "tooltip";
|
|
392
392
|
hideExpressionOption: AnyObject[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cnhis-design-vue",
|
|
3
|
-
"version": "3.4.0-beta.
|
|
3
|
+
"version": "3.4.0-beta.59",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"module": "./es/components/index.js",
|
|
6
6
|
"main": "./es/components/index.js",
|
|
@@ -73,5 +73,5 @@
|
|
|
73
73
|
"iOS 7",
|
|
74
74
|
"last 3 iOS versions"
|
|
75
75
|
],
|
|
76
|
-
"gitHead": "
|
|
76
|
+
"gitHead": "553bf943575758db3c926d8330c7de2d2d03a17c"
|
|
77
77
|
}
|