pace-chart-lib 1.0.69 → 1.0.71
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/Components/Charts/ChartJS/charts/CJSAreaChart.d.ts +19 -0
- package/dist/Components/Charts/ChartJS/charts/CJSBubbleChart.d.ts +17 -0
- package/dist/Components/Charts/ChartJS/charts/CJSColumnChart.d.ts +19 -0
- package/dist/Components/Charts/ChartJS/charts/CJSDonutChart.d.ts +19 -0
- package/dist/Components/Charts/ChartJS/charts/CJSHorizontalBarChart.d.ts +18 -0
- package/dist/Components/Charts/ChartJS/charts/CJSLineChart.d.ts +19 -0
- package/dist/Components/Charts/ChartJS/charts/CJSNormalizedStackAreaChart.d.ts +17 -0
- package/dist/Components/Charts/ChartJS/charts/CJSNormalizedStackColumnChart.d.ts +17 -0
- package/dist/Components/Charts/ChartJS/charts/CJSNormalizedStackHorizontalBarChart.d.ts +17 -0
- package/dist/Components/Charts/ChartJS/charts/CJSNormalizedStackLineChart.d.ts +17 -0
- package/dist/Components/Charts/ChartJS/charts/CJSPieChart.d.ts +23 -0
- package/dist/Components/Charts/ChartJS/charts/CJSPolarAreaChart.d.ts +19 -0
- package/dist/Components/Charts/ChartJS/charts/CJSRadarChart.d.ts +16 -0
- package/dist/Components/Charts/ChartJS/charts/CJSScatterChart.d.ts +16 -0
- package/dist/Components/Charts/ChartJS/charts/CJSStackAreaChart.d.ts +15 -0
- package/dist/Components/Charts/ChartJS/charts/CJSStackColumnChart.d.ts +15 -0
- package/dist/Components/Charts/ChartJS/charts/CJSStackHorizontalBarChart.d.ts +15 -0
- package/dist/Components/Charts/ChartJS/charts/CJSStackLineChart.d.ts +15 -0
- package/dist/Components/Charts/ChartJS/core/ChartJSDataTransformer.d.ts +31 -0
- package/dist/Components/Charts/ChartJS/core/ChartJSOptionsMapper.d.ts +9 -0
- package/dist/Components/Charts/ChartJS/core/ChartJSWrapper.d.ts +27 -0
- package/dist/Components/Charts/ChartJS/index.d.ts +21 -0
- package/dist/Components/Charts/ChartsWithAxis/AreaFamily/AreaChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/AreaFamily/NormalizedStackAreaChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/AreaFamily/StackAreaChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/ChartsWithAxisFunctions.d.ts +638 -0
- package/dist/Components/Charts/ChartsWithAxis/ChartsWithAxisTypes.types.d.ts +176 -0
- package/dist/Components/Charts/ChartsWithAxis/ColumnFamily/ColumnChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/ColumnFamily/ColumnHistogramChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/ColumnFamily/CustomColumnChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/ColumnFamily/LayeredColumnChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/ColumnFamily/NormalizedStackColumnChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/ColumnFamily/StackColumnChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/HorizontalBarFamily/HorizontalBarChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/HorizontalBarFamily/HorizontalHistogramChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/HorizontalBarFamily/LayeredHorizontalBarChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/HorizontalBarFamily/NormalizedStackHorizontalBarChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/HorizontalBarFamily/StackHorizontalBarChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/LineFamily/LineChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/LineFamily/NormalizedStackLineChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/LineFamily/StackLineChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/MiscellaneousChartFamily/DotPlot.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/MiscellaneousChartFamily/TornadoChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithAxis/MiscellaneousChartFamily/WaterfallChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/ChartsWithoutAxisFunctions.d.ts +96 -0
- package/dist/Components/Charts/ChartsWithoutAxis/ChartsWithoutAxisTypes.types.d.ts +116 -0
- package/dist/Components/Charts/ChartsWithoutAxis/Maps/Cordinates.d.ts +26 -0
- package/dist/Components/Charts/ChartsWithoutAxis/Maps/Maps.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/BubbleChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/OrganizationChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/ProgressChart.d.ts +3 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/PyramidChart.d.ts +3 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/RadialBarChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/SankeyChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/ScatterChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/Speedometer.d.ts +3 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/VennChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/OtherCharts/WordCloud.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/PieFamily/DonutChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/PieFamily/PieChart.d.ts +4 -0
- package/dist/Components/Charts/ChartsWithoutAxis/PieFamily/PieFamilyCommonFunctions.d.ts +10 -0
- package/dist/Components/Charts/ChartsWithoutAxis/PieFamily/PieofPieChart.d.ts +3 -0
- package/dist/Components/Charts/ChartsWithoutAxis/PieFamily/TreemapChart.d.ts +3 -0
- package/dist/Components/Charts/Core/Common.types.d.ts +415 -0
- package/dist/Components/Charts/Core/CommonFunctions.d.ts +251 -0
- package/dist/Components/Charts/Core/DefaultChartDataProperties.d.ts +66 -0
- package/dist/Components/Charts/Core/DefaultProperties.types.d.ts +631 -0
- package/dist/Components/Charts/Core/VfxInteraction.d.ts +25 -0
- package/dist/Services/ErrorLog.d.ts +1 -0
- package/dist/index.d.ts +37 -0
- package/dist/pace-chart-lib.es.js +74756 -0
- package/dist/pace-chart-lib.umd.js +448 -117
- package/package.json +1 -1
|
@@ -14262,38 +14262,49 @@
|
|
|
14262
14262
|
throw e;
|
|
14263
14263
|
}
|
|
14264
14264
|
};
|
|
14265
|
-
const dataTablePreCalculation = (formatOptions, yLabel, yTitle, seriesData, dimensionList) => {
|
|
14265
|
+
const dataTablePreCalculation = (formatOptions, yLabel, yTitle, seriesData, dimensionList, data) => {
|
|
14266
14266
|
try {
|
|
14267
|
+
const extraDataTableFields = data?.DataTableData ?? [];
|
|
14267
14268
|
let dataTable = [];
|
|
14268
14269
|
let dataTableHeight = 20;
|
|
14269
14270
|
if (formatOptions.dataTableProperties && formatOptions.dataTableProperties.dataTable) {
|
|
14271
|
+
const dataTableData = [...seriesData, ...extraDataTableFields];
|
|
14270
14272
|
formatOptions.xAxisLabel.xAxisLabelVisibility = false;
|
|
14271
|
-
|
|
14272
|
-
|
|
14273
|
-
|
|
14274
|
-
|
|
14275
|
-
|
|
14276
|
-
|
|
14277
|
-
|
|
14278
|
-
|
|
14279
|
-
|
|
14280
|
-
|
|
14281
|
-
|
|
14282
|
-
|
|
14283
|
-
|
|
14284
|
-
|
|
14285
|
-
|
|
14286
|
-
|
|
14287
|
-
|
|
14288
|
-
|
|
14289
|
-
|
|
14290
|
-
|
|
14291
|
-
|
|
14273
|
+
const isLegendIconVisible = formatOptions.dataTableProperties.disableLegendIcon ? false : true;
|
|
14274
|
+
const widthToSubtract = isLegendIconVisible ? 35 : 0;
|
|
14275
|
+
let exactAvailableWidth = yLabel + yTitle - widthToSubtract;
|
|
14276
|
+
dataTableData.forEach((data2, i) => {
|
|
14277
|
+
if (data2?.properties?.showInDataTable ?? true) {
|
|
14278
|
+
let tempObj = {
|
|
14279
|
+
data: data2.data.filter(
|
|
14280
|
+
(data3) => dimensionList.includes(data3.dimension)
|
|
14281
|
+
),
|
|
14282
|
+
properties: {
|
|
14283
|
+
legend: data2.properties.alias,
|
|
14284
|
+
color: data2.properties.color,
|
|
14285
|
+
markerColor: data2.properties.markerColor,
|
|
14286
|
+
markerShape: data2.properties.markerShape,
|
|
14287
|
+
lineStyle: data2.properties.lineStyle,
|
|
14288
|
+
height: calculateDataTableObjectHeight(
|
|
14289
|
+
data2.properties.alias.includes("~$~") ? data2.properties.alias.split("~$~")[1] : data2.properties.alias,
|
|
14290
|
+
exactAvailableWidth,
|
|
14291
|
+
formatOptions
|
|
14292
|
+
)
|
|
14293
|
+
}
|
|
14294
|
+
};
|
|
14295
|
+
dataTableHeight += tempObj.properties.height;
|
|
14296
|
+
dataTable.push(tempObj);
|
|
14297
|
+
}
|
|
14292
14298
|
});
|
|
14293
14299
|
} else {
|
|
14294
14300
|
dataTableHeight = 0;
|
|
14295
14301
|
dataTable = [];
|
|
14296
14302
|
}
|
|
14303
|
+
if (dataTable.length == 0) {
|
|
14304
|
+
dataTableHeight = 0;
|
|
14305
|
+
dataTable = [];
|
|
14306
|
+
formatOptions.dataTableProperties.dataTable = false;
|
|
14307
|
+
}
|
|
14297
14308
|
return { dataTable, dataTableHeight };
|
|
14298
14309
|
} catch (e) {
|
|
14299
14310
|
}
|
|
@@ -14336,7 +14347,7 @@
|
|
|
14336
14347
|
).style("text-align", "center").style("vertical-align", "middle").text("");
|
|
14337
14348
|
}
|
|
14338
14349
|
let legendsParentTag = temp.append("foreignObject").attr("x", -margin.left).attr("y", tableStartY + yCordinate).attr("width", margin.left).attr("height", cellHeight2);
|
|
14339
|
-
let innerdiv = legendsParentTag.append("xhtml:div").style("display", "flex").style("justify-content", "
|
|
14350
|
+
let innerdiv = legendsParentTag.append("xhtml:div").style("display", "flex").style("justify-content", "center").style("align-items", "center").attr("class", "parentClass").style("flex-wrap", "wrap").style("flex-direction", "row").style("pointer-events", "auto").style("width", cellWidth).style("height", `${cellHeight2}px`).style("padding-left", formatOptions.dataTableProperties.disableLegendIcon ? `2px` : `5px`).style("padding-right", `3px`).style(
|
|
14340
14351
|
"border-width",
|
|
14341
14352
|
getBorderStyle(
|
|
14342
14353
|
formatOptions,
|
|
@@ -14399,7 +14410,7 @@
|
|
|
14399
14410
|
).style("font-style", fontStyle.includes("Italic") ? "Italic" : "").style(
|
|
14400
14411
|
"text-decoration",
|
|
14401
14412
|
fontStyle.includes("Underline") ? "Underline" : ""
|
|
14402
|
-
).style("padding-left", `5px`).style("white-space", "normal").style("overflow-wrap", "break-word").style("color", "black").style("width", "100%").style("font-weight", fontStyle.includes("Bold") ? "Bold" : "").attr("title", text).text(text);
|
|
14413
|
+
).style("padding-left", `5px`).style("white-space", "normal").style("overflow-wrap", "break-word").style("color", "black").style("width", formatOptions.dataTableProperties.disableLegendIcon ? "100%" : "calc(100% - 30px)").style("font-weight", fontStyle.includes("Bold") ? "Bold" : "").attr("title", text).text(text);
|
|
14403
14414
|
};
|
|
14404
14415
|
let innerVerticalBorderLineWidth = formatOptions.dataTableInnerBorder.verticalBorderLineWidth;
|
|
14405
14416
|
let innerHorizontalBorderLineWidth = formatOptions.dataTableInnerBorder.horizontalBorderLineWidth;
|
|
@@ -16232,6 +16243,22 @@
|
|
|
16232
16243
|
tooltip: "",
|
|
16233
16244
|
tooltipMeasure: ""
|
|
16234
16245
|
};
|
|
16246
|
+
var VfxDataAttr = /* @__PURE__ */ ((VfxDataAttr2) => {
|
|
16247
|
+
VfxDataAttr2["SeriesId"] = "data-series-id";
|
|
16248
|
+
VfxDataAttr2["DimValue"] = "data-dim-value";
|
|
16249
|
+
return VfxDataAttr2;
|
|
16250
|
+
})(VfxDataAttr || {});
|
|
16251
|
+
const VFX_TOOLTIP_FONT_SIZE = "11px";
|
|
16252
|
+
const VFX_TOOLTIP_LINE_HEIGHT = "1.6";
|
|
16253
|
+
function makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, buildPayload) {
|
|
16254
|
+
return (_event, datum2) => {
|
|
16255
|
+
if (!vfxPickModeActiveRef.current || !onElementClickRef.current) return;
|
|
16256
|
+
onElementClickRef.current(buildPayload(_event, datum2));
|
|
16257
|
+
};
|
|
16258
|
+
}
|
|
16259
|
+
function resolveCustomTooltipHTML(tooltipFormatter, dimValue, seriesProperties) {
|
|
16260
|
+
return tooltipFormatter?.(dimValue, seriesProperties) ?? void 0;
|
|
16261
|
+
}
|
|
16235
16262
|
const fileName$b = "CommonFunctions.ts";
|
|
16236
16263
|
[
|
|
16237
16264
|
chartTypes.ColumnChart,
|
|
@@ -16363,7 +16390,7 @@
|
|
|
16363
16390
|
logError$2(fileName$b, "calculateMaxLegendWidth", error);
|
|
16364
16391
|
}
|
|
16365
16392
|
}
|
|
16366
|
-
function lineMarkers(lines, chartData, type, xScale, yScale, yScaleRight, tooltipHandle, formatOptions, chartJSON, secondaryCustomYaxisMaxValue, secondaryCustomYaxisMinValue, customYaxisMinValue, customYaxisMaxValue, isNormalizedChart) {
|
|
16393
|
+
function lineMarkers(lines, chartData, type, xScale, yScale, yScaleRight, tooltipHandle, formatOptions, chartJSON, secondaryCustomYaxisMaxValue, secondaryCustomYaxisMinValue, customYaxisMinValue, customYaxisMaxValue, isNormalizedChart, tooltipFormatter) {
|
|
16367
16394
|
try {
|
|
16368
16395
|
let hideZeroValues = formatOptions.plotArea.hideZeroValues;
|
|
16369
16396
|
formatOptions.plotArea.plotAreaHideLineAndMarkers === void 0 ? formatOptions.plotArea.plotAreaHideLineAndMarkers = true : null;
|
|
@@ -16400,6 +16427,10 @@
|
|
|
16400
16427
|
const dataPoint = d;
|
|
16401
16428
|
const legendEntry = d;
|
|
16402
16429
|
const parentG = select$2(this.parentNode);
|
|
16430
|
+
const _dimVal = String(chartJSON.formattedDimensionListMap.get(
|
|
16431
|
+
Array.isArray(dataPoint.dimension) ? dataPoint.dimension[0] : dataPoint.dimension
|
|
16432
|
+
) ?? "");
|
|
16433
|
+
const _customHTML = tooltipFormatter?.(_dimVal, d) ?? void 0;
|
|
16403
16434
|
showTooltipOnMouseMove(
|
|
16404
16435
|
[
|
|
16405
16436
|
{
|
|
@@ -16428,7 +16459,8 @@
|
|
|
16428
16459
|
],
|
|
16429
16460
|
formatOptions,
|
|
16430
16461
|
event2,
|
|
16431
|
-
d
|
|
16462
|
+
d,
|
|
16463
|
+
_customHTML
|
|
16432
16464
|
);
|
|
16433
16465
|
parentG.selectAll(".halo").remove();
|
|
16434
16466
|
parentG.insert("circle", ":first-child").attr("class", "halo").attr("cx", xScale(dataPoint.dimension)).attr("cy", () => {
|
|
@@ -16719,7 +16751,7 @@
|
|
|
16719
16751
|
if (abs2 >= 1e3) return (value2 / 1e3).toFixed(2) + "K";
|
|
16720
16752
|
return value2.toFixed(2);
|
|
16721
16753
|
}
|
|
16722
|
-
function showTooltipOnMouseMove(elements, chartFormatOptions, event2, prop) {
|
|
16754
|
+
function showTooltipOnMouseMove(elements, chartFormatOptions, event2, prop, customHTML) {
|
|
16723
16755
|
try {
|
|
16724
16756
|
const markerColor = prop?.color ?? prop?.markerColor ?? "blue";
|
|
16725
16757
|
const markerShape = prop?.markerShape?.toLowerCase() ?? "circle";
|
|
@@ -16819,12 +16851,9 @@
|
|
|
16819
16851
|
`;
|
|
16820
16852
|
return p;
|
|
16821
16853
|
}, ``);
|
|
16822
|
-
tooltip.html(
|
|
16823
|
-
|
|
16824
|
-
|
|
16825
|
-
${tooltipElements}
|
|
16826
|
-
</div>
|
|
16827
|
-
`);
|
|
16854
|
+
tooltip.html(
|
|
16855
|
+
customHTML ? `<div class="tooltipInner" style="display:flex; flex-direction:column; font-size:${VFX_TOOLTIP_FONT_SIZE}; color:${textColor}; line-height:${VFX_TOOLTIP_LINE_HEIGHT};">${customHTML}</div>` : `<div class="arrow-placeholder"></div><div class="tooltipInner" style="display:flex; flex-direction:column;">${tooltipElements}</div>`
|
|
16856
|
+
);
|
|
16828
16857
|
const tooltipNode = tooltip.node();
|
|
16829
16858
|
const tooltipWidth = tooltipNode.offsetWidth;
|
|
16830
16859
|
const tooltipHeight = tooltipNode.offsetHeight;
|
|
@@ -17486,13 +17515,22 @@
|
|
|
17486
17515
|
data,
|
|
17487
17516
|
isReportEditable,
|
|
17488
17517
|
onDataLabelCoordinatesChange,
|
|
17489
|
-
addLocalFilterFromLib
|
|
17518
|
+
addLocalFilterFromLib,
|
|
17519
|
+
tooltipFormatter,
|
|
17520
|
+
onElementClick,
|
|
17521
|
+
vfxPickModeActive
|
|
17490
17522
|
}) => {
|
|
17491
17523
|
const chartId = crypto.randomUUID();
|
|
17492
17524
|
let columnWidth = 0;
|
|
17493
17525
|
let scrollbarVisible = false;
|
|
17494
17526
|
const chartType = chartTypes.ColumnChart;
|
|
17495
17527
|
const svgRef = require$$0$1.useRef();
|
|
17528
|
+
const tooltipFormatterRef = require$$0$1.useRef(tooltipFormatter);
|
|
17529
|
+
tooltipFormatterRef.current = tooltipFormatter;
|
|
17530
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
17531
|
+
onElementClickRef.current = onElementClick;
|
|
17532
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
17533
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
17496
17534
|
const seriesData = generalizedChartData(
|
|
17497
17535
|
data.ChartData,
|
|
17498
17536
|
data.DimensionList
|
|
@@ -17615,7 +17653,8 @@
|
|
|
17615
17653
|
yLabel,
|
|
17616
17654
|
yTitle,
|
|
17617
17655
|
seriesData,
|
|
17618
|
-
chartJSON.dimensionList
|
|
17656
|
+
chartJSON.dimensionList,
|
|
17657
|
+
data
|
|
17619
17658
|
));
|
|
17620
17659
|
initSvg$1(
|
|
17621
17660
|
// for svg creation
|
|
@@ -17913,7 +17952,7 @@
|
|
|
17913
17952
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr(
|
|
17914
17953
|
"visibility",
|
|
17915
17954
|
(d) => d.value === 0 && formatOptions.xAxisLabel.hideZeroValues ? "hidden" : "visible"
|
|
17916
|
-
);
|
|
17955
|
+
).attr(VfxDataAttr.SeriesId, () => data2.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension));
|
|
17917
17956
|
const finalBars = formatOptions.animation.animationEnabled ? bars.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : bars;
|
|
17918
17957
|
finalBars.attr("y", (d) => {
|
|
17919
17958
|
const yScale = data2.properties.axis === axisTypes.primary ? yScaleLeft : yScaleRight;
|
|
@@ -17924,13 +17963,17 @@
|
|
|
17924
17963
|
});
|
|
17925
17964
|
columnGroupsEnter.merge(columnGroups).on("mousemove", (event2, d) => {
|
|
17926
17965
|
(data2.properties.alias || data2.properties.name || "Legend").replace(/ /g, "-");
|
|
17966
|
+
const _dimVal = String(
|
|
17967
|
+
chartJSON.formattedDimensionListMap.get(
|
|
17968
|
+
Array.isArray(d.dimension) ? d.dimension[0] : d.dimension
|
|
17969
|
+
) ?? ""
|
|
17970
|
+
);
|
|
17971
|
+
const _customHTML = resolveCustomTooltipHTML(tooltipFormatterRef.current, _dimVal, data2.properties);
|
|
17927
17972
|
showTooltipOnMouseMove(
|
|
17928
17973
|
[
|
|
17929
17974
|
{
|
|
17930
17975
|
key: formatOptions.xAxisTitle.xAxisTitleHTML !== "" ? new DOMParser().parseFromString(formatOptions.xAxisTitle.xAxisTitleHTML, "text/html").body.textContent?.trim() : formatOptions.xAxisTitle.xAxisTitleText.includes("~$~") ? formatOptions.xAxisTitle.xAxisTitleText.split("~$~")[1] : formatOptions.xAxisTitle.xAxisTitleText,
|
|
17931
|
-
value:
|
|
17932
|
-
Array.isArray(d.dimension) ? d.dimension[0] : d.dimension
|
|
17933
|
-
)
|
|
17976
|
+
value: _dimVal
|
|
17934
17977
|
},
|
|
17935
17978
|
{
|
|
17936
17979
|
key: formatOptions.yAxisTitle.yAxisTitleHTML !== "" ? new DOMParser().parseFromString(formatOptions.yAxisTitle.yAxisTitleHTML, "text/html").body.textContent?.trim() : d.properties?.currentMeasure ? d.properties.currentMeasure : formatOptions.yAxisTitle.yAxisTitleText || d.value,
|
|
@@ -17952,12 +17995,19 @@
|
|
|
17952
17995
|
],
|
|
17953
17996
|
formatOptions,
|
|
17954
17997
|
event2,
|
|
17955
|
-
data2.properties
|
|
17998
|
+
data2.properties,
|
|
17999
|
+
_customHTML
|
|
17956
18000
|
);
|
|
17957
18001
|
}).on("mouseout", (event2, d) => {
|
|
17958
18002
|
(data2.properties.alias || data2.properties.name || "Legend").replace(/ /g, "-");
|
|
17959
18003
|
hideTooltipOnMouseOut();
|
|
17960
18004
|
});
|
|
18005
|
+
columnGroupsEnter.merge(columnGroups).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
18006
|
+
seriesId: data2.properties.legendUniqueId,
|
|
18007
|
+
dimValue: Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension),
|
|
18008
|
+
legendUniqueId: data2.properties.legendUniqueId,
|
|
18009
|
+
seriesDisplayName: data2.properties.alias || data2.properties.name || ""
|
|
18010
|
+
})));
|
|
17961
18011
|
columnGroups.exit().remove();
|
|
17962
18012
|
});
|
|
17963
18013
|
gTag.selectAll(".parentGroup").raise();
|
|
@@ -18061,7 +18111,9 @@
|
|
|
18061
18111
|
data,
|
|
18062
18112
|
isReportEditable,
|
|
18063
18113
|
onDataLabelCoordinatesChange,
|
|
18064
|
-
addLocalFilterFromLib
|
|
18114
|
+
addLocalFilterFromLib,
|
|
18115
|
+
onElementClick,
|
|
18116
|
+
vfxPickModeActive
|
|
18065
18117
|
}) => {
|
|
18066
18118
|
const chartId = crypto.randomUUID();
|
|
18067
18119
|
let columnWidth = 0;
|
|
@@ -18069,6 +18121,10 @@
|
|
|
18069
18121
|
let stackChartData = [];
|
|
18070
18122
|
const chartType = chartTypes.CustomColumnChart;
|
|
18071
18123
|
const svgRef = require$$0$1.useRef();
|
|
18124
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
18125
|
+
onElementClickRef.current = onElementClick;
|
|
18126
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
18127
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
18072
18128
|
const seriesData = generalizedChartData(
|
|
18073
18129
|
data.ChartData,
|
|
18074
18130
|
data.DimensionList
|
|
@@ -18201,7 +18257,8 @@
|
|
|
18201
18257
|
yLabel,
|
|
18202
18258
|
yTitle,
|
|
18203
18259
|
seriesData,
|
|
18204
|
-
chartJSON.dimensionList
|
|
18260
|
+
chartJSON.dimensionList,
|
|
18261
|
+
data
|
|
18205
18262
|
));
|
|
18206
18263
|
initSvg$1(
|
|
18207
18264
|
// for svg creation
|
|
@@ -18642,7 +18699,7 @@
|
|
|
18642
18699
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr(
|
|
18643
18700
|
"visibility",
|
|
18644
18701
|
(d) => d.value === 0 && formatOptions.xAxisLabel.hideZeroValues ? "hidden" : "visible"
|
|
18645
|
-
).on("mousemove", (event2, d) => {
|
|
18702
|
+
).attr(VfxDataAttr.SeriesId, () => data2.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension)).on("mousemove", (event2, d) => {
|
|
18646
18703
|
showTooltipOnMouseMove(
|
|
18647
18704
|
[
|
|
18648
18705
|
{
|
|
@@ -18673,7 +18730,12 @@
|
|
|
18673
18730
|
event2,
|
|
18674
18731
|
seriesData.filter((e) => e.legend === d.legend)[0].properties
|
|
18675
18732
|
);
|
|
18676
|
-
}).on("mouseout", hideTooltipOnMouseOut)
|
|
18733
|
+
}).on("mouseout", hideTooltipOnMouseOut).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
18734
|
+
seriesId: data2.properties.legendUniqueId,
|
|
18735
|
+
dimValue: Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension),
|
|
18736
|
+
legendUniqueId: data2.properties.legendUniqueId,
|
|
18737
|
+
seriesDisplayName: data2.properties.alias || data2.properties.name || ""
|
|
18738
|
+
})));
|
|
18677
18739
|
const finalBars = formatOptions.animation.animationEnabled ? bars.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : bars;
|
|
18678
18740
|
finalBars.attr("y", (d) => {
|
|
18679
18741
|
const yScale = data2.properties.axis === axisTypes.primary ? yScaleLeft : yScaleRight;
|
|
@@ -18978,7 +19040,12 @@
|
|
|
18978
19040
|
event2,
|
|
18979
19041
|
seriesData.filter((e) => e.legend === d.key)[0].properties
|
|
18980
19042
|
);
|
|
18981
|
-
}).on("mouseout", hideTooltipOnMouseOut)
|
|
19043
|
+
}).on("mouseout", hideTooltipOnMouseOut).attr(VfxDataAttr.SeriesId, (d) => d.key ?? "").attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension)).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
19044
|
+
seriesId: d.key ?? "",
|
|
19045
|
+
dimValue: Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension),
|
|
19046
|
+
legendUniqueId: d.key ?? "",
|
|
19047
|
+
seriesDisplayName: d.alias || d.key || ""
|
|
19048
|
+
})));
|
|
18982
19049
|
const finalStackRects = formatOptions.animation.animationEnabled ? rectsEnter.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : rectsEnter;
|
|
18983
19050
|
finalStackRects.attr(
|
|
18984
19051
|
"y",
|
|
@@ -19197,12 +19264,18 @@
|
|
|
19197
19264
|
data,
|
|
19198
19265
|
isReportEditable,
|
|
19199
19266
|
onDataLabelCoordinatesChange,
|
|
19200
|
-
addLocalFilterFromLib
|
|
19267
|
+
addLocalFilterFromLib,
|
|
19268
|
+
onElementClick,
|
|
19269
|
+
vfxPickModeActive
|
|
19201
19270
|
}) => {
|
|
19202
19271
|
const chartId = crypto.randomUUID();
|
|
19203
19272
|
let columnWidth = 0;
|
|
19204
19273
|
const chartType = chartTypes.LayeredColumnChart;
|
|
19205
19274
|
const svgRef = require$$0$1.useRef();
|
|
19275
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
19276
|
+
onElementClickRef.current = onElementClick;
|
|
19277
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
19278
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
19206
19279
|
const seriesData = generalizedChartData(
|
|
19207
19280
|
data.ChartData,
|
|
19208
19281
|
data.DimensionList
|
|
@@ -19324,7 +19397,8 @@
|
|
|
19324
19397
|
yLabel,
|
|
19325
19398
|
yTitle,
|
|
19326
19399
|
seriesData,
|
|
19327
|
-
chartJSON.dimensionList
|
|
19400
|
+
chartJSON.dimensionList,
|
|
19401
|
+
data
|
|
19328
19402
|
));
|
|
19329
19403
|
initSvg$1(
|
|
19330
19404
|
// for svg creation
|
|
@@ -19591,7 +19665,7 @@
|
|
|
19591
19665
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr("opacity", 0.7).attr(
|
|
19592
19666
|
"visibility",
|
|
19593
19667
|
(d) => d.value === 0 && formatOptions.xAxisLabel.hideZeroValues ? "hidden" : "visible"
|
|
19594
|
-
);
|
|
19668
|
+
).attr(VfxDataAttr.SeriesId, () => data2.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension));
|
|
19595
19669
|
const finalBars = formatOptions.animation.animationEnabled ? bars.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : bars;
|
|
19596
19670
|
finalBars.attr("y", (d) => {
|
|
19597
19671
|
const yScale = data2.properties.axis === axisTypes.primary ? yScaleLeft : yScaleRight;
|
|
@@ -19647,6 +19721,12 @@
|
|
|
19647
19721
|
selectAll('[hoverId="' + legend + '"]').classed("highlight", false).classed("unhighlight", false);
|
|
19648
19722
|
hideTooltipOnMouseOut();
|
|
19649
19723
|
});
|
|
19724
|
+
columnGroupsEnter.merge(columnGroups).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
19725
|
+
seriesId: data2.properties.legendUniqueId,
|
|
19726
|
+
dimValue: Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension),
|
|
19727
|
+
legendUniqueId: data2.properties.legendUniqueId,
|
|
19728
|
+
seriesDisplayName: data2.properties.alias || data2.properties.name || ""
|
|
19729
|
+
})));
|
|
19650
19730
|
columnGroups.exit().remove();
|
|
19651
19731
|
});
|
|
19652
19732
|
gTag.selectAll(".parentGroup").raise();
|
|
@@ -19754,13 +19834,20 @@
|
|
|
19754
19834
|
data,
|
|
19755
19835
|
isReportEditable,
|
|
19756
19836
|
onDataLabelCoordinatesChange,
|
|
19757
|
-
addLocalFilterFromLib
|
|
19837
|
+
addLocalFilterFromLib,
|
|
19838
|
+
tooltipFormatter,
|
|
19839
|
+
onElementClick,
|
|
19840
|
+
vfxPickModeActive
|
|
19758
19841
|
}) => {
|
|
19759
19842
|
const chartId = crypto.randomUUID();
|
|
19760
19843
|
let columnWidth = 0;
|
|
19761
19844
|
let scrollbarVisible = false;
|
|
19762
19845
|
const chartType = chartTypes.StackColumnChart;
|
|
19763
19846
|
const svgRef = require$$0$1.useRef();
|
|
19847
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
19848
|
+
onElementClickRef.current = onElementClick;
|
|
19849
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
19850
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
19764
19851
|
const dimensionList = data.DimensionList;
|
|
19765
19852
|
const seriesData = (generalizedChartData(data.ChartData, data.DimensionList) || []).reverse();
|
|
19766
19853
|
const barChart = false;
|
|
@@ -19880,7 +19967,8 @@
|
|
|
19880
19967
|
yLabel,
|
|
19881
19968
|
yTitle,
|
|
19882
19969
|
seriesData,
|
|
19883
|
-
chartJSON.dimensionList
|
|
19970
|
+
chartJSON.dimensionList,
|
|
19971
|
+
data
|
|
19884
19972
|
));
|
|
19885
19973
|
initSvg$1(
|
|
19886
19974
|
// for svg creation
|
|
@@ -20117,7 +20205,9 @@
|
|
|
20117
20205
|
}).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr("visibility", (d, i, nodes) => {
|
|
20118
20206
|
const { props } = getPropsForRect(nodes, i);
|
|
20119
20207
|
return d.data[d.key] == 0 && props?.hideZeroValues ? "hidden" : "visible";
|
|
20120
|
-
}).on("mousemove", (event2, d) => {
|
|
20208
|
+
}).attr(VfxDataAttr.SeriesId, (d) => d.key ?? "").attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension)).on("mousemove", (event2, d) => {
|
|
20209
|
+
const _dimVal = String(chartJSON.formattedDimensionListMap.get(d.data.dimension) ?? "");
|
|
20210
|
+
const _customHTML = resolveCustomTooltipHTML(tooltipFormatter, _dimVal, d.properties);
|
|
20121
20211
|
showTooltipOnMouseMove(
|
|
20122
20212
|
[
|
|
20123
20213
|
{
|
|
@@ -20140,11 +20230,17 @@
|
|
|
20140
20230
|
],
|
|
20141
20231
|
formatOptions,
|
|
20142
20232
|
event2,
|
|
20143
|
-
d.properties
|
|
20233
|
+
d.properties,
|
|
20234
|
+
_customHTML
|
|
20144
20235
|
);
|
|
20145
20236
|
}).on("mouseout", (event2, d) => {
|
|
20146
20237
|
hideTooltipOnMouseOut();
|
|
20147
|
-
})
|
|
20238
|
+
}).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
20239
|
+
seriesId: d.key ?? "",
|
|
20240
|
+
dimValue: Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension),
|
|
20241
|
+
legendUniqueId: d.key ?? "",
|
|
20242
|
+
seriesDisplayName: d.properties?.alias || d.key || ""
|
|
20243
|
+
})));
|
|
20148
20244
|
const finalRects = formatOptions.animation.animationEnabled ? baseRects.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : baseRects;
|
|
20149
20245
|
finalRects.attr("y", (d) => d[1] >= d[0] ? yScaleLeft(d[1]) : yScaleLeft(d[0])).attr("height", (d) => Math.abs(yScaleLeft(d[0]) - yScaleLeft(d[1])));
|
|
20150
20246
|
columnGroups.exit().remove();
|
|
@@ -20493,12 +20589,18 @@
|
|
|
20493
20589
|
data,
|
|
20494
20590
|
isReportEditable,
|
|
20495
20591
|
onDataLabelCoordinatesChange,
|
|
20496
|
-
addLocalFilterFromLib
|
|
20592
|
+
addLocalFilterFromLib,
|
|
20593
|
+
onElementClick,
|
|
20594
|
+
vfxPickModeActive
|
|
20497
20595
|
}) => {
|
|
20498
20596
|
const chartId = crypto.randomUUID();
|
|
20499
20597
|
let columnWidth = 0;
|
|
20500
20598
|
const chartType = chartTypes.NormalizedStackColumnChart;
|
|
20501
20599
|
const svgRef = require$$0$1.useRef();
|
|
20600
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
20601
|
+
onElementClickRef.current = onElementClick;
|
|
20602
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
20603
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
20502
20604
|
const seriesData = generalizedChartData(
|
|
20503
20605
|
data.ChartData,
|
|
20504
20606
|
data.DimensionList
|
|
@@ -20619,7 +20721,8 @@
|
|
|
20619
20721
|
yLabel,
|
|
20620
20722
|
yTitle,
|
|
20621
20723
|
seriesData,
|
|
20622
|
-
chartJSON.dimensionList
|
|
20724
|
+
chartJSON.dimensionList,
|
|
20725
|
+
data
|
|
20623
20726
|
));
|
|
20624
20727
|
initSvg$1(
|
|
20625
20728
|
// for svg creation
|
|
@@ -20883,7 +20986,7 @@
|
|
|
20883
20986
|
}).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr("visibility", (d, i, nodes) => {
|
|
20884
20987
|
const { props } = getPropsForRect(nodes, i);
|
|
20885
20988
|
return d.data[d.key] === 0 && props?.hideZeroValues ? "hidden" : "visible";
|
|
20886
|
-
});
|
|
20989
|
+
}).attr(VfxDataAttr.SeriesId, (d) => d.key ?? "").attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension));
|
|
20887
20990
|
const shouldAnimate = formatOptions.animation.animationEnabled;
|
|
20888
20991
|
const applyTransition = (sel) => shouldAnimate ? sel.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : sel;
|
|
20889
20992
|
applyTransition(rectsEnter).attr("y", (d) => d[1] >= d[0] ? yScaleLeft(d[1]) : yScaleLeft(d[0])).attr("height", (d) => Math.abs(yScaleLeft(d[0]) - yScaleLeft(d[1])));
|
|
@@ -20914,7 +21017,12 @@
|
|
|
20914
21017
|
);
|
|
20915
21018
|
}).on("mouseout", (event2, d) => {
|
|
20916
21019
|
hideTooltipOnMouseOut();
|
|
20917
|
-
})
|
|
21020
|
+
}).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
21021
|
+
seriesId: d.key ?? "",
|
|
21022
|
+
dimValue: Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension),
|
|
21023
|
+
legendUniqueId: d.key ?? "",
|
|
21024
|
+
seriesDisplayName: d.properties?.alias || d.key || ""
|
|
21025
|
+
})));
|
|
20918
21026
|
columnGroups.exit().remove();
|
|
20919
21027
|
gTag.selectAll(".parentGroup").raise();
|
|
20920
21028
|
};
|
|
@@ -22333,12 +22441,19 @@
|
|
|
22333
22441
|
data,
|
|
22334
22442
|
isReportEditable,
|
|
22335
22443
|
onDataLabelCoordinatesChange,
|
|
22336
|
-
addLocalFilterFromLib
|
|
22444
|
+
addLocalFilterFromLib,
|
|
22445
|
+
tooltipFormatter,
|
|
22446
|
+
onElementClick,
|
|
22447
|
+
vfxPickModeActive
|
|
22337
22448
|
}) => {
|
|
22338
22449
|
const chartId = crypto.randomUUID();
|
|
22339
22450
|
const barWidth = 0;
|
|
22340
22451
|
const chartType = chartTypes.LineChart;
|
|
22341
22452
|
const svgRef = require$$0$1.useRef();
|
|
22453
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
22454
|
+
onElementClickRef.current = onElementClick;
|
|
22455
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
22456
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
22342
22457
|
const seriesData = generalizedChartData(
|
|
22343
22458
|
data.ChartData,
|
|
22344
22459
|
data.DimensionList
|
|
@@ -22462,7 +22577,8 @@
|
|
|
22462
22577
|
yLabel,
|
|
22463
22578
|
yTitle,
|
|
22464
22579
|
seriesData,
|
|
22465
|
-
chartJSON.dimensionList
|
|
22580
|
+
chartJSON.dimensionList,
|
|
22581
|
+
data
|
|
22466
22582
|
));
|
|
22467
22583
|
initSvg$1(
|
|
22468
22584
|
// for svg creation
|
|
@@ -22773,7 +22889,12 @@
|
|
|
22773
22889
|
).attr(
|
|
22774
22890
|
"hoverId",
|
|
22775
22891
|
(d.properties.alias || d.properties.name || "Legend").replace(/\s+/g, "-")
|
|
22776
|
-
).attr("clip-path", `url(#${chartId}-clip)`).attr("d", (d2) => lineGenerator(d2.data))
|
|
22892
|
+
).attr("clip-path", `url(#${chartId}-clip)`).attr("d", (d2) => lineGenerator(d2.data)).attr(VfxDataAttr.SeriesId, (d2) => d2.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d2) => d2.properties.alias || d2.properties.name || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d2) => ({
|
|
22893
|
+
seriesId: d2.properties.legendUniqueId,
|
|
22894
|
+
dimValue: d2.properties.alias || d2.properties.name || "",
|
|
22895
|
+
legendUniqueId: d2.properties.legendUniqueId,
|
|
22896
|
+
seriesDisplayName: d2.properties.alias || d2.properties.name || ""
|
|
22897
|
+
})));
|
|
22777
22898
|
if (shouldAnimate) {
|
|
22778
22899
|
pathSel.each(function() {
|
|
22779
22900
|
const path2 = select$2(this);
|
|
@@ -22797,7 +22918,9 @@
|
|
|
22797
22918
|
secondaryCustomYaxisMaxValue,
|
|
22798
22919
|
secondaryCustomYaxisMinValue,
|
|
22799
22920
|
customYaxisMinValue,
|
|
22800
|
-
customYaxisMaxValue
|
|
22921
|
+
customYaxisMaxValue,
|
|
22922
|
+
false,
|
|
22923
|
+
tooltipFormatter
|
|
22801
22924
|
);
|
|
22802
22925
|
gTag.selectAll(".parentGroup").raise();
|
|
22803
22926
|
};
|
|
@@ -22909,12 +23032,18 @@
|
|
|
22909
23032
|
data,
|
|
22910
23033
|
isReportEditable,
|
|
22911
23034
|
onDataLabelCoordinatesChange,
|
|
22912
|
-
addLocalFilterFromLib
|
|
23035
|
+
addLocalFilterFromLib,
|
|
23036
|
+
onElementClick,
|
|
23037
|
+
vfxPickModeActive
|
|
22913
23038
|
}) => {
|
|
22914
23039
|
const chartId = crypto.randomUUID();
|
|
22915
23040
|
const barWidth = 0;
|
|
22916
23041
|
const chartType = chartTypes.StackLineChart;
|
|
22917
23042
|
const svgRef = require$$0$1.useRef();
|
|
23043
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
23044
|
+
onElementClickRef.current = onElementClick;
|
|
23045
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
23046
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
22918
23047
|
const dimensionList = data.DimensionList;
|
|
22919
23048
|
const seriesData = (generalizedChartData(data.ChartData, data.DimensionList) || []).reverse();
|
|
22920
23049
|
const barChart = false;
|
|
@@ -23036,7 +23165,8 @@
|
|
|
23036
23165
|
yLabel,
|
|
23037
23166
|
yTitle,
|
|
23038
23167
|
seriesData,
|
|
23039
|
-
chartJSON.dimensionList
|
|
23168
|
+
chartJSON.dimensionList,
|
|
23169
|
+
data
|
|
23040
23170
|
));
|
|
23041
23171
|
initSvg$1(
|
|
23042
23172
|
// for svg creation
|
|
@@ -23314,7 +23444,12 @@
|
|
|
23314
23444
|
).attr(
|
|
23315
23445
|
"stroke-width",
|
|
23316
23446
|
seriesData[i].properties.lineStyle !== staticLineStyle.none ? seriesData[i].properties.lineWidth : 0
|
|
23317
|
-
).attr("fill", "none")
|
|
23447
|
+
).attr("fill", "none").attr(VfxDataAttr.SeriesId, seriesData[i].properties.legendUniqueId).attr(VfxDataAttr.DimValue, seriesData[i].properties.alias || seriesData[i].properties.name || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, () => ({
|
|
23448
|
+
seriesId: seriesData[i].properties.legendUniqueId,
|
|
23449
|
+
dimValue: seriesData[i].properties.alias || seriesData[i].properties.name || "",
|
|
23450
|
+
legendUniqueId: seriesData[i].properties.legendUniqueId,
|
|
23451
|
+
seriesDisplayName: seriesData[i].properties.alias || seriesData[i].properties.name || ""
|
|
23452
|
+
})));
|
|
23318
23453
|
const enableTransition = formatOptions.animation.animationEnabled;
|
|
23319
23454
|
const totalLength = pathSel.node().getTotalLength();
|
|
23320
23455
|
if (enableTransition) {
|
|
@@ -23497,12 +23632,18 @@
|
|
|
23497
23632
|
data,
|
|
23498
23633
|
isReportEditable,
|
|
23499
23634
|
onDataLabelCoordinatesChange,
|
|
23500
|
-
addLocalFilterFromLib
|
|
23635
|
+
addLocalFilterFromLib,
|
|
23636
|
+
onElementClick,
|
|
23637
|
+
vfxPickModeActive
|
|
23501
23638
|
}) => {
|
|
23502
23639
|
const chartId = crypto.randomUUID();
|
|
23503
23640
|
const barWidth = 0;
|
|
23504
23641
|
const chartType = chartTypes.NormalizedStackLineChart;
|
|
23505
23642
|
const svgRef = require$$0$1.useRef();
|
|
23643
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
23644
|
+
onElementClickRef.current = onElementClick;
|
|
23645
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
23646
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
23506
23647
|
const seriesData = generalizedChartData(data.ChartData, data.DimensionList)?.reverse() || [];
|
|
23507
23648
|
const dimensionList = data.DimensionList;
|
|
23508
23649
|
const barChart = false;
|
|
@@ -23615,7 +23756,8 @@
|
|
|
23615
23756
|
yLabel,
|
|
23616
23757
|
yTitle,
|
|
23617
23758
|
seriesData,
|
|
23618
|
-
chartJSON.dimensionList
|
|
23759
|
+
chartJSON.dimensionList,
|
|
23760
|
+
data
|
|
23619
23761
|
));
|
|
23620
23762
|
initSvg$1(
|
|
23621
23763
|
// for svg creation
|
|
@@ -23846,7 +23988,12 @@
|
|
|
23846
23988
|
).attr(
|
|
23847
23989
|
"stroke-width",
|
|
23848
23990
|
seriesData[i].properties.lineStyle !== staticLineStyle.none ? seriesData[i].properties.lineWidth : 0
|
|
23849
|
-
).attr("fill", "none")
|
|
23991
|
+
).attr("fill", "none").attr(VfxDataAttr.SeriesId, seriesData[i].properties.legendUniqueId).attr(VfxDataAttr.DimValue, seriesData[i].properties.alias || seriesData[i].properties.name || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, () => ({
|
|
23992
|
+
seriesId: seriesData[i].properties.legendUniqueId,
|
|
23993
|
+
dimValue: seriesData[i].properties.alias || seriesData[i].properties.name || "",
|
|
23994
|
+
legendUniqueId: seriesData[i].properties.legendUniqueId,
|
|
23995
|
+
seriesDisplayName: seriesData[i].properties.alias || seriesData[i].properties.name || ""
|
|
23996
|
+
})));
|
|
23850
23997
|
const enableTransition = formatOptions.animation.animationEnabled;
|
|
23851
23998
|
const totalLength = pathSel.node().getTotalLength();
|
|
23852
23999
|
if (enableTransition) {
|
|
@@ -24028,12 +24175,19 @@
|
|
|
24028
24175
|
data,
|
|
24029
24176
|
isReportEditable,
|
|
24030
24177
|
onDataLabelCoordinatesChange,
|
|
24031
|
-
addLocalFilterFromLib
|
|
24178
|
+
addLocalFilterFromLib,
|
|
24179
|
+
tooltipFormatter,
|
|
24180
|
+
onElementClick,
|
|
24181
|
+
vfxPickModeActive
|
|
24032
24182
|
}) => {
|
|
24033
24183
|
const chartId = crypto.randomUUID();
|
|
24034
24184
|
let columnWidth = 0;
|
|
24035
24185
|
const chartType = chartTypes.HorizontalBarChart;
|
|
24036
24186
|
const svgRef = require$$0$1.useRef();
|
|
24187
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
24188
|
+
onElementClickRef.current = onElementClick;
|
|
24189
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
24190
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
24037
24191
|
const seriesData = generalizedChartData(
|
|
24038
24192
|
data.ChartData,
|
|
24039
24193
|
data.DimensionList
|
|
@@ -24445,7 +24599,7 @@
|
|
|
24445
24599
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr(
|
|
24446
24600
|
"visibility",
|
|
24447
24601
|
(d) => d.value === 0 && formatOptions.xAxisLabel.hideZeroValues ? "hidden" : "visible"
|
|
24448
|
-
);
|
|
24602
|
+
).attr(VfxDataAttr.SeriesId, () => data2.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension));
|
|
24449
24603
|
const finalBars = formatOptions.animation.animationEnabled ? bars.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : bars;
|
|
24450
24604
|
finalBars.attr("x", (d) => {
|
|
24451
24605
|
const xScaleUsed = data2.properties.axis === axisTypes.primary ? xScaleBottom : xScaleTop;
|
|
@@ -24461,6 +24615,10 @@
|
|
|
24461
24615
|
});
|
|
24462
24616
|
columnGroupsEnter.merge(columnGroups).on("mousemove", (event2, d) => {
|
|
24463
24617
|
(data2.properties.alias || data2.properties.name || "Legend").replace(/ /g, "-");
|
|
24618
|
+
const _dimVal = String(chartJSON.formattedDimensionListMap.get(
|
|
24619
|
+
Array.isArray(d.dimension) ? d.dimension[0] : d.dimension
|
|
24620
|
+
) ?? "");
|
|
24621
|
+
const _customHTML = resolveCustomTooltipHTML(tooltipFormatter, _dimVal, data2.properties);
|
|
24464
24622
|
showTooltipOnMouseMove(
|
|
24465
24623
|
[
|
|
24466
24624
|
{
|
|
@@ -24489,12 +24647,18 @@
|
|
|
24489
24647
|
],
|
|
24490
24648
|
formatOptions,
|
|
24491
24649
|
event2,
|
|
24492
|
-
data2.properties
|
|
24650
|
+
data2.properties,
|
|
24651
|
+
_customHTML
|
|
24493
24652
|
);
|
|
24494
24653
|
}).on("mouseout", (event2, d) => {
|
|
24495
24654
|
(data2.properties.alias || data2.properties.name || "Legend").replace(/ /g, "-");
|
|
24496
24655
|
hideTooltipOnMouseOut();
|
|
24497
|
-
})
|
|
24656
|
+
}).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
24657
|
+
seriesId: data2.properties.legendUniqueId,
|
|
24658
|
+
dimValue: Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension),
|
|
24659
|
+
legendUniqueId: data2.properties.legendUniqueId,
|
|
24660
|
+
seriesDisplayName: data2.properties.alias || data2.properties.name || ""
|
|
24661
|
+
})));
|
|
24498
24662
|
columnGroups.exit().remove();
|
|
24499
24663
|
});
|
|
24500
24664
|
gTag.selectAll(".parentGroup").raise();
|
|
@@ -24581,12 +24745,18 @@
|
|
|
24581
24745
|
data,
|
|
24582
24746
|
isReportEditable,
|
|
24583
24747
|
onDataLabelCoordinatesChange,
|
|
24584
|
-
addLocalFilterFromLib
|
|
24748
|
+
addLocalFilterFromLib,
|
|
24749
|
+
onElementClick,
|
|
24750
|
+
vfxPickModeActive
|
|
24585
24751
|
}) => {
|
|
24586
24752
|
const chartId = crypto.randomUUID();
|
|
24587
24753
|
let columnWidth = 0;
|
|
24588
24754
|
const chartType = chartTypes.StackHorizontalBarChart;
|
|
24589
24755
|
const svgRef = require$$0$1.useRef();
|
|
24756
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
24757
|
+
onElementClickRef.current = onElementClick;
|
|
24758
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
24759
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
24590
24760
|
const seriesData = generalizedChartData(
|
|
24591
24761
|
data.ChartData,
|
|
24592
24762
|
data.DimensionList
|
|
@@ -24941,7 +25111,7 @@
|
|
|
24941
25111
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr("x", (d) => Math.min(xScaleBottom(d[0]), xScaleBottom(d[1]))).attr("width", 0).attr("visibility", (d, i, nodes) => {
|
|
24942
25112
|
const props = getPropsForRect(nodes, i).props;
|
|
24943
25113
|
return d.data[d.key] === 0 && props?.hideZeroValues ? "hidden" : "visible";
|
|
24944
|
-
}).on("mousemove", (event2, d) => {
|
|
25114
|
+
}).attr(VfxDataAttr.SeriesId, (d) => d.key ?? "").attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension)).on("mousemove", (event2, d) => {
|
|
24945
25115
|
const dim = d.data.dimension;
|
|
24946
25116
|
showTooltipOnMouseMove(
|
|
24947
25117
|
[
|
|
@@ -24970,7 +25140,12 @@
|
|
|
24970
25140
|
}).on("mouseout", (event2, d) => {
|
|
24971
25141
|
d.data.dimension;
|
|
24972
25142
|
hideTooltipOnMouseOut();
|
|
24973
|
-
})
|
|
25143
|
+
}).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
25144
|
+
seriesId: d.key,
|
|
25145
|
+
dimValue: Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension),
|
|
25146
|
+
legendUniqueId: d.key,
|
|
25147
|
+
seriesDisplayName: d.properties?.alias || d.properties?.name || ""
|
|
25148
|
+
})));
|
|
24974
25149
|
baseRects.attr("x", (d) => xScaleBottom(0));
|
|
24975
25150
|
const finalRects = formatOptions.animation.animationEnabled ? baseRects.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : baseRects;
|
|
24976
25151
|
finalRects.attr("x", (d) => Math.min(xScaleBottom(d[0]), xScaleBottom(d[1]))).attr("width", (d) => Math.abs(xScaleBottom(d[1]) - xScaleBottom(d[0])));
|
|
@@ -25306,12 +25481,18 @@
|
|
|
25306
25481
|
data,
|
|
25307
25482
|
isReportEditable,
|
|
25308
25483
|
onDataLabelCoordinatesChange,
|
|
25309
|
-
addLocalFilterFromLib
|
|
25484
|
+
addLocalFilterFromLib,
|
|
25485
|
+
onElementClick,
|
|
25486
|
+
vfxPickModeActive
|
|
25310
25487
|
}) => {
|
|
25311
25488
|
const chartId = crypto.randomUUID();
|
|
25312
25489
|
let columnWidth = 0;
|
|
25313
25490
|
const chartType = chartTypes.NormalizedStackHorizontalBarChart;
|
|
25314
25491
|
const svgRef = require$$0$1.useRef();
|
|
25492
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
25493
|
+
onElementClickRef.current = onElementClick;
|
|
25494
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
25495
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
25315
25496
|
const seriesData = generalizedChartData(
|
|
25316
25497
|
data.ChartData,
|
|
25317
25498
|
data.DimensionList
|
|
@@ -25646,7 +25827,7 @@
|
|
|
25646
25827
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr("x", (d) => xScaleBottom(0)).attr("width", 0).attr("visibility", (d, i, nodes) => {
|
|
25647
25828
|
const props = getPropsForRect(nodes, i).props;
|
|
25648
25829
|
return d.data[d.key] === 0 && props?.hideZeroValues ? "hidden" : "visible";
|
|
25649
|
-
}).on("mousemove", (event2, d) => {
|
|
25830
|
+
}).attr(VfxDataAttr.SeriesId, (d) => d.key ?? "").attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension)).on("mousemove", (event2, d) => {
|
|
25650
25831
|
const dim = d.data.dimension;
|
|
25651
25832
|
showTooltipOnMouseMove(
|
|
25652
25833
|
[
|
|
@@ -25677,7 +25858,12 @@
|
|
|
25677
25858
|
selectAll(".parentGroup").classed("highlight", false).classed("unhighlight", false);
|
|
25678
25859
|
selectAll('[hoverId="' + legend + '"]').classed("highlight", false).classed("unhighlight", false);
|
|
25679
25860
|
hideTooltipOnMouseOut();
|
|
25680
|
-
})
|
|
25861
|
+
}).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
25862
|
+
seriesId: d.key,
|
|
25863
|
+
dimValue: Array.isArray(d.data.dimension) ? String(d.data.dimension[0]) : String(d.data.dimension),
|
|
25864
|
+
legendUniqueId: d.key,
|
|
25865
|
+
seriesDisplayName: d.properties?.alias || d.properties?.name || ""
|
|
25866
|
+
})));
|
|
25681
25867
|
const finalRects = formatOptions.animation.animationEnabled ? baseRects.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : baseRects;
|
|
25682
25868
|
finalRects.attr("x", (d) => Math.min(xScaleBottom(d[0]), xScaleBottom(d[1]))).attr("width", (d) => Math.abs(xScaleBottom(d[1]) - xScaleBottom(d[0])));
|
|
25683
25869
|
columnGroups.exit().remove();
|
|
@@ -25787,12 +25973,18 @@
|
|
|
25787
25973
|
data,
|
|
25788
25974
|
isReportEditable,
|
|
25789
25975
|
onDataLabelCoordinatesChange,
|
|
25790
|
-
addLocalFilterFromLib
|
|
25976
|
+
addLocalFilterFromLib,
|
|
25977
|
+
onElementClick,
|
|
25978
|
+
vfxPickModeActive
|
|
25791
25979
|
}) => {
|
|
25792
25980
|
const chartId = crypto.randomUUID();
|
|
25793
25981
|
let columnWidth = 0;
|
|
25794
25982
|
const chartType = chartTypes.LayeredHorizontalBarChart;
|
|
25795
25983
|
const svgRef = require$$0$1.useRef();
|
|
25984
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
25985
|
+
onElementClickRef.current = onElementClick;
|
|
25986
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
25987
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
25796
25988
|
const seriesData = generalizedChartData(
|
|
25797
25989
|
data.ChartData,
|
|
25798
25990
|
data.DimensionList
|
|
@@ -26141,7 +26333,7 @@
|
|
|
26141
26333
|
).style("clip-path", "inset(0px) fill-box").style("shape-rendering", "crispEdges").attr("opacity", 0.7).attr(
|
|
26142
26334
|
"visibility",
|
|
26143
26335
|
(d) => d.value === 0 && formatOptions.xAxisLabel.hideZeroValues ? "hidden" : "visible"
|
|
26144
|
-
);
|
|
26336
|
+
).attr(VfxDataAttr.SeriesId, () => data2.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d) => Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension));
|
|
26145
26337
|
const finalBars = formatOptions.animation.animationEnabled ? bars.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : bars;
|
|
26146
26338
|
finalBars.attr(
|
|
26147
26339
|
"x",
|
|
@@ -26184,7 +26376,12 @@
|
|
|
26184
26376
|
);
|
|
26185
26377
|
}).on("mouseout", () => {
|
|
26186
26378
|
hideTooltipOnMouseOut();
|
|
26187
|
-
})
|
|
26379
|
+
}).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
26380
|
+
seriesId: data2.properties.legendUniqueId,
|
|
26381
|
+
dimValue: Array.isArray(d.dimension) ? String(d.dimension[0]) : String(d.dimension),
|
|
26382
|
+
legendUniqueId: data2.properties.legendUniqueId,
|
|
26383
|
+
seriesDisplayName: data2.properties.alias || data2.properties.name || ""
|
|
26384
|
+
})));
|
|
26188
26385
|
columnGroups.exit().remove();
|
|
26189
26386
|
});
|
|
26190
26387
|
gTag.selectAll(".parentGroup").raise();
|
|
@@ -27004,12 +27201,19 @@
|
|
|
27004
27201
|
data,
|
|
27005
27202
|
isReportEditable,
|
|
27006
27203
|
onDataLabelCoordinatesChange,
|
|
27007
|
-
addLocalFilterFromLib
|
|
27204
|
+
addLocalFilterFromLib,
|
|
27205
|
+
tooltipFormatter,
|
|
27206
|
+
onElementClick,
|
|
27207
|
+
vfxPickModeActive
|
|
27008
27208
|
}) => {
|
|
27009
27209
|
const chartId = crypto.randomUUID();
|
|
27010
27210
|
const barWidth = 0;
|
|
27011
27211
|
const chartType = chartTypes.AreaChart;
|
|
27012
27212
|
const svgRef = require$$0$1.useRef();
|
|
27213
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
27214
|
+
onElementClickRef.current = onElementClick;
|
|
27215
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
27216
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
27013
27217
|
const seriesData = generalizedChartData(
|
|
27014
27218
|
data.ChartData,
|
|
27015
27219
|
data.DimensionList
|
|
@@ -27133,7 +27337,8 @@
|
|
|
27133
27337
|
yLabel,
|
|
27134
27338
|
yTitle,
|
|
27135
27339
|
seriesData,
|
|
27136
|
-
chartJSON.dimensionList
|
|
27340
|
+
chartJSON.dimensionList,
|
|
27341
|
+
data
|
|
27137
27342
|
));
|
|
27138
27343
|
initSvg$1(
|
|
27139
27344
|
// for svg creation
|
|
@@ -27425,7 +27630,12 @@
|
|
|
27425
27630
|
/\s+/g,
|
|
27426
27631
|
"-"
|
|
27427
27632
|
)
|
|
27428
|
-
).attr("d", (d) => areaGeneratorStart(d.data)).
|
|
27633
|
+
).attr("d", (d) => areaGeneratorStart(d.data)).attr(VfxDataAttr.SeriesId, (d) => d.properties.legendUniqueId).attr(VfxDataAttr.DimValue, (d) => d.properties.alias || d.properties.name || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
27634
|
+
seriesId: d.properties.legendUniqueId,
|
|
27635
|
+
dimValue: d.properties.alias || d.properties.name || "",
|
|
27636
|
+
legendUniqueId: d.properties.legendUniqueId,
|
|
27637
|
+
seriesDisplayName: d.properties.alias || d.properties.name || ""
|
|
27638
|
+
}))).each(function(d) {
|
|
27429
27639
|
if (enableTransition) {
|
|
27430
27640
|
select$2(this).transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]).attr("d", areaGenerator(d.data));
|
|
27431
27641
|
} else {
|
|
@@ -27484,7 +27694,9 @@
|
|
|
27484
27694
|
secondaryCustomYaxisMaxValue,
|
|
27485
27695
|
secondaryCustomYaxisMinValue,
|
|
27486
27696
|
customYaxisMinValue,
|
|
27487
|
-
customYaxisMaxValue
|
|
27697
|
+
customYaxisMaxValue,
|
|
27698
|
+
false,
|
|
27699
|
+
tooltipFormatter
|
|
27488
27700
|
);
|
|
27489
27701
|
gTag.selectAll(".parentGroup").raise();
|
|
27490
27702
|
gTag.selectAll(".hoverLine").raise();
|
|
@@ -27601,12 +27813,18 @@
|
|
|
27601
27813
|
data,
|
|
27602
27814
|
isReportEditable,
|
|
27603
27815
|
onDataLabelCoordinatesChange,
|
|
27604
|
-
addLocalFilterFromLib
|
|
27816
|
+
addLocalFilterFromLib,
|
|
27817
|
+
onElementClick,
|
|
27818
|
+
vfxPickModeActive
|
|
27605
27819
|
}) => {
|
|
27606
27820
|
const chartId = crypto.randomUUID();
|
|
27607
27821
|
const barWidth = 0;
|
|
27608
27822
|
const chartType = chartTypes.StackAreaChart;
|
|
27609
27823
|
const svgRef = require$$0$1.useRef();
|
|
27824
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
27825
|
+
onElementClickRef.current = onElementClick;
|
|
27826
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
27827
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
27610
27828
|
const seriesData = generalizedChartData(data.ChartData, data.DimensionList)?.reverse() || [];
|
|
27611
27829
|
const dimensionList = data.DimensionList;
|
|
27612
27830
|
const barChart = false;
|
|
@@ -27728,7 +27946,8 @@
|
|
|
27728
27946
|
yLabel,
|
|
27729
27947
|
yTitle,
|
|
27730
27948
|
seriesData,
|
|
27731
|
-
chartJSON.dimensionList
|
|
27949
|
+
chartJSON.dimensionList,
|
|
27950
|
+
data
|
|
27732
27951
|
));
|
|
27733
27952
|
initSvg$1(
|
|
27734
27953
|
// for svg creation
|
|
@@ -27982,7 +28201,16 @@
|
|
|
27982
28201
|
areaGroupsEnter.append("path").attr(
|
|
27983
28202
|
"hoverId",
|
|
27984
28203
|
(d) => (lineData[d.index].properties.alias || lineData[d.index].properties.name || "Legend").replace(/\s+/g, "-")
|
|
27985
|
-
).attr("class", "area parentGroup").attr("fill", (d) => d.color !== commonColors.white ? d.color : "none").style("fill-opacity", formatOptions.plotArea.fillOpacity).style("pointer-events", "none").attr("d", (d) => areaGeneratorStart(d)).
|
|
28204
|
+
).attr("class", "area parentGroup").attr("fill", (d) => d.color !== commonColors.white ? d.color : "none").style("fill-opacity", formatOptions.plotArea.fillOpacity).style("pointer-events", "none").attr("d", (d) => areaGeneratorStart(d)).attr(VfxDataAttr.SeriesId, (d) => seriesData[d.index]?.properties?.legendUniqueId ?? d.key).attr(VfxDataAttr.DimValue, (d) => seriesData[d.index]?.properties?.alias || seriesData[d.index]?.properties?.name || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => {
|
|
28205
|
+
const sid = seriesData[d.index]?.properties?.legendUniqueId ?? d.key;
|
|
28206
|
+
const displayName = seriesData[d.index]?.properties?.alias || seriesData[d.index]?.properties?.name || "";
|
|
28207
|
+
return {
|
|
28208
|
+
seriesId: sid,
|
|
28209
|
+
dimValue: displayName,
|
|
28210
|
+
legendUniqueId: sid,
|
|
28211
|
+
seriesDisplayName: displayName
|
|
28212
|
+
};
|
|
28213
|
+
})).each(function(d) {
|
|
27986
28214
|
if (enableTransition) {
|
|
27987
28215
|
select$2(this).transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]).attr("d", areaGenerator(d));
|
|
27988
28216
|
} else {
|
|
@@ -28208,12 +28436,18 @@
|
|
|
28208
28436
|
data,
|
|
28209
28437
|
isReportEditable,
|
|
28210
28438
|
onDataLabelCoordinatesChange,
|
|
28211
|
-
addLocalFilterFromLib
|
|
28439
|
+
addLocalFilterFromLib,
|
|
28440
|
+
onElementClick,
|
|
28441
|
+
vfxPickModeActive
|
|
28212
28442
|
}) => {
|
|
28213
28443
|
const chartId = crypto.randomUUID();
|
|
28214
28444
|
const barWidth = 0;
|
|
28215
28445
|
const chartType = chartTypes.NormalizedStackAreaChart;
|
|
28216
28446
|
const svgRef = require$$0$1.useRef();
|
|
28447
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
28448
|
+
onElementClickRef.current = onElementClick;
|
|
28449
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
28450
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
28217
28451
|
const seriesData = generalizedChartData(data.ChartData, data.DimensionList)?.reverse() || [];
|
|
28218
28452
|
const dimensionList = data.DimensionList;
|
|
28219
28453
|
const barChart = false;
|
|
@@ -28326,7 +28560,8 @@
|
|
|
28326
28560
|
yLabel,
|
|
28327
28561
|
yTitle,
|
|
28328
28562
|
seriesData,
|
|
28329
|
-
chartJSON.dimensionList
|
|
28563
|
+
chartJSON.dimensionList,
|
|
28564
|
+
data
|
|
28330
28565
|
));
|
|
28331
28566
|
initSvg$1(
|
|
28332
28567
|
// for svg creation
|
|
@@ -28554,7 +28789,16 @@
|
|
|
28554
28789
|
areaGroupsEnter.append("path").attr(
|
|
28555
28790
|
"hoverId",
|
|
28556
28791
|
(d) => (lineData[d.index]?.properties?.alias || lineData[d.index]?.properties?.name || "Legend").replace(/\s+/g, "-")
|
|
28557
|
-
).attr("class", "area parentGroup").attr("fill", (d) => d.color !== commonColors.white ? d.color : "none").style("fill-opacity", formatOptions.plotArea.fillOpacity).style("pointer-events", "none").attr("d", (d) => columnGeneratorStart(d)).
|
|
28792
|
+
).attr("class", "area parentGroup").attr("fill", (d) => d.color !== commonColors.white ? d.color : "none").style("fill-opacity", formatOptions.plotArea.fillOpacity).style("pointer-events", "none").attr("d", (d) => columnGeneratorStart(d)).attr(VfxDataAttr.SeriesId, (d) => seriesData[d.index]?.properties?.legendUniqueId ?? d.key).attr(VfxDataAttr.DimValue, (d) => seriesData[d.index]?.properties?.alias || seriesData[d.index]?.properties?.name || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => {
|
|
28793
|
+
const sid = seriesData[d.index]?.properties?.legendUniqueId ?? d.key;
|
|
28794
|
+
const displayName = seriesData[d.index]?.properties?.alias || seriesData[d.index]?.properties?.name || "";
|
|
28795
|
+
return {
|
|
28796
|
+
seriesId: sid,
|
|
28797
|
+
dimValue: displayName,
|
|
28798
|
+
legendUniqueId: sid,
|
|
28799
|
+
seriesDisplayName: displayName
|
|
28800
|
+
};
|
|
28801
|
+
})).each(function(d) {
|
|
28558
28802
|
const path2 = select$2(this);
|
|
28559
28803
|
if (enableTransition) {
|
|
28560
28804
|
path2.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]).attr("d", columnGenerator(d));
|
|
@@ -28873,8 +29117,12 @@
|
|
|
28873
29117
|
}
|
|
28874
29118
|
};
|
|
28875
29119
|
const fileName$8 = "PieChart.tsx";
|
|
28876
|
-
const PieChart = ({ data, formatOptions, chartId, isReportEditable, onDataLabelCoordinatesChange, addLocalFilterFromLib }) => {
|
|
29120
|
+
const PieChart = ({ data, formatOptions, chartId, isReportEditable, onDataLabelCoordinatesChange, addLocalFilterFromLib, onElementClick, vfxPickModeActive }) => {
|
|
28877
29121
|
const svgRef = require$$0$1.useRef();
|
|
29122
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
29123
|
+
onElementClickRef.current = onElementClick;
|
|
29124
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
29125
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
28878
29126
|
const seriesData = generalizedChartData(data.ChartData);
|
|
28879
29127
|
let chartFormatOptions;
|
|
28880
29128
|
let height;
|
|
@@ -29007,7 +29255,12 @@
|
|
|
29007
29255
|
).attr(
|
|
29008
29256
|
"fill",
|
|
29009
29257
|
(d) => d.data.properties.color !== commonColors.white ? d.data.properties.color : "none"
|
|
29010
|
-
).
|
|
29258
|
+
).attr(VfxDataAttr.SeriesId, (d) => d.data.properties.legendUniqueId ?? d.data.properties.name ?? "").attr(VfxDataAttr.DimValue, (d) => d.data.properties.alias || d.data.legend || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
29259
|
+
seriesId: d.data.properties.legendUniqueId ?? d.data.properties.name ?? "",
|
|
29260
|
+
dimValue: d.data.properties.alias || d.data.legend || "",
|
|
29261
|
+
legendUniqueId: d.data.properties.legendUniqueId ?? d.data.properties.name ?? "",
|
|
29262
|
+
seriesDisplayName: d.data.properties.alias || d.data.properties.name || ""
|
|
29263
|
+
}))).on("mouseover.arc", function(d) {
|
|
29011
29264
|
select$2(this).transition().duration(100).attr("d", arcOver);
|
|
29012
29265
|
}).on("mousemove. ", (d) => {
|
|
29013
29266
|
showTooltipOnMouseMove(
|
|
@@ -29309,9 +29562,15 @@
|
|
|
29309
29562
|
chartId,
|
|
29310
29563
|
isReportEditable,
|
|
29311
29564
|
onDataLabelCoordinatesChange,
|
|
29312
|
-
addLocalFilterFromLib
|
|
29565
|
+
addLocalFilterFromLib,
|
|
29566
|
+
onElementClick,
|
|
29567
|
+
vfxPickModeActive
|
|
29313
29568
|
}) => {
|
|
29314
29569
|
const svgRef = require$$0$1.useRef();
|
|
29570
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
29571
|
+
onElementClickRef.current = onElementClick;
|
|
29572
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
29573
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
29315
29574
|
const seriesData = generalizedChartData(data.ChartData);
|
|
29316
29575
|
let chartFormatOptions;
|
|
29317
29576
|
let width;
|
|
@@ -29444,7 +29703,12 @@
|
|
|
29444
29703
|
).attr(
|
|
29445
29704
|
"fill",
|
|
29446
29705
|
(d) => d.data.properties.color !== commonColors.white ? d.data.properties.color : "none"
|
|
29447
|
-
).
|
|
29706
|
+
).attr(VfxDataAttr.SeriesId, (d) => d.data.properties.legendUniqueId ?? d.data.properties.name ?? "").attr(VfxDataAttr.DimValue, (d) => d.data.properties.alias || d.data.legend || "").on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
29707
|
+
seriesId: d.data.properties.legendUniqueId ?? d.data.properties.name ?? "",
|
|
29708
|
+
dimValue: d.data.properties.alias || d.data.legend || "",
|
|
29709
|
+
legendUniqueId: d.data.properties.legendUniqueId ?? d.data.properties.name ?? "",
|
|
29710
|
+
seriesDisplayName: d.data.properties.alias || d.data.properties.name || ""
|
|
29711
|
+
}))).each(function(d) {
|
|
29448
29712
|
const thisPath = d;
|
|
29449
29713
|
thisPath._current = { startAngle: 0, endAngle: 0 };
|
|
29450
29714
|
}).on("mouseover.arc", function() {
|
|
@@ -29807,8 +30071,12 @@
|
|
|
29807
30071
|
) });
|
|
29808
30072
|
};
|
|
29809
30073
|
const fileName$6 = "TreemapChart.tsx";
|
|
29810
|
-
const Treemap = ({ data, formatOptions, chartId }) => {
|
|
30074
|
+
const Treemap = ({ data, formatOptions, chartId, onElementClick, vfxPickModeActive }) => {
|
|
29811
30075
|
const svgRef = require$$0$1.useRef();
|
|
30076
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
30077
|
+
onElementClickRef.current = onElementClick;
|
|
30078
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
30079
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
29812
30080
|
let chartFormatOptions;
|
|
29813
30081
|
let width;
|
|
29814
30082
|
let height;
|
|
@@ -29975,7 +30243,16 @@
|
|
|
29975
30243
|
void 0,
|
|
29976
30244
|
getMarkerColorForTooltip(d)
|
|
29977
30245
|
);
|
|
29978
|
-
}).on("mouseout", () => hideTooltipOnMouseOut())
|
|
30246
|
+
}).on("mouseout", () => hideTooltipOnMouseOut()).attr(VfxDataAttr.SeriesId, (d) => String(d.data.properties?.legendUniqueId ?? d.data.legend ?? "")).attr(VfxDataAttr.DimValue, (d) => String(d.data.data[0].legend ?? "")).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => {
|
|
30247
|
+
const seriesId = String(d.data.properties?.legendUniqueId ?? d.data.legend ?? "");
|
|
30248
|
+
const dimValue = String(d.data.data[0].legend ?? "");
|
|
30249
|
+
return {
|
|
30250
|
+
seriesId,
|
|
30251
|
+
dimValue,
|
|
30252
|
+
legendUniqueId: seriesId,
|
|
30253
|
+
seriesDisplayName: String(d.data.properties?.alias || d.data.properties?.name || dimValue)
|
|
30254
|
+
};
|
|
30255
|
+
}));
|
|
29979
30256
|
if (shouldAnimate) {
|
|
29980
30257
|
rects.transition().duration(chartFormatOptions.animation.animationDuration).ease(effectsMap[chartFormatOptions.animation.animationEffect]).attr("fill-opacity", 0.7);
|
|
29981
30258
|
}
|
|
@@ -36458,12 +36735,18 @@
|
|
|
36458
36735
|
const SankeyChart = ({
|
|
36459
36736
|
formatOptions,
|
|
36460
36737
|
data,
|
|
36461
|
-
chartId
|
|
36738
|
+
chartId,
|
|
36739
|
+
onElementClick,
|
|
36740
|
+
vfxPickModeActive
|
|
36462
36741
|
}) => {
|
|
36463
36742
|
let sankeyLinks = JSON.parse(JSON.stringify(data?.sankeyLinks));
|
|
36464
36743
|
let sankeyNodes = JSON.parse(JSON.stringify(data?.sankeyNodes));
|
|
36465
36744
|
if (!data) return null;
|
|
36466
36745
|
const svgRef = require$$0$1.useRef();
|
|
36746
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
36747
|
+
onElementClickRef.current = onElementClick;
|
|
36748
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
36749
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
36467
36750
|
let chartFormatOptions;
|
|
36468
36751
|
let width;
|
|
36469
36752
|
let height;
|
|
@@ -36750,7 +37033,15 @@
|
|
|
36750
37033
|
} catch (error) {
|
|
36751
37034
|
logError$2("SankeyChart.tsx", "Nodes.onMouseOut", error);
|
|
36752
37035
|
}
|
|
36753
|
-
})
|
|
37036
|
+
}).attr(VfxDataAttr.SeriesId, (d) => String(d.name ?? "")).attr(VfxDataAttr.DimValue, (d) => String(d.name ?? "")).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => {
|
|
37037
|
+
const nodeName = String(d.name ?? "");
|
|
37038
|
+
return {
|
|
37039
|
+
seriesId: nodeName,
|
|
37040
|
+
dimValue: nodeName,
|
|
37041
|
+
legendUniqueId: nodeName,
|
|
37042
|
+
seriesDisplayName: nodeName.includes("~$~") ? nodeName.split("~$~")[1] : nodeName
|
|
37043
|
+
};
|
|
37044
|
+
}));
|
|
36754
37045
|
const link2 = chartAreaTagG.append("g").attr("fill", "none").selectAll("g").data(links).enter().append("g").style("mix-blend-mode", "multiply");
|
|
36755
37046
|
link2.append("path").attr("class", "sankey-links").attr("stroke-opacity", linksFillOpacity).attr("id", (d) => "Link" + d.index).attr("d", sankeyLinkCustom(curviness)).attr(
|
|
36756
37047
|
"stroke",
|
|
@@ -54958,8 +55249,15 @@
|
|
|
54958
55249
|
data,
|
|
54959
55250
|
formatOptions,
|
|
54960
55251
|
chartId,
|
|
54961
|
-
addLocalFilterFromLib
|
|
55252
|
+
addLocalFilterFromLib,
|
|
55253
|
+
onElementClick,
|
|
55254
|
+
vfxPickModeActive
|
|
54962
55255
|
}) => {
|
|
55256
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
55257
|
+
onElementClickRef.current = onElementClick;
|
|
55258
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
55259
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
55260
|
+
const legendIndexMap = new Map((data.ChartData ?? []).map((s2, i) => [s2.legend, i]));
|
|
54963
55261
|
let legendEntries = data.LegendList;
|
|
54964
55262
|
const svgRef = require$$0$1.useRef();
|
|
54965
55263
|
let chartFormatOptions;
|
|
@@ -55132,10 +55430,15 @@
|
|
|
55132
55430
|
);
|
|
55133
55431
|
}).attr("transform", function(d) {
|
|
55134
55432
|
return `translate(${xScale(d.dimension)}, ${yScale(d.measure)})`;
|
|
55135
|
-
}).attr("opacity", shouldAnimate ? 0 : chartFormatOptions.plotArea.fillOpacity).style(
|
|
55433
|
+
}).attr(VfxDataAttr.SeriesId, (d) => `${legendIndexMap.get(d.legendName)}_${d.legendName}`).attr(VfxDataAttr.DimValue, (d) => String(d.dimension)).attr("opacity", shouldAnimate ? 0 : chartFormatOptions.plotArea.fillOpacity).style(
|
|
55136
55434
|
"visibility",
|
|
55137
55435
|
(d, i) => d.dimension[0] === 0 || d.measure === 0 && chartFormatOptions.plotArea.hideZeroValues || d.dimension < customXaxisMinValue || d.dimension > customXaxisMaxValue || d.measure < customYaxisMinValue || d.measure > customYaxisMaxValue ? "hidden" : "visible"
|
|
55138
|
-
).on("
|
|
55436
|
+
).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
55437
|
+
seriesId: `${legendIndexMap.get(d.legendName)}_${d.legendName}`,
|
|
55438
|
+
dimValue: String(d.dimension),
|
|
55439
|
+
legendUniqueId: `${legendIndexMap.get(d.legendName)}_${d.legendName}`,
|
|
55440
|
+
seriesDisplayName: d.legendName
|
|
55441
|
+
}))).on("mousemove", (event2, d) => {
|
|
55139
55442
|
showTooltipOnMouseMove(
|
|
55140
55443
|
[
|
|
55141
55444
|
{
|
|
@@ -55418,10 +55721,17 @@
|
|
|
55418
55721
|
const ScatterChart = ({
|
|
55419
55722
|
data,
|
|
55420
55723
|
formatOptions,
|
|
55421
|
-
chartId
|
|
55724
|
+
chartId,
|
|
55725
|
+
onElementClick,
|
|
55726
|
+
vfxPickModeActive
|
|
55422
55727
|
}) => {
|
|
55728
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
55729
|
+
onElementClickRef.current = onElementClick;
|
|
55730
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
55731
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
55423
55732
|
const colorsList = data.ColorElements ?? [];
|
|
55424
55733
|
const shapesList = data.ShapeElements ?? [];
|
|
55734
|
+
const colorIndexMap = new Map(colorsList.map((c2, i) => [c2.name, i]));
|
|
55425
55735
|
let modifiedData = [];
|
|
55426
55736
|
const svgRef = require$$0$1.useRef();
|
|
55427
55737
|
let chartFormatOptions;
|
|
@@ -55587,10 +55897,15 @@
|
|
|
55587
55897
|
);
|
|
55588
55898
|
}).attr("transform", function(d) {
|
|
55589
55899
|
return `translate(${xScale(d.dimension)}, ${yScale(d.measure)})`;
|
|
55590
|
-
}).attr("opacity", shouldAnimate ? 0 : chartFormatOptions.plotArea.fillOpacity).style(
|
|
55900
|
+
}).attr(VfxDataAttr.SeriesId, (d) => `${colorIndexMap.get(d.colorName)}_${d.colorName}`).attr(VfxDataAttr.DimValue, (d) => String(d.dimension)).attr("opacity", shouldAnimate ? 0 : chartFormatOptions.plotArea.fillOpacity).style(
|
|
55591
55901
|
"visibility",
|
|
55592
55902
|
(d, i) => d.dimension[0] === 0 || d.measure === 0 && chartFormatOptions.plotArea.hideZeroValues || d.dimension < customXaxisMinValue || d.dimension > customXaxisMaxValue || d.measure < customYaxisMinValue || d.measure > customYaxisMaxValue ? "hidden" : "visible"
|
|
55593
|
-
).on("
|
|
55903
|
+
).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
55904
|
+
seriesId: `${colorIndexMap.get(d.colorName)}_${d.colorName}`,
|
|
55905
|
+
dimValue: String(d.dimension),
|
|
55906
|
+
legendUniqueId: `${colorIndexMap.get(d.colorName)}_${d.colorName}`,
|
|
55907
|
+
seriesDisplayName: d.colorName
|
|
55908
|
+
}))).on("mousemove", (event2, d) => {
|
|
55594
55909
|
showTooltipOnMouseMove(
|
|
55595
55910
|
[
|
|
55596
55911
|
...[
|
|
@@ -56058,13 +56373,19 @@
|
|
|
56058
56373
|
isDateType,
|
|
56059
56374
|
formatOptions,
|
|
56060
56375
|
data,
|
|
56061
|
-
isAdvancedAnalyticsWaterFall = false
|
|
56376
|
+
isAdvancedAnalyticsWaterFall = false,
|
|
56377
|
+
onElementClick,
|
|
56378
|
+
vfxPickModeActive
|
|
56062
56379
|
}) => {
|
|
56063
56380
|
const chartId = crypto.randomUUID?.();
|
|
56064
56381
|
let columnWidth = 0;
|
|
56065
56382
|
let colorScale;
|
|
56066
56383
|
const chartType = chartTypes.WaterfallChart;
|
|
56067
56384
|
const svgRef = require$$0$1.useRef();
|
|
56385
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
56386
|
+
onElementClickRef.current = onElementClick;
|
|
56387
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
56388
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
56068
56389
|
const isAdvancedWaterfall = isAdvancedAnalyticsWaterFall ?? false;
|
|
56069
56390
|
const seriesData = isAdvancedWaterfall ? [] : generalizedChartData(data.ChartData, data.DimensionList);
|
|
56070
56391
|
const dimensionList = data.DimensionList;
|
|
@@ -56510,7 +56831,14 @@
|
|
|
56510
56831
|
);
|
|
56511
56832
|
}).on("mouseout", () => {
|
|
56512
56833
|
hideTooltipOnMouseOut();
|
|
56513
|
-
})
|
|
56834
|
+
}).attr(VfxDataAttr.SeriesId, (d) => String(d.key ?? d.Key ?? "")).attr(
|
|
56835
|
+
VfxDataAttr.DimValue,
|
|
56836
|
+
(d) => !isAdvancedWaterfall ? String(d.data.dimension || d.data.legend || "") : String(d.data.xKey || "")
|
|
56837
|
+
).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => {
|
|
56838
|
+
const seriesId = String(d.key ?? d.Key ?? "");
|
|
56839
|
+
const dimValue = !isAdvancedWaterfall ? String(d.data.dimension || d.data.legend || "") : String(d.data.xKey || "");
|
|
56840
|
+
return { seriesId, dimValue, legendUniqueId: seriesId, seriesDisplayName: seriesId };
|
|
56841
|
+
}));
|
|
56514
56842
|
const finalRects = shouldAnimate ? rectsEnter.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : rectsEnter;
|
|
56515
56843
|
finalRects.attr("y", (d) => d[1] ? yScaleLeft(d[1]) : 0).attr("height", (d) => d[1] ? yScaleLeft(d[0]) - yScaleLeft(d[1]) : 0);
|
|
56516
56844
|
rects.exit().remove();
|
|
@@ -56737,13 +57065,19 @@
|
|
|
56737
57065
|
formatOptions,
|
|
56738
57066
|
data,
|
|
56739
57067
|
isReportEditable,
|
|
56740
|
-
onDataLabelCoordinatesChange
|
|
57068
|
+
onDataLabelCoordinatesChange,
|
|
57069
|
+
onElementClick,
|
|
57070
|
+
vfxPickModeActive
|
|
56741
57071
|
}) => {
|
|
56742
57072
|
const chartId = crypto.randomUUID();
|
|
56743
57073
|
let columnWidth = 0;
|
|
56744
57074
|
const chartType = chartTypes.TornadoChart;
|
|
56745
57075
|
const isAdvanceAnalyticsChart = data.IsadvanceanalyticsChart ?? data.IsCalCSensitivity;
|
|
56746
57076
|
const svgRef = require$$0$1.useRef();
|
|
57077
|
+
const onElementClickRef = require$$0$1.useRef(onElementClick);
|
|
57078
|
+
onElementClickRef.current = onElementClick;
|
|
57079
|
+
const vfxPickModeActiveRef = require$$0$1.useRef(vfxPickModeActive);
|
|
57080
|
+
vfxPickModeActiveRef.current = vfxPickModeActive;
|
|
56747
57081
|
let seriesData = generalizedChartData(
|
|
56748
57082
|
data.ChartData,
|
|
56749
57083
|
data.DimensionList,
|
|
@@ -56857,14 +57191,6 @@
|
|
|
56857
57191
|
chartJSON
|
|
56858
57192
|
));
|
|
56859
57193
|
setSVGContainer(margin);
|
|
56860
|
-
({ dataTable, dataTableHeight } = dataTablePreCalculation(
|
|
56861
|
-
// calculations for data tables
|
|
56862
|
-
formatOptions,
|
|
56863
|
-
yLabel,
|
|
56864
|
-
yTitle,
|
|
56865
|
-
seriesData,
|
|
56866
|
-
chartJSON.dimensionList
|
|
56867
|
-
));
|
|
56868
57194
|
initSvg$1(
|
|
56869
57195
|
// for svg creation
|
|
56870
57196
|
svg,
|
|
@@ -57150,7 +57476,7 @@
|
|
|
57150
57476
|
customYaxisMaxValue,
|
|
57151
57477
|
barChart,
|
|
57152
57478
|
innerWidth2
|
|
57153
|
-
).customTickValue ??
|
|
57479
|
+
).customTickValue ?? innerWidth2 / 30
|
|
57154
57480
|
).tickPadding(8).tickSizeOuter(0);
|
|
57155
57481
|
};
|
|
57156
57482
|
const getChartType = () => {
|
|
@@ -57205,7 +57531,12 @@
|
|
|
57205
57531
|
event2,
|
|
57206
57532
|
!data.IsCalCSensitivity ? d.properties : d.properties.legend === "Calculated Low(-ve)" ? { markerColor: formatOptions.plotArea.plotAreaCalculatedLow } : { markerColor: formatOptions.plotArea.plotAreaCalculatedHigh }
|
|
57207
57533
|
);
|
|
57208
|
-
}).on("mouseout", hideTooltipOnMouseOut)
|
|
57534
|
+
}).on("mouseout", hideTooltipOnMouseOut).attr(VfxDataAttr.SeriesId, (d) => String(d.properties?.legendUniqueId ?? "")).attr(VfxDataAttr.DimValue, (d) => String(d.legend ?? d.legendText ?? "")).on("click", makeVfxClickHandler(vfxPickModeActiveRef, onElementClickRef, (_event, d) => ({
|
|
57535
|
+
seriesId: String(d.properties?.legendUniqueId ?? ""),
|
|
57536
|
+
dimValue: String(d.legend ?? d.legendText ?? ""),
|
|
57537
|
+
legendUniqueId: String(d.properties?.legendUniqueId ?? ""),
|
|
57538
|
+
seriesDisplayName: String(d.properties?.alias || d.properties?.name || d.legendText || "")
|
|
57539
|
+
})));
|
|
57209
57540
|
const finalBars = shouldAnimate ? bars.transition().duration(formatOptions.animation.animationDuration).ease(effectsMap[formatOptions.animation.animationEffect]) : bars;
|
|
57210
57541
|
finalBars.attr("x", (d) => d.value >= 0 ? xScale(0) : xScale(d.value)).attr("width", (d) => Math.abs(xScale(d.value) - xScale(0)));
|
|
57211
57542
|
};
|