@fluentui/react-charts 0.0.0-nightly-20251028-0422.1 → 0.0.0-nightly-20251029-0406.1
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/CHANGELOG.md +15 -15
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +20 -5
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +20 -5
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/package.json +12 -12
|
@@ -497,7 +497,7 @@ const transformPlotlyJsonToDonutProps = (input, isMultiPlot, colorMap, colorwayT
|
|
|
497
497
|
};
|
|
498
498
|
};
|
|
499
499
|
const transformPlotlyJsonToVSBCProps = (input, isMultiPlot, colorMap, colorwayType, isDarkTheme, fallbackVSBC)=>{
|
|
500
|
-
var
|
|
500
|
+
var _input_layout, _input_layout1, _input_layout2, _vsbcData_;
|
|
501
501
|
const mapXToDataPoints = {};
|
|
502
502
|
let yMaxValue = 0;
|
|
503
503
|
let yMinValue = 0;
|
|
@@ -574,15 +574,30 @@ const transformPlotlyJsonToVSBCProps = (input, isMultiPlot, colorMap, colorwayTy
|
|
|
574
574
|
});
|
|
575
575
|
});
|
|
576
576
|
});
|
|
577
|
-
var
|
|
578
|
-
const xCategories = (
|
|
577
|
+
var _input_data;
|
|
578
|
+
const xCategories = Array.from(new Set(((_input_data = input.data) !== null && _input_data !== void 0 ? _input_data : []).flatMap((trace)=>{
|
|
579
|
+
const xData = trace.x;
|
|
580
|
+
if (!xData) {
|
|
581
|
+
return [];
|
|
582
|
+
}
|
|
583
|
+
if (Array.isArray(xData)) {
|
|
584
|
+
return xData.flat().map((x)=>{
|
|
585
|
+
return x;
|
|
586
|
+
});
|
|
587
|
+
}
|
|
588
|
+
return [];
|
|
589
|
+
}).filter((x)=>x !== undefined && x !== null)));
|
|
579
590
|
var _input_layout_shapes;
|
|
580
591
|
((_input_layout_shapes = (_input_layout = input.layout) === null || _input_layout === void 0 ? void 0 : _input_layout.shapes) !== null && _input_layout_shapes !== void 0 ? _input_layout_shapes : []).filter((shape)=>shape.type === 'line').forEach((shape, shapeIdx)=>{
|
|
581
592
|
var _shape_line;
|
|
582
593
|
const lineColor = (_shape_line = shape.line) === null || _shape_line === void 0 ? void 0 : _shape_line.color;
|
|
583
594
|
const resolveX = (val)=>{
|
|
584
|
-
if (typeof val === 'number' && Array.isArray(xCategories)
|
|
585
|
-
|
|
595
|
+
if (typeof val === 'number' && Array.isArray(xCategories)) {
|
|
596
|
+
if (xCategories[val] !== undefined) {
|
|
597
|
+
return xCategories[val];
|
|
598
|
+
} else {
|
|
599
|
+
return xCategories[shapeIdx];
|
|
600
|
+
}
|
|
586
601
|
}
|
|
587
602
|
return val;
|
|
588
603
|
};
|