@fluentui/react-charts 0.0.0-nightly-20250815-0407.1 → 0.0.0-nightly-20250819-0407.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/dist/index.d.ts +56 -0
- package/lib/components/DeclarativeChart/DeclarativeChart.js +16 -8
- package/lib/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js +69 -48
- package/lib/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/lib/components/LineChart/LineChart.js +30 -9
- package/lib/components/LineChart/LineChart.js.map +1 -1
- package/lib/components/LineChart/LineChart.types.js.map +1 -1
- package/lib/components/LineChart/useLineChartStyles.styles.js +8 -2
- package/lib/components/LineChart/useLineChartStyles.styles.js.map +1 -1
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js +12 -1
- package/lib/components/LineChart/useLineChartStyles.styles.raw.js.map +1 -1
- package/lib/components/ScatterChart/ScatterChart.js +7 -7
- package/lib/components/ScatterChart/ScatterChart.js.map +1 -1
- package/lib/types/DataPoint.js.map +1 -1
- package/lib/utilities/utilities.js +33 -1
- package/lib/utilities/utilities.js.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js +16 -8
- package/lib-commonjs/components/DeclarativeChart/DeclarativeChart.js.map +1 -1
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js +69 -48
- package/lib-commonjs/components/DeclarativeChart/PlotlySchemaAdapter.js.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.js +30 -9
- package/lib-commonjs/components/LineChart/LineChart.js.map +1 -1
- package/lib-commonjs/components/LineChart/LineChart.types.js.map +1 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.js +10 -2
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.js.map +1 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.js +12 -1
- package/lib-commonjs/components/LineChart/useLineChartStyles.styles.raw.js.map +1 -1
- package/lib-commonjs/components/ScatterChart/ScatterChart.js +7 -7
- package/lib-commonjs/components/ScatterChart/ScatterChart.js.map +1 -1
- package/lib-commonjs/types/DataPoint.js.map +1 -1
- package/lib-commonjs/utilities/utilities.js +33 -0
- package/lib-commonjs/utilities/utilities.js.map +1 -1
- package/package.json +13 -13
|
@@ -437,7 +437,8 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
437
437
|
const circleId = `${_circleId}_${i}`;
|
|
438
438
|
const isLegendSelected = _legendHighlighted(legendVal) || _noLegendHighlighted() || isSelectedLegend;
|
|
439
439
|
const currentMarkerSize = _points[i].data[0].markerSize;
|
|
440
|
-
|
|
440
|
+
var _points_i_data__text;
|
|
441
|
+
pointsForLine.push(/*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement("circle", {
|
|
441
442
|
id: circleId,
|
|
442
443
|
key: circleId,
|
|
443
444
|
r: currentMarkerSize ? currentMarkerSize * extraMaxPixels / maxMarkerSize : activePoint === circleId ? 5.5 : 3.5,
|
|
@@ -452,7 +453,7 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
452
453
|
strokeWidth: activePoint === circleId ? DEFAULT_LINE_STROKE_SIZE : 0,
|
|
453
454
|
stroke: activePoint === circleId ? lineColor : '',
|
|
454
455
|
role: "img",
|
|
455
|
-
"aria-label": _getAriaLabel(i, 0),
|
|
456
|
+
"aria-label": (_points_i_data__text = _points[i].data[0].text) !== null && _points_i_data__text !== void 0 ? _points_i_data__text : _getAriaLabel(i, 0),
|
|
456
457
|
"data-is-focusable": isLegendSelected,
|
|
457
458
|
ref: (e)=>{
|
|
458
459
|
_refCallback(e, circleId);
|
|
@@ -460,7 +461,13 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
460
461
|
onFocus: (event)=>_handleFocus(event, circleId, x1, xAxisCalloutData, circleId, xAxisCalloutAccessibilityData),
|
|
461
462
|
onBlur: _handleMouseOut,
|
|
462
463
|
..._getClickHandler(_points[i].data[0].onDataPointClick)
|
|
463
|
-
})
|
|
464
|
+
}), _points[i].data[0].text && /*#__PURE__*/ React.createElement("text", {
|
|
465
|
+
key: `${circleId}-label`,
|
|
466
|
+
x: _xAxisScale(x1),
|
|
467
|
+
y: yScale(y1) + Math.max(currentMarkerSize ? currentMarkerSize * extraMaxPixels / maxMarkerSize : 3.5, 4) + 12,
|
|
468
|
+
className: classes.markerLabel,
|
|
469
|
+
opacity: isLegendSelected ? 1 : 0.1
|
|
470
|
+
}, _points[i].data[0].text)));
|
|
464
471
|
}
|
|
465
472
|
let gapIndex = 0;
|
|
466
473
|
var _points_i_gaps_sort;
|
|
@@ -562,7 +569,8 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
562
569
|
const isLegendSelected = _legendHighlighted(legendVal) || _noLegendHighlighted() || isSelectedLegend;
|
|
563
570
|
const currentPointHidden = _points[i].hideNonActiveDots && activePoint !== circleId;
|
|
564
571
|
let currentMarkerSize = _points[i].data[j - 1].markerSize;
|
|
565
|
-
|
|
572
|
+
var _points_i_data__text1;
|
|
573
|
+
pointsForLine.push(((_points_i_lineOptions8 = _points[i].lineOptions) === null || _points_i_lineOptions8 === void 0 ? void 0 : (_points_i_lineOptions_mode = _points_i_lineOptions8.mode) === null || _points_i_lineOptions_mode === void 0 ? void 0 : _points_i_lineOptions_mode.includes('markers')) ? /*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement("circle", {
|
|
566
574
|
id: circleId,
|
|
567
575
|
key: circleId,
|
|
568
576
|
r: currentMarkerSize ? currentMarkerSize * extraMaxPixels / maxMarkerSize : 4,
|
|
@@ -580,8 +588,14 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
580
588
|
stroke: lineColor,
|
|
581
589
|
strokeWidth: strokeWidth,
|
|
582
590
|
role: "img",
|
|
583
|
-
"aria-label": _getAriaLabel(i, j - 1)
|
|
584
|
-
})
|
|
591
|
+
"aria-label": (_points_i_data__text1 = _points[i].data[j - 1].text) !== null && _points_i_data__text1 !== void 0 ? _points_i_data__text1 : _getAriaLabel(i, j - 1)
|
|
592
|
+
}), _points[i].data[j - 1].text && /*#__PURE__*/ React.createElement("text", {
|
|
593
|
+
key: `${circleId}-label`,
|
|
594
|
+
x: _xAxisScale(x1),
|
|
595
|
+
y: yScale(y1) + 12,
|
|
596
|
+
fontSize: 12,
|
|
597
|
+
className: classes.markerLabel
|
|
598
|
+
}, _points[i].data[j - 1].text)) : /*#__PURE__*/ React.createElement("path", {
|
|
585
599
|
id: circleId,
|
|
586
600
|
key: circleId,
|
|
587
601
|
d: path,
|
|
@@ -609,9 +623,10 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
609
623
|
path = _getPath(_xAxisScale(x2), yScale(y2), lastCircleId, j, true, _points[i].index);
|
|
610
624
|
const { xAxisCalloutData: lastCirlceXCallout, xAxisCalloutAccessibilityData: lastCirlceXCalloutAccessibilityData } = _points[i].data[j];
|
|
611
625
|
currentMarkerSize = _points[i].data[j].markerSize;
|
|
626
|
+
var _points_i_data_j_text;
|
|
612
627
|
pointsForLine.push(/*#__PURE__*/ React.createElement(React.Fragment, {
|
|
613
628
|
key: `${lastCircleId}_container`
|
|
614
|
-
}, ((_points_i_lineOptions10 = _points[i].lineOptions) === null || _points_i_lineOptions10 === void 0 ? void 0 : (_points_i_lineOptions_mode2 = _points_i_lineOptions10.mode) === null || _points_i_lineOptions_mode2 === void 0 ? void 0 : _points_i_lineOptions_mode2.includes('markers')) ? /*#__PURE__*/ React.createElement("circle", {
|
|
629
|
+
}, ((_points_i_lineOptions10 = _points[i].lineOptions) === null || _points_i_lineOptions10 === void 0 ? void 0 : (_points_i_lineOptions_mode2 = _points_i_lineOptions10.mode) === null || _points_i_lineOptions_mode2 === void 0 ? void 0 : _points_i_lineOptions_mode2.includes('markers')) ? /*#__PURE__*/ React.createElement(React.Fragment, null, /*#__PURE__*/ React.createElement("circle", {
|
|
615
630
|
id: lastCircleId,
|
|
616
631
|
key: lastCircleId,
|
|
617
632
|
r: currentMarkerSize ? currentMarkerSize * extraMaxPixels / maxMarkerSize : 4,
|
|
@@ -629,8 +644,14 @@ const PATH_MULTIPLY_SIZE = 2.5;
|
|
|
629
644
|
stroke: lineColor,
|
|
630
645
|
strokeWidth: strokeWidth,
|
|
631
646
|
role: "img",
|
|
632
|
-
"aria-label": _getAriaLabel(i, j)
|
|
633
|
-
})
|
|
647
|
+
"aria-label": (_points_i_data_j_text = _points[i].data[j].text) !== null && _points_i_data_j_text !== void 0 ? _points_i_data_j_text : _getAriaLabel(i, j)
|
|
648
|
+
}), _points[i].data[j].text && /*#__PURE__*/ React.createElement("text", {
|
|
649
|
+
key: `${lastCircleId}-label`,
|
|
650
|
+
x: _xAxisScale(x2),
|
|
651
|
+
y: yScale(y2) + 12,
|
|
652
|
+
fontSize: 12,
|
|
653
|
+
className: classes.markerLabel
|
|
654
|
+
}, _points[i].data[j].text)) : /*#__PURE__*/ React.createElement("path", {
|
|
634
655
|
id: lastCircleId,
|
|
635
656
|
key: lastCircleId,
|
|
636
657
|
d: path,
|