pace-chart-lib 1.0.54 → 1.0.55
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/dist/pace-chart-lib.es.js +12 -11
- package/dist/pace-chart-lib.umd.js +12 -11
- package/package.json +1 -1
|
@@ -13421,7 +13421,7 @@ function commonAnnotations(chartData, xScale, yScaleLeft, yScaleRight, margin, d
|
|
|
13421
13421
|
}
|
|
13422
13422
|
});
|
|
13423
13423
|
}
|
|
13424
|
-
|
|
13424
|
+
finalAnnotationList.forEach((d) => {
|
|
13425
13425
|
if (d.data?.legendUniqueId == annotation2.data.legendUniqueId || d.legendUniqueId == annotation2.data.legendUniqueId) {
|
|
13426
13426
|
d.dx = annotation2._dx * width / d.width;
|
|
13427
13427
|
d.dy = annotation2._dy * height / d.height;
|
|
@@ -13429,7 +13429,7 @@ function commonAnnotations(chartData, xScale, yScaleLeft, yScaleRight, margin, d
|
|
|
13429
13429
|
}
|
|
13430
13430
|
});
|
|
13431
13431
|
if (onDataLabelCoordinatesChange) {
|
|
13432
|
-
const cleaned =
|
|
13432
|
+
const cleaned = finalAnnotationList.map((d) => ({
|
|
13433
13433
|
legendUniqueId: d.data?.legendUniqueId || d.legendUniqueId,
|
|
13434
13434
|
dx: d.dx,
|
|
13435
13435
|
dy: d.dy,
|
|
@@ -13937,7 +13937,7 @@ function commonAnnotationsForCustomChart(chartData, xScale, yScaleLeft, yScaleRi
|
|
|
13937
13937
|
});
|
|
13938
13938
|
}
|
|
13939
13939
|
;
|
|
13940
|
-
|
|
13940
|
+
finalAnnotationList.forEach((d) => {
|
|
13941
13941
|
if (d.data?.legendUniqueId == annotation2.data.legendUniqueId || d.legendUniqueId == annotation2.data.legendUniqueId) {
|
|
13942
13942
|
d.dx = annotation2._dx * width / d.width;
|
|
13943
13943
|
d.dy = annotation2._dy * height / d.height;
|
|
@@ -13945,7 +13945,7 @@ function commonAnnotationsForCustomChart(chartData, xScale, yScaleLeft, yScaleRi
|
|
|
13945
13945
|
}
|
|
13946
13946
|
});
|
|
13947
13947
|
if (onDataLabelCoordinatesChange) {
|
|
13948
|
-
const cleaned =
|
|
13948
|
+
const cleaned = finalAnnotationList.map((d) => ({
|
|
13949
13949
|
legendUniqueId: d.data?.legendUniqueId || d.legendUniqueId,
|
|
13950
13950
|
dx: d.dx,
|
|
13951
13951
|
dy: d.dy,
|
|
@@ -15214,6 +15214,12 @@ function stacklineAnnotations(chartData, xScale, yScaleLeft, yScaleRight, margin
|
|
|
15214
15214
|
});
|
|
15215
15215
|
break;
|
|
15216
15216
|
}
|
|
15217
|
+
if (formatOptions.annotation.annotationHideZeroValues) {
|
|
15218
|
+
labelData = labelData.filter((d) => {
|
|
15219
|
+
const value2 = d[1] < 0 && d[0] < 0 ? d[0] - d[1] : d[1] === 0 && d[0] < 0 ? d[1] + d[0] : d[1] - d[0];
|
|
15220
|
+
return value2 !== 0;
|
|
15221
|
+
});
|
|
15222
|
+
}
|
|
15217
15223
|
let maxValue = 0;
|
|
15218
15224
|
labelData.forEach((d, i) => {
|
|
15219
15225
|
if (maxValue < d.Measure) {
|
|
@@ -15271,11 +15277,6 @@ function stacklineAnnotations(chartData, xScale, yScaleLeft, yScaleRight, margin
|
|
|
15271
15277
|
// ?
|
|
15272
15278
|
annotationsList.push(singleAnnotation);
|
|
15273
15279
|
});
|
|
15274
|
-
if (formatOptions.annotation.annotationHideZeroValues) {
|
|
15275
|
-
annotationsList = annotationsList.filter(
|
|
15276
|
-
(d) => barChart ? d.data.x !== 0 : d.data.y !== 0
|
|
15277
|
-
);
|
|
15278
|
-
}
|
|
15279
15280
|
if (oldAnnotationList.length === 0) {
|
|
15280
15281
|
oldAnnotationList = annotationsList;
|
|
15281
15282
|
oldMap = new Map(
|
|
@@ -15347,7 +15348,7 @@ function stacklineAnnotations(chartData, xScale, yScaleLeft, yScaleRight, margin
|
|
|
15347
15348
|
});
|
|
15348
15349
|
}
|
|
15349
15350
|
;
|
|
15350
|
-
|
|
15351
|
+
finalAnnotationList.forEach((d) => {
|
|
15351
15352
|
if (d.data?.legendUniqueId == annotation2.data.legendUniqueId || d.legendUniqueId == annotation2.data.legendUniqueId) {
|
|
15352
15353
|
d.dx = annotation2._dx * width / d.width;
|
|
15353
15354
|
d.dy = annotation2._dy * height / d.height;
|
|
@@ -15355,7 +15356,7 @@ function stacklineAnnotations(chartData, xScale, yScaleLeft, yScaleRight, margin
|
|
|
15355
15356
|
}
|
|
15356
15357
|
});
|
|
15357
15358
|
if (onDataLabelCoordinatesChange) {
|
|
15358
|
-
const cleaned =
|
|
15359
|
+
const cleaned = finalAnnotationList.map((d) => ({
|
|
15359
15360
|
legendUniqueId: d.data?.legendUniqueId || d.legendUniqueId,
|
|
15360
15361
|
dx: d.dx,
|
|
15361
15362
|
dy: d.dy,
|
|
@@ -13424,7 +13424,7 @@
|
|
|
13424
13424
|
}
|
|
13425
13425
|
});
|
|
13426
13426
|
}
|
|
13427
|
-
|
|
13427
|
+
finalAnnotationList.forEach((d) => {
|
|
13428
13428
|
if (d.data?.legendUniqueId == annotation2.data.legendUniqueId || d.legendUniqueId == annotation2.data.legendUniqueId) {
|
|
13429
13429
|
d.dx = annotation2._dx * width / d.width;
|
|
13430
13430
|
d.dy = annotation2._dy * height / d.height;
|
|
@@ -13432,7 +13432,7 @@
|
|
|
13432
13432
|
}
|
|
13433
13433
|
});
|
|
13434
13434
|
if (onDataLabelCoordinatesChange) {
|
|
13435
|
-
const cleaned =
|
|
13435
|
+
const cleaned = finalAnnotationList.map((d) => ({
|
|
13436
13436
|
legendUniqueId: d.data?.legendUniqueId || d.legendUniqueId,
|
|
13437
13437
|
dx: d.dx,
|
|
13438
13438
|
dy: d.dy,
|
|
@@ -13940,7 +13940,7 @@
|
|
|
13940
13940
|
});
|
|
13941
13941
|
}
|
|
13942
13942
|
;
|
|
13943
|
-
|
|
13943
|
+
finalAnnotationList.forEach((d) => {
|
|
13944
13944
|
if (d.data?.legendUniqueId == annotation2.data.legendUniqueId || d.legendUniqueId == annotation2.data.legendUniqueId) {
|
|
13945
13945
|
d.dx = annotation2._dx * width / d.width;
|
|
13946
13946
|
d.dy = annotation2._dy * height / d.height;
|
|
@@ -13948,7 +13948,7 @@
|
|
|
13948
13948
|
}
|
|
13949
13949
|
});
|
|
13950
13950
|
if (onDataLabelCoordinatesChange) {
|
|
13951
|
-
const cleaned =
|
|
13951
|
+
const cleaned = finalAnnotationList.map((d) => ({
|
|
13952
13952
|
legendUniqueId: d.data?.legendUniqueId || d.legendUniqueId,
|
|
13953
13953
|
dx: d.dx,
|
|
13954
13954
|
dy: d.dy,
|
|
@@ -15217,6 +15217,12 @@
|
|
|
15217
15217
|
});
|
|
15218
15218
|
break;
|
|
15219
15219
|
}
|
|
15220
|
+
if (formatOptions.annotation.annotationHideZeroValues) {
|
|
15221
|
+
labelData = labelData.filter((d) => {
|
|
15222
|
+
const value2 = d[1] < 0 && d[0] < 0 ? d[0] - d[1] : d[1] === 0 && d[0] < 0 ? d[1] + d[0] : d[1] - d[0];
|
|
15223
|
+
return value2 !== 0;
|
|
15224
|
+
});
|
|
15225
|
+
}
|
|
15220
15226
|
let maxValue = 0;
|
|
15221
15227
|
labelData.forEach((d, i) => {
|
|
15222
15228
|
if (maxValue < d.Measure) {
|
|
@@ -15274,11 +15280,6 @@
|
|
|
15274
15280
|
// ?
|
|
15275
15281
|
annotationsList.push(singleAnnotation);
|
|
15276
15282
|
});
|
|
15277
|
-
if (formatOptions.annotation.annotationHideZeroValues) {
|
|
15278
|
-
annotationsList = annotationsList.filter(
|
|
15279
|
-
(d) => barChart ? d.data.x !== 0 : d.data.y !== 0
|
|
15280
|
-
);
|
|
15281
|
-
}
|
|
15282
15283
|
if (oldAnnotationList.length === 0) {
|
|
15283
15284
|
oldAnnotationList = annotationsList;
|
|
15284
15285
|
oldMap = new Map(
|
|
@@ -15350,7 +15351,7 @@
|
|
|
15350
15351
|
});
|
|
15351
15352
|
}
|
|
15352
15353
|
;
|
|
15353
|
-
|
|
15354
|
+
finalAnnotationList.forEach((d) => {
|
|
15354
15355
|
if (d.data?.legendUniqueId == annotation2.data.legendUniqueId || d.legendUniqueId == annotation2.data.legendUniqueId) {
|
|
15355
15356
|
d.dx = annotation2._dx * width / d.width;
|
|
15356
15357
|
d.dy = annotation2._dy * height / d.height;
|
|
@@ -15358,7 +15359,7 @@
|
|
|
15358
15359
|
}
|
|
15359
15360
|
});
|
|
15360
15361
|
if (onDataLabelCoordinatesChange) {
|
|
15361
|
-
const cleaned =
|
|
15362
|
+
const cleaned = finalAnnotationList.map((d) => ({
|
|
15362
15363
|
legendUniqueId: d.data?.legendUniqueId || d.legendUniqueId,
|
|
15363
15364
|
dx: d.dx,
|
|
15364
15365
|
dy: d.dy,
|