@rowsncolumns/charts 28.1.6 → 28.1.7

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.
Files changed (29) hide show
  1. package/dist/cjs/basic-chart/basic-chart.d.ts +1 -1
  2. package/dist/cjs/basic-chart/basic-chart.d.ts.map +1 -1
  3. package/dist/cjs/basic-chart/basic-chart.js +152 -137
  4. package/dist/cjs/components/editors/chart-editor.d.ts.map +1 -1
  5. package/dist/cjs/components/editors/chart-editor.js +5 -1
  6. package/dist/cjs/plotly/basic-chart/basic-chart.d.ts +1 -1
  7. package/dist/cjs/plotly/basic-chart/basic-chart.d.ts.map +1 -1
  8. package/dist/cjs/plotly/basic-chart/basic-chart.js +56 -11
  9. package/dist/cjs/utils/axis-number-format.d.ts +26 -7
  10. package/dist/cjs/utils/axis-number-format.d.ts.map +1 -1
  11. package/dist/cjs/utils/axis-number-format.js +94 -16
  12. package/dist/cjs/utils/overrides.d.ts +3 -3
  13. package/dist/cjs/utils/overrides.d.ts.map +1 -1
  14. package/dist/cjs/utils/overrides.js +32 -15
  15. package/dist/esm/basic-chart/basic-chart.d.ts +1 -1
  16. package/dist/esm/basic-chart/basic-chart.d.ts.map +1 -1
  17. package/dist/esm/basic-chart/basic-chart.js +64 -45
  18. package/dist/esm/components/editors/chart-editor.d.ts.map +1 -1
  19. package/dist/esm/components/editors/chart-editor.js +5 -1
  20. package/dist/esm/plotly/basic-chart/basic-chart.d.ts +1 -1
  21. package/dist/esm/plotly/basic-chart/basic-chart.d.ts.map +1 -1
  22. package/dist/esm/plotly/basic-chart/basic-chart.js +55 -12
  23. package/dist/esm/utils/axis-number-format.d.ts +26 -7
  24. package/dist/esm/utils/axis-number-format.d.ts.map +1 -1
  25. package/dist/esm/utils/axis-number-format.js +83 -13
  26. package/dist/esm/utils/overrides.d.ts +3 -3
  27. package/dist/esm/utils/overrides.d.ts.map +1 -1
  28. package/dist/esm/utils/overrides.js +33 -16
  29. package/package.json +3 -3
@@ -193,7 +193,7 @@ var defaultLegendConfig = {
193
193
  var CATEGORY_AXIS_NAME_GAP = (0, legend_layout_1.categoryAxisNameGap)();
194
194
  var BasicChart = function (_a) {
195
195
  var _b;
196
- var width = _a.width, height = _a.height, chart = _a.chart, theme = _a.theme, isDarkMode = _a.isDarkMode, sheetId = _a.sheetId, readonly = _a.readonly, getDomainValuesFromRange = _a.getDomainValuesFromRange, getSeriesValuesFromRange = _a.getSeriesValuesFromRange, getFormattingFromRange = _a.getFormattingFromRange, onDeleteChart = _a.onDeleteChart, onUpdateChart = _a.onUpdateChart, onRequestEdit = _a.onRequestEdit, onRequestCalculate = _a.onRequestCalculate, isSelected = _a.isSelected, fieldButtons = _a.fieldButtons;
196
+ var width = _a.width, height = _a.height, chart = _a.chart, theme = _a.theme, isDarkMode = _a.isDarkMode, sheetId = _a.sheetId, readonly = _a.readonly, getDomainValuesFromRange = _a.getDomainValuesFromRange, getSeriesValuesFromRange = _a.getSeriesValuesFromRange, getFormattingFromRange = _a.getFormattingFromRange, onDeleteChart = _a.onDeleteChart, onUpdateChart = _a.onUpdateChart, onRequestEdit = _a.onRequestEdit, onRequestCalculate = _a.onRequestCalculate, isSelected = _a.isSelected, fieldButtons = _a.fieldButtons, locale = _a.locale;
197
197
  var spec = chart.spec;
198
198
  var explicitChartTitle = (_b = chart.spec.title) !== null && _b !== void 0 ? _b : undefined;
199
199
  var hierarchyTitleRef = (0, react_1.useRef)(explicitChartTitle);
@@ -369,9 +369,9 @@ var BasicChart = function (_a) {
369
369
  var updateChart = function () { return tslib_1.__awaiter(void 0, void 0, void 0, function () {
370
370
  var threeDRenderKind, canRender3D, willRender3D, isRegionMap, regionSpec, geoScope, geo, labels, seriesEntry, values, _a, data, unmatched, min, max, textColor, ramp, noDataColor, borderColor, regionSeriesLabel, seriesName, chartDomains, chartSeries, legend, chartType, position, showAxis, isBubble, isHierarchy, skipHeaders_1, labelValues, perSeriesX, perSeriesSize, seriesInputs, i, seriesEntry, resolvedLabel, _b, xValues, sizeValues_1, sharedXValues, sharedSizeValues, _c, categories_1, preparedSeries, sizeValues, sizeScale_1, xAxisConfig, tooltipFormatter, bubbleSeriesLabel_1, hierarchyRows, headerTitle, hierarchyData, rootName, seriesDisplayName, hierarchyDepth, levels, sizeNumberFormat_1, tooltipFormatter, hierarchyDataLabels, hierarchySeriesLabel, isContour, categories_2, contourSeriesInputs, _d, _e, seriesEntry, dataLabel, _f, _g, values, e_1_1, seriesNames_1, contourPoints, _h, zMin, zMax, contourFormats_1, contourLabel, categories_3, threeDSeriesInputs, _j, _k, seriesEntry, dataLabel, _l, _m, values, e_2_1, seriesNames_2, threeDPalette_1, seriesColorAt_1, categoryAxisLabel, seriesAxisLabel, stackedBar3D_1, threeDFormats_1, threeDTooltipFormatter, threeDSeries, visualMap, xAxis3D, yAxis3D, categoryCount, categoryTotals_1, threeDSeriesInputs_1, threeDSeriesInputs_1_1, entry, isPercent_1, surfacePoints, _o, zMin, zMax, skipHeaders, categories, radarSeriesInputs, _p, _q, seriesEntry, label, values, indicators_1, radarData, radarStyle_1, radarColors_1, radarFormats_1, radarDataLabels_1, radarSeriesLabelFor_1, radarTooltipFormatter, variant_1, categories, seriesValues, stockFormats_1, stockRoleIndex_1, stockFormatFor_1, stockDataLabels_1, stockSeriesLabelFor_1, upColor_1, downColor_1, volumePoints, hasVolume, stockGrid, baseStockXAxis, stockXAxis, volumeYAxis, volumeSeries, stockAxisPointer, candleData, lineSeries, stockColors_1, isStacked, isCircularChart, isOfPie, ofPieLayout, isHorizontalBarChart, shouldAggregate, primaryDomainSource, rawPrimaryDomainValues, aggregateDomainValues, categoryLevels, pushSeriesOverlays, sideBySideBarCount, specBarGap, specBarCategoryGap, seriesPalette, paletteColorAt, _loop_1, _r, _s, _t, specSeriesIndex, series, e_3_1, labels, seriesEntry, rawValues, _u, main_1, secondary, otherTotal, total, ofPieType_1, secondScale, halfAngle_1, hasSecondary, MAIN_CX_1, CY_1, MAIN_RADIUS_PCT_1, SECONDARY_CX_1, secondaryRadiusPct_1, BAR_LEFT_1, BAR_RIGHT, barHalfFrac_1, ofPiePalette_1, paletteAt_1, connectorColor_1, primaryDomainSource_1, rawDomainValues, labels, seriesEntry, rawValues_1, totalIndices, steps, accent_1, decreaseColor_1, totalColor_1, connectors, primaryDomainSource_2, rawDomainValues, labels_1, seriesEntry, rawValues, quartileMethod, showOutliers, showMeanMarker, boxStats, boxLabels, outlierPoints, meanPoints, _v, _w, seriesEntry, label, rawValues, summary, boxIndex, lo, hi, _x, _y, outlier, boxSeries, boxColor, rawValues, _z, labels, counts, isPareto_1, cumulativePercents, pareto, histogramSeries, histogramColor, renderedSeriesCount, replaceMerge, valueAxisBase, isPareto, hasSecondaryAxis, isPercentStackedBars, primaryAxisNumberFormat, secondaryAxisNumberFormat, axisNumberFormatFor, seriesNumberFormats, seriesNumberFormatFor, tooltipConfig, finalLegend, bottomAxisNameGap, legendBand, positionedLegend, gridConfig, dataLabelOptions, seriesLabelOptionFor, isDoughnut, doughnutHoleSize, explosion, explosionOffset, barSeries, len, categoryTotals_2, barSeries_1, barSeries_1_1, s, i, raw, n, barSeries_2, barSeries_2_1, s, seriesWithLabels;
371
371
  var e_1, _0, e_2, _1, e_4, _2, e_5, _3, e_3, _4, e_6, _5, e_7, _6, e_8, _7, e_9, _8;
372
- var _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45, _46, _47, _48, _49, _50, _51, _52, _53, _54, _55, _56, _57, _58, _59, _60, _61, _62, _63, _64, _65, _66, _67, _68, _69, _70, _71, _72, _73, _74, _75, _76, _77, _78, _79, _80, _81, _82, _83, _84, _85, _86, _87, _88, _89, _90, _91, _92, _93, _94, _95, _96, _97, _98, _99, _100, _101, _102, _103, _104, _105, _106, _107, _108, _109, _110, _111, _112, _113, _114, _115, _116, _117, _118, _119, _120, _121, _122, _123, _124, _125, _126, _127, _128, _129, _130, _131, _132, _133, _134, _135, _136, _137, _138;
373
- return tslib_1.__generator(this, function (_139) {
374
- switch (_139.label) {
372
+ var _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45, _46, _47, _48, _49, _50, _51, _52, _53, _54, _55, _56, _57, _58, _59, _60, _61, _62, _63, _64, _65, _66, _67, _68, _69, _70, _71, _72, _73, _74, _75, _76, _77, _78, _79, _80, _81, _82, _83, _84, _85, _86, _87, _88, _89, _90, _91, _92, _93, _94, _95, _96, _97, _98, _99, _100, _101, _102, _103, _104, _105, _106, _107, _108, _109, _110, _111, _112, _113, _114, _115, _116, _117, _118, _119, _120, _121, _122, _123, _124, _125, _126, _127, _128, _129, _130, _131, _132, _133, _134, _135, _136, _137, _138, _139;
373
+ return tslib_1.__generator(this, function (_140) {
374
+ switch (_140.label) {
375
375
  case 0:
376
376
  (0, utils_1.debug)("Updating chart", chart);
377
377
  threeDRenderKind = (0, three_d_1.resolve3DRenderKind)(spec.sourceChartType);
@@ -422,7 +422,7 @@ var BasicChart = function (_a) {
422
422
  geoScope = (0, region_map_1.resolveGeoScope)(regionSpec.geoScope);
423
423
  return [4 /*yield*/, (0, region_map_loader_1.loadRegionMapGeo)(geoScope)];
424
424
  case 1:
425
- geo = _139.sent();
425
+ geo = _140.sent();
426
426
  // Entering the region map from a cartesian render: the previous
427
427
  // grid/axis option doesn't merge into the map one, so start from
428
428
  // a bare instance (theme options are re-applied after setOption).
@@ -457,7 +457,7 @@ var BasicChart = function (_a) {
457
457
  ? "rgba(255,255,255,0.08)"
458
458
  : "rgba(0,0,0,0.06)";
459
459
  borderColor = isDarkMode ? "rgba(255,255,255,0.3)" : "#FFFFFF";
460
- regionSeriesLabel = (0, overrides_1.buildSeriesLabelOption)(spec.dataLabels);
460
+ regionSeriesLabel = (0, overrides_1.buildSeriesLabelOption)(spec.dataLabels, undefined, locale);
461
461
  seriesName = (seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) && !(0, utils_1.isAFormula)(seriesEntry.dataLabel)
462
462
  ? seriesEntry.dataLabel
463
463
  : "";
@@ -537,7 +537,7 @@ var BasicChart = function (_a) {
537
537
  });
538
538
  seriesInputs = [];
539
539
  i = 0;
540
- _139.label = 3;
540
+ _140.label = 3;
541
541
  case 3:
542
542
  if (!(i < spec.series.length)) return [3 /*break*/, 7];
543
543
  seriesEntry = spec.series[i];
@@ -546,13 +546,13 @@ var BasicChart = function (_a) {
546
546
  _b = chart_spec_utils_1.coerceCalculatedLabel;
547
547
  return [4 /*yield*/, onRequestCalculate(resolvedLabel, (_17 = position.sheetId) !== null && _17 !== void 0 ? _17 : sheetId, position.overlayPosition.anchorCell.rowIndex, position.overlayPosition.anchorCell.columnIndex)];
548
548
  case 4:
549
- resolvedLabel = _b.apply(void 0, [_139.sent()]);
550
- _139.label = 5;
549
+ resolvedLabel = _b.apply(void 0, [_140.sent()]);
550
+ _140.label = 5;
551
551
  case 5:
552
552
  xValues = (_18 = perSeriesX[i]) !== null && _18 !== void 0 ? _18 : perSeriesX[0];
553
553
  sizeValues_1 = (_19 = perSeriesSize[i]) !== null && _19 !== void 0 ? _19 : perSeriesSize[0];
554
554
  seriesInputs.push(tslib_1.__assign(tslib_1.__assign({ name: resolvedLabel, values: flattenChartDataValues([seriesEntry], getSeriesValuesFromRange, spec.hiddenDimensionStrategy, skipHeaders_1) }, (xValues ? { xValues: xValues } : {})), (sizeValues_1 ? { sizeValues: sizeValues_1 } : {})));
555
- _139.label = 6;
555
+ _140.label = 6;
556
556
  case 6:
557
557
  i++;
558
558
  return [3 /*break*/, 3];
@@ -590,7 +590,7 @@ var BasicChart = function (_a) {
590
590
  var seriesName = params.seriesName ? "".concat(params.seriesName, "<br/>") : "";
591
591
  return "".concat(seriesName).concat(bubbleName, "X: ").concat(label !== null && label !== void 0 ? label : "", "<br/>Y: ").concat(y !== null && y !== void 0 ? y : "", "<br/>Size: ").concat(size !== null && size !== void 0 ? size : "");
592
592
  };
593
- bubbleSeriesLabel_1 = (0, overrides_1.buildSeriesLabelOption)(spec.dataLabels);
593
+ bubbleSeriesLabel_1 = (0, overrides_1.buildSeriesLabelOption)(spec.dataLabels, undefined, locale);
594
594
  (_24 = chartRef.current) === null || _24 === void 0 ? void 0 : _24.setOption({
595
595
  xAxis: [
596
596
  (0, overrides_1.applyAxisOverrides)(tslib_1.__assign({}, xAxisConfig), spec.categoryAxisOptions),
@@ -601,7 +601,7 @@ var BasicChart = function (_a) {
601
601
  name: (_25 = spec.verticalAxisTitle) !== null && _25 !== void 0 ? _25 : "",
602
602
  nameLocation: "middle",
603
603
  nameGap: 45,
604
- }, spec.valueAxisOptions),
604
+ }, spec.valueAxisOptions, undefined, locale),
605
605
  ],
606
606
  legend: (0, overrides_1.applyLegendOverrides)(tslib_1.__assign(tslib_1.__assign({}, legend), { show: preparedSeries.length > 1, data: preparedSeries.map(function (entry) { return entry.name; }) }), spec.legend),
607
607
  grid: {
@@ -620,7 +620,7 @@ var BasicChart = function (_a) {
620
620
  // routed through the bubble code, producing Y-scaled giant
621
621
  // circles instead of Excel's small dots.
622
622
  series: preparedSeries.map(function (entry, index) {
623
- var _a, _b, _c, _d, _e, _f;
623
+ var _a, _b, _c, _d, _e, _f, _g;
624
624
  var isScatter = spec.chartType === "scatter";
625
625
  var scatterStyle = (_a = spec.scatterStyle) !== null && _a !== void 0 ? _a : (isScatter ? "lineMarker" : undefined);
626
626
  var seriesEntry = (_b = spec.series) === null || _b === void 0 ? void 0 : _b[index];
@@ -639,13 +639,18 @@ var BasicChart = function (_a) {
639
639
  scatterStyle === "smoothMarker" ||
640
640
  !scatterStyle);
641
641
  var smooth = scatterStyle === "smooth" || scatterStyle === "smoothMarker";
642
+ // Labels hang off the point symbols: a marker-less line keeps
643
+ // an invisible 0-size symbol per point when they show (#1049).
644
+ var labelsWithoutMarkers = !wantsMarkers && Boolean((_c = spec.dataLabels) === null || _c === void 0 ? void 0 : _c.show);
642
645
  return wantsLine
643
- ? tslib_1.__assign({ type: "line", name: entry.name, data: entry.points, showSymbol: wantsMarkers, smooth: smooth, symbol: (_c = (0, helpers_1.mapMarkerSymbolToEcharts)(symbol)) !== null && _c !== void 0 ? _c : "circle", symbolSize: (_d = perMarker === null || perMarker === void 0 ? void 0 : perMarker.size) !== null && _d !== void 0 ? _d : 6 }, (seriesColor
646
+ ? tslib_1.__assign({ type: "line", name: entry.name, data: entry.points, showSymbol: wantsMarkers || labelsWithoutMarkers, smooth: smooth, symbol: (_d = (0, helpers_1.mapMarkerSymbolToEcharts)(symbol)) !== null && _d !== void 0 ? _d : "circle", symbolSize: labelsWithoutMarkers
647
+ ? 0
648
+ : (_e = perMarker === null || perMarker === void 0 ? void 0 : perMarker.size) !== null && _e !== void 0 ? _e : 6 }, (seriesColor
644
649
  ? {
645
650
  itemStyle: { color: seriesColor },
646
651
  lineStyle: { color: seriesColor },
647
652
  }
648
- : {})) : tslib_1.__assign({ type: "scatter", name: entry.name, data: entry.points, symbol: (_e = (0, helpers_1.mapMarkerSymbolToEcharts)(symbol)) !== null && _e !== void 0 ? _e : "circle", symbolSize: (_f = perMarker === null || perMarker === void 0 ? void 0 : perMarker.size) !== null && _f !== void 0 ? _f : 6 }, (seriesColor
653
+ : {})) : tslib_1.__assign({ type: "scatter", name: entry.name, data: entry.points, symbol: (_f = (0, helpers_1.mapMarkerSymbolToEcharts)(symbol)) !== null && _f !== void 0 ? _f : "circle", symbolSize: (_g = perMarker === null || perMarker === void 0 ? void 0 : perMarker.size) !== null && _g !== void 0 ? _g : 6 }, (seriesColor
649
654
  ? { itemStyle: { color: seriesColor } }
650
655
  : {}));
651
656
  }
@@ -695,11 +700,11 @@ var BasicChart = function (_a) {
695
700
  var value = Array.isArray(params.value)
696
701
  ? params.value[params.value.length - 1]
697
702
  : (_a = params.value) !== null && _a !== void 0 ? _a : "";
698
- return "".concat(params.name, ": ").concat((0, axis_number_format_1.formatAxisValue)(sizeNumberFormat_1, value));
703
+ return "".concat(params.name, ": ").concat((0, axis_number_format_1.formatAxisValue)(sizeNumberFormat_1, value, locale));
699
704
  };
700
705
  hierarchyDataLabels = spec.dataLabels;
701
706
  hierarchySeriesLabel = (0, overrides_1.buildSeriesLabelOption)(hierarchyDataLabels && !hierarchyDataLabels.numberFormatPattern
702
- ? tslib_1.__assign(tslib_1.__assign({}, hierarchyDataLabels), { numberFormatPattern: sizeNumberFormat_1 }) : hierarchyDataLabels);
707
+ ? tslib_1.__assign(tslib_1.__assign({}, hierarchyDataLabels), { numberFormatPattern: sizeNumberFormat_1 }) : hierarchyDataLabels, undefined, locale);
703
708
  (_32 = chartRef.current) === null || _32 === void 0 ? void 0 : _32.setOption({
704
709
  xAxis: [
705
710
  {
@@ -775,11 +780,11 @@ var BasicChart = function (_a) {
775
780
  if (!isContour) return [3 /*break*/, 19];
776
781
  categories_2 = flattenChartDataValues(spec.domains, getDomainValuesFromRange, spec.hiddenDimensionStrategy, false).map(function (v) { return String(v !== null && v !== void 0 ? v : ""); });
777
782
  contourSeriesInputs = [];
778
- _139.label = 9;
783
+ _140.label = 9;
779
784
  case 9:
780
- _139.trys.push([9, 16, 17, 18]);
785
+ _140.trys.push([9, 16, 17, 18]);
781
786
  _d = tslib_1.__values((_34 = spec.series) !== null && _34 !== void 0 ? _34 : []), _e = _d.next();
782
- _139.label = 10;
787
+ _140.label = 10;
783
788
  case 10:
784
789
  if (!!_e.done) return [3 /*break*/, 15];
785
790
  seriesEntry = _e.value;
@@ -787,22 +792,22 @@ var BasicChart = function (_a) {
787
792
  _g = chart_spec_utils_1.coerceCalculatedLabel;
788
793
  return [4 /*yield*/, onRequestCalculate(seriesEntry.dataLabel, (_35 = position.sheetId) !== null && _35 !== void 0 ? _35 : sheetId, position.overlayPosition.anchorCell.rowIndex, position.overlayPosition.anchorCell.columnIndex)];
789
794
  case 11:
790
- _f = _g.apply(void 0, [_139.sent()]);
795
+ _f = _g.apply(void 0, [_140.sent()]);
791
796
  return [3 /*break*/, 13];
792
797
  case 12:
793
798
  _f = (_36 = seriesEntry.dataLabel) !== null && _36 !== void 0 ? _36 : "";
794
- _139.label = 13;
799
+ _140.label = 13;
795
800
  case 13:
796
801
  dataLabel = _f;
797
802
  values = flattenChartDataValues([seriesEntry], getSeriesValuesFromRange, spec.hiddenDimensionStrategy).map(sanitizeChartValue);
798
803
  contourSeriesInputs.push({ name: dataLabel, values: values });
799
- _139.label = 14;
804
+ _140.label = 14;
800
805
  case 14:
801
806
  _e = _d.next();
802
807
  return [3 /*break*/, 10];
803
808
  case 15: return [3 /*break*/, 18];
804
809
  case 16:
805
- e_1_1 = _139.sent();
810
+ e_1_1 = _140.sent();
806
811
  e_1 = { error: e_1_1 };
807
812
  return [3 /*break*/, 18];
808
813
  case 17:
@@ -818,7 +823,7 @@ var BasicChart = function (_a) {
818
823
  return typeof point[2] === "number";
819
824
  })), 2), zMin = _h[0], zMax = _h[1];
820
825
  contourFormats_1 = (0, axis_number_format_1.resolveSeriesNumberFormats)(spec.series, getFormattingFromRange, spec.hiddenDimensionStrategy);
821
- contourLabel = (0, overrides_1.buildSeriesLabelOption)(spec.dataLabels);
826
+ contourLabel = (0, overrides_1.buildSeriesLabelOption)(spec.dataLabels, undefined, locale);
822
827
  if (!renderedAsContour.current && chartRef.current) {
823
828
  chartRef.current.dispose();
824
829
  chartRef.current = undefined;
@@ -836,7 +841,7 @@ var BasicChart = function (_a) {
836
841
  var _d = tslib_1.__read(((_a = params === null || params === void 0 ? void 0 : params.value) !== null && _a !== void 0 ? _a : []), 3), x = _d[0], y = _d[1], z = _d[2];
837
842
  var value = z === "-" || z === undefined
838
843
  ? ""
839
- : (0, axis_number_format_1.formatAxisValue)(contourFormats_1[y], z);
844
+ : (0, axis_number_format_1.formatAxisValue)(contourFormats_1[y], z, locale);
840
845
  return "".concat((_b = seriesNames_1[y]) !== null && _b !== void 0 ? _b : "", "<br/>").concat((_c = categories_2[x]) !== null && _c !== void 0 ? _c : "", ": ").concat(value);
841
846
  },
842
847
  },
@@ -873,7 +878,7 @@ var BasicChart = function (_a) {
873
878
  top: "center",
874
879
  inRange: { color: tslib_1.__spreadArray([], tslib_1.__read(three_d_1.SURFACE_COLOR_RAMP), false) },
875
880
  formatter: function (value) {
876
- return (0, axis_number_format_1.formatAxisValue)(contourFormats_1[0], value);
881
+ return (0, axis_number_format_1.formatAxisValue)(contourFormats_1[0], value, locale);
877
882
  },
878
883
  },
879
884
  ],
@@ -885,7 +890,7 @@ var BasicChart = function (_a) {
885
890
  var _b = tslib_1.__read(((_a = params === null || params === void 0 ? void 0 : params.value) !== null && _a !== void 0 ? _a : []), 3), y = _b[1], z = _b[2];
886
891
  return z === "-" || z === undefined
887
892
  ? ""
888
- : (0, axis_number_format_1.formatAxisValue)(contourFormats_1[y], z);
893
+ : (0, axis_number_format_1.formatAxisValue)(contourFormats_1[y], z, locale);
889
894
  } }),
890
895
  }
891
896
  : {})),
@@ -910,11 +915,11 @@ var BasicChart = function (_a) {
910
915
  if (!(willRender3D && threeDRenderKind)) return [3 /*break*/, 30];
911
916
  categories_3 = flattenChartDataValues(spec.domains, getDomainValuesFromRange, spec.hiddenDimensionStrategy, false).map(function (v) { return String(v !== null && v !== void 0 ? v : ""); });
912
917
  threeDSeriesInputs = [];
913
- _139.label = 20;
918
+ _140.label = 20;
914
919
  case 20:
915
- _139.trys.push([20, 27, 28, 29]);
920
+ _140.trys.push([20, 27, 28, 29]);
916
921
  _j = tslib_1.__values((_40 = spec.series) !== null && _40 !== void 0 ? _40 : []), _k = _j.next();
917
- _139.label = 21;
922
+ _140.label = 21;
918
923
  case 21:
919
924
  if (!!_k.done) return [3 /*break*/, 26];
920
925
  seriesEntry = _k.value;
@@ -922,22 +927,22 @@ var BasicChart = function (_a) {
922
927
  _m = chart_spec_utils_1.coerceCalculatedLabel;
923
928
  return [4 /*yield*/, onRequestCalculate(seriesEntry.dataLabel, (_41 = position.sheetId) !== null && _41 !== void 0 ? _41 : sheetId, position.overlayPosition.anchorCell.rowIndex, position.overlayPosition.anchorCell.columnIndex)];
924
929
  case 22:
925
- _l = _m.apply(void 0, [_139.sent()]);
930
+ _l = _m.apply(void 0, [_140.sent()]);
926
931
  return [3 /*break*/, 24];
927
932
  case 23:
928
933
  _l = (_42 = seriesEntry.dataLabel) !== null && _42 !== void 0 ? _42 : "";
929
- _139.label = 24;
934
+ _140.label = 24;
930
935
  case 24:
931
936
  dataLabel = _l;
932
937
  values = flattenChartDataValues([seriesEntry], getSeriesValuesFromRange, spec.hiddenDimensionStrategy).map(sanitizeChartValue);
933
938
  threeDSeriesInputs.push({ name: dataLabel, values: values });
934
- _139.label = 25;
939
+ _140.label = 25;
935
940
  case 25:
936
941
  _k = _j.next();
937
942
  return [3 /*break*/, 21];
938
943
  case 26: return [3 /*break*/, 29];
939
944
  case 27:
940
- e_2_1 = _139.sent();
945
+ e_2_1 = _140.sent();
941
946
  e_2 = { error: e_2_1 };
942
947
  return [3 /*break*/, 29];
943
948
  case 28:
@@ -991,7 +996,7 @@ var BasicChart = function (_a) {
991
996
  : (_j = (_h = seriesNames_2[Math.round((_g = value[1]) !== null && _g !== void 0 ? _g : 0)]) !== null && _h !== void 0 ? _h : params === null || params === void 0 ? void 0 : params.seriesName) !== null && _j !== void 0 ? _j : "";
992
997
  var valueLabel = spec.stackedType === "PERCENT_STACKED" && stackedBar3D_1
993
998
  ? "".concat(Math.round(((_k = value[2]) !== null && _k !== void 0 ? _k : 0) * 10) / 10, "%")
994
- : (0, axis_number_format_1.formatAxisValue)(threeDFormats_1[seriesIndex], value[2]);
999
+ : (0, axis_number_format_1.formatAxisValue)(threeDFormats_1[seriesIndex], value[2], locale);
995
1000
  return "".concat(seriesLabel ? "".concat(seriesLabel, "<br/>") : "").concat(categoryLabel, ": ").concat(valueLabel);
996
1001
  };
997
1002
  threeDSeries = void 0;
@@ -1166,14 +1171,14 @@ var BasicChart = function (_a) {
1166
1171
  radarDataLabels_1 = spec.dataLabels;
1167
1172
  radarSeriesLabelFor_1 = function (seriesIndex) {
1168
1173
  return (0, overrides_1.buildSeriesLabelOption)(radarDataLabels_1 && !radarDataLabels_1.numberFormatPattern
1169
- ? tslib_1.__assign(tslib_1.__assign({}, radarDataLabels_1), { numberFormatPattern: radarFormats_1[seriesIndex] }) : radarDataLabels_1);
1174
+ ? tslib_1.__assign(tslib_1.__assign({}, radarDataLabels_1), { numberFormatPattern: radarFormats_1[seriesIndex] }) : radarDataLabels_1, undefined, locale);
1170
1175
  };
1171
1176
  radarTooltipFormatter = function (params) {
1172
1177
  var _a, _b;
1173
1178
  var values = Array.isArray(params === null || params === void 0 ? void 0 : params.value) ? params.value : [];
1174
1179
  var pattern = radarFormats_1[(_a = params === null || params === void 0 ? void 0 : params.dataIndex) !== null && _a !== void 0 ? _a : 0];
1175
1180
  var lines = indicators_1.map(function (indicator, i) {
1176
- return "".concat(indicator.name, ": ").concat((0, axis_number_format_1.formatAxisValue)(pattern, values[i]));
1181
+ return "".concat(indicator.name, ": ").concat((0, axis_number_format_1.formatAxisValue)(pattern, values[i], locale));
1177
1182
  });
1178
1183
  return tslib_1.__spreadArray([(_b = params === null || params === void 0 ? void 0 : params.name) !== null && _b !== void 0 ? _b : ""], tslib_1.__read(lines), false).filter(Boolean).join("<br/>");
1179
1184
  };
@@ -1235,7 +1240,7 @@ var BasicChart = function (_a) {
1235
1240
  stockDataLabels_1 = spec.dataLabels;
1236
1241
  stockSeriesLabelFor_1 = function (role) {
1237
1242
  return (0, overrides_1.buildSeriesLabelOption)(stockDataLabels_1 && !stockDataLabels_1.numberFormatPattern
1238
- ? tslib_1.__assign(tslib_1.__assign({}, stockDataLabels_1), { numberFormatPattern: stockFormatFor_1(role) }) : stockDataLabels_1);
1243
+ ? tslib_1.__assign(tslib_1.__assign({}, stockDataLabels_1), { numberFormatPattern: stockFormatFor_1(role) }) : stockDataLabels_1, undefined, locale);
1239
1244
  };
1240
1245
  upColor_1 = theme.themeColors.accent1;
1241
1246
  downColor_1 = theme.themeColors.accent2;
@@ -1279,10 +1284,10 @@ var BasicChart = function (_a) {
1279
1284
  tslib_1.__assign({ type: "bar", name: "Volume", xAxisIndex: 1, yAxisIndex: 1, data: (volumePoints !== null && volumePoints !== void 0 ? volumePoints : []).map(function (p) { return ({
1280
1285
  value: p.value,
1281
1286
  itemStyle: { color: p.up ? upColor_1 : downColor_1 },
1282
- }); }) }, ((0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("volume"))
1287
+ }); }) }, ((0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("volume"), locale)
1283
1288
  ? {
1284
1289
  tooltip: {
1285
- valueFormatter: (0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("volume")),
1290
+ valueFormatter: (0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("volume"), locale),
1286
1291
  },
1287
1292
  }
1288
1293
  : {})),
@@ -1307,7 +1312,7 @@ var BasicChart = function (_a) {
1307
1312
  nameLocation: "middle",
1308
1313
  nameGap: 50,
1309
1314
  gridIndex: 0,
1310
- }, spec.valueAxisOptions)
1315
+ }, spec.valueAxisOptions, undefined, locale)
1311
1316
  ], tslib_1.__read((hasVolume ? [volumeYAxis] : [])), false),
1312
1317
  legend: (0, overrides_1.applyLegendOverrides)(tslib_1.__assign(tslib_1.__assign({}, legend), { show: false }), spec.legend),
1313
1318
  grid: stockGrid,
@@ -1319,10 +1324,10 @@ var BasicChart = function (_a) {
1319
1324
  color0: downColor_1,
1320
1325
  borderColor: upColor_1,
1321
1326
  borderColor0: downColor_1,
1322
- } }, ((0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("close"))
1327
+ } }, ((0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("close"), locale)
1323
1328
  ? {
1324
1329
  tooltip: {
1325
- valueFormatter: (0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("close")),
1330
+ valueFormatter: (0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1("close"), locale),
1326
1331
  },
1327
1332
  }
1328
1333
  : {}))
@@ -1358,7 +1363,7 @@ var BasicChart = function (_a) {
1358
1363
  nameLocation: "middle",
1359
1364
  nameGap: 50,
1360
1365
  gridIndex: 0,
1361
- }, spec.valueAxisOptions)
1366
+ }, spec.valueAxisOptions, undefined, locale)
1362
1367
  ], tslib_1.__read((hasVolume ? [volumeYAxis] : [])), false),
1363
1368
  legend: (0, overrides_1.applyLegendOverrides)(tslib_1.__assign(tslib_1.__assign({}, legend), { show: lineSeries.length > 1, data: lineSeries.map(function (s) { return s.name; }) }), spec.legend),
1364
1369
  grid: stockGrid,
@@ -1366,10 +1371,10 @@ var BasicChart = function (_a) {
1366
1371
  axisPointer: stockAxisPointer,
1367
1372
  series: tslib_1.__spreadArray(tslib_1.__spreadArray([], tslib_1.__read(lineSeries.map(function (s, i) { return (tslib_1.__assign(tslib_1.__assign({ type: "line", name: s.name, data: s.values, showSymbol: false, itemStyle: { color: (0, utils_1.chartPaletteColorAt)(stockColors_1, i) }, lineStyle: { color: (0, utils_1.chartPaletteColorAt)(stockColors_1, i) } }, (stockSeriesLabelFor_1(s.role)
1368
1373
  ? { label: stockSeriesLabelFor_1(s.role) }
1369
- : {})), ((0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1(s.role))
1374
+ : {})), ((0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1(s.role), locale)
1370
1375
  ? {
1371
1376
  tooltip: {
1372
- valueFormatter: (0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1(s.role)),
1377
+ valueFormatter: (0, axis_number_format_1.tooltipValueFormatter)(stockFormatFor_1(s.role), locale),
1373
1378
  },
1374
1379
  }
1375
1380
  : {}))); })), false), tslib_1.__read(volumeSeries), false),
@@ -1627,22 +1632,22 @@ var BasicChart = function (_a) {
1627
1632
  return (0, utils_1.chartPaletteColorAt)(seriesPalette, index);
1628
1633
  };
1629
1634
  _loop_1 = function (specSeriesIndex, series) {
1630
- var dataLabel, _140, _141, effectiveChartType, lineLike, domainSources, pieDomainLabels, piePointOffset, data, seriesEchartsType, seriesStyleAttrs, seriesEntry, isBarOrColumn, seriesAny, markerSymbol, wantsMarkers, isolated, marked, isolated_1, isolated_1_1, i, gradientArgs, gradient, overrides_2, _142, _143, dp, fallback_1, overrides_3, _144, _145, dp, positiveColor_1, negativeColor_1;
1631
- var e_11, _146, e_12, _147, e_13, _148;
1632
- return tslib_1.__generator(this, function (_149) {
1633
- switch (_149.label) {
1635
+ var dataLabel, _141, _142, effectiveChartType, lineLike, domainSources, pieDomainLabels, piePointOffset, data, seriesEchartsType, seriesStyleAttrs, seriesEntry, isBarOrColumn, seriesAny, markerSymbol, wantsMarkers, labelsWithoutMarkers, isolated, marked, isolated_1, isolated_1_1, i, gradientArgs, gradient, overrides_2, _143, _144, dp, fallback_1, overrides_3, _145, _146, dp, positiveColor_1, negativeColor_1;
1636
+ var e_11, _147, e_12, _148, e_13, _149;
1637
+ return tslib_1.__generator(this, function (_150) {
1638
+ switch (_150.label) {
1634
1639
  case 0:
1635
1640
  if (!(!(0, utils_1.isNil)(series.dataLabel) && (0, utils_1.isAFormula)(series.dataLabel))) return [3 /*break*/, 2];
1636
- _141 = chart_spec_utils_1.coerceCalculatedLabel;
1641
+ _142 = chart_spec_utils_1.coerceCalculatedLabel;
1637
1642
  return [4 /*yield*/, onRequestCalculate(series.dataLabel, (_69 = position.sheetId) !== null && _69 !== void 0 ? _69 : sheetId, position.overlayPosition.anchorCell.rowIndex, position.overlayPosition.anchorCell.columnIndex)];
1638
1643
  case 1:
1639
- _140 = _141.apply(void 0, [_149.sent()]);
1644
+ _141 = _142.apply(void 0, [_150.sent()]);
1640
1645
  return [3 /*break*/, 3];
1641
1646
  case 2:
1642
- _140 = (_70 = series.dataLabel) !== null && _70 !== void 0 ? _70 : "";
1643
- _149.label = 3;
1647
+ _141 = (_70 = series.dataLabel) !== null && _70 !== void 0 ? _70 : "";
1648
+ _150.label = 3;
1644
1649
  case 3:
1645
- dataLabel = _140;
1650
+ dataLabel = _141;
1646
1651
  // Label
1647
1652
  if (dataLabel) {
1648
1653
  (_71 = legend.data) === null || _71 === void 0 ? void 0 : _71.push(dataLabel);
@@ -1710,41 +1715,49 @@ var BasicChart = function (_a) {
1710
1715
  wantsMarkers = markerSymbol === "none"
1711
1716
  ? false
1712
1717
  : Boolean(spec.showMarkers) || !(0, utils_1.isNil)(markerSymbol);
1713
- seriesEntry.showSymbol = wantsMarkers;
1718
+ labelsWithoutMarkers = !wantsMarkers && Boolean((_79 = spec.dataLabels) === null || _79 === void 0 ? void 0 : _79.show);
1719
+ seriesEntry.showSymbol = wantsMarkers || labelsWithoutMarkers;
1714
1720
  if (wantsMarkers) {
1715
1721
  seriesEntry.symbol =
1716
- (_79 = (0, helpers_1.mapMarkerSymbolToEcharts)(markerSymbol)) !== null && _79 !== void 0 ? _79 : "circle";
1717
- seriesEntry.symbolSize = (_81 = (_80 = seriesAny.marker) === null || _80 === void 0 ? void 0 : _80.size) !== null && _81 !== void 0 ? _81 : 6;
1722
+ (_80 = (0, helpers_1.mapMarkerSymbolToEcharts)(markerSymbol)) !== null && _80 !== void 0 ? _80 : "circle";
1723
+ seriesEntry.symbolSize = (_82 = (_81 = seriesAny.marker) === null || _81 === void 0 ? void 0 : _81.size) !== null && _82 !== void 0 ? _82 : 6;
1718
1724
  }
1719
- else if (Array.isArray(data)) {
1720
- isolated = (0, empty_cells_1.isolatedPointIndexes)(data, (0, empty_cells_1.connectsAcrossEmptyCells)(spec, lineLike));
1721
- if (isolated.length) {
1722
- seriesEntry.showSymbol = true;
1723
- seriesEntry.symbol = "none";
1724
- marked = tslib_1.__spreadArray([], tslib_1.__read(data), false);
1725
- try {
1726
- for (isolated_1 = (e_11 = void 0, tslib_1.__values(isolated)), isolated_1_1 = isolated_1.next(); !isolated_1_1.done; isolated_1_1 = isolated_1.next()) {
1727
- i = isolated_1_1.value;
1728
- marked[i] = { value: marked[i], symbol: "circle", symbolSize: 6 };
1729
- }
1730
- }
1731
- catch (e_11_1) { e_11 = { error: e_11_1 }; }
1732
- finally {
1725
+ else {
1726
+ if (labelsWithoutMarkers) {
1727
+ seriesEntry.symbol = "circle";
1728
+ seriesEntry.symbolSize = 0;
1729
+ }
1730
+ if (Array.isArray(data)) {
1731
+ isolated = (0, empty_cells_1.isolatedPointIndexes)(data, (0, empty_cells_1.connectsAcrossEmptyCells)(spec, lineLike));
1732
+ if (isolated.length) {
1733
+ seriesEntry.showSymbol = true;
1734
+ if (!labelsWithoutMarkers)
1735
+ seriesEntry.symbol = "none";
1736
+ marked = tslib_1.__spreadArray([], tslib_1.__read(data), false);
1733
1737
  try {
1734
- if (isolated_1_1 && !isolated_1_1.done && (_146 = isolated_1.return)) _146.call(isolated_1);
1738
+ for (isolated_1 = (e_11 = void 0, tslib_1.__values(isolated)), isolated_1_1 = isolated_1.next(); !isolated_1_1.done; isolated_1_1 = isolated_1.next()) {
1739
+ i = isolated_1_1.value;
1740
+ marked[i] = { value: marked[i], symbol: "circle", symbolSize: 6 };
1741
+ }
1742
+ }
1743
+ catch (e_11_1) { e_11 = { error: e_11_1 }; }
1744
+ finally {
1745
+ try {
1746
+ if (isolated_1_1 && !isolated_1_1.done && (_147 = isolated_1.return)) _147.call(isolated_1);
1747
+ }
1748
+ finally { if (e_11) throw e_11.error; }
1735
1749
  }
1736
- finally { if (e_11) throw e_11.error; }
1750
+ seriesEntry.data = marked;
1737
1751
  }
1738
- seriesEntry.data = marked;
1739
1752
  }
1740
1753
  }
1741
1754
  }
1742
1755
  gradientArgs = (0, gradient_1.gradientToEcharts)(series.gradient);
1743
1756
  if (gradientArgs && !seriesAny.noFill) {
1744
1757
  gradient = new echarts.graphic.LinearGradient(gradientArgs.x, gradientArgs.y, gradientArgs.x2, gradientArgs.y2, gradientArgs.colorStops);
1745
- seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_82 = seriesEntry.itemStyle) !== null && _82 !== void 0 ? _82 : {})), { color: gradient });
1758
+ seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_83 = seriesEntry.itemStyle) !== null && _83 !== void 0 ? _83 : {})), { color: gradient });
1746
1759
  if (effectiveChartType === "area") {
1747
- seriesEntry.areaStyle = tslib_1.__assign(tslib_1.__assign({}, ((_83 = seriesEntry.areaStyle) !== null && _83 !== void 0 ? _83 : {})), { color: gradient });
1760
+ seriesEntry.areaStyle = tslib_1.__assign(tslib_1.__assign({}, ((_84 = seriesEntry.areaStyle) !== null && _84 !== void 0 ? _84 : {})), { color: gradient });
1748
1761
  }
1749
1762
  }
1750
1763
  else if (seriesAny.noFill) {
@@ -1752,15 +1765,15 @@ var BasicChart = function (_a) {
1752
1765
  // with `transparent` so layout is preserved but nothing
1753
1766
  // paints. Legend entries are also suppressed via `name: ""`
1754
1767
  // since the series carries no semantic information.
1755
- seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_84 = seriesEntry.itemStyle) !== null && _84 !== void 0 ? _84 : {})), { color: "transparent", borderColor: "transparent" });
1768
+ seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_85 = seriesEntry.itemStyle) !== null && _85 !== void 0 ? _85 : {})), { color: "transparent", borderColor: "transparent" });
1756
1769
  }
1757
1770
  else if (isBarOrColumn &&
1758
1771
  Array.isArray(seriesAny.dataPointColors) &&
1759
1772
  seriesAny.dataPointColors.length) {
1760
1773
  overrides_2 = new Map();
1761
1774
  try {
1762
- for (_142 = (e_12 = void 0, tslib_1.__values(seriesAny.dataPointColors)), _143 = _142.next(); !_143.done; _143 = _142.next()) {
1763
- dp = _143.value;
1775
+ for (_143 = (e_12 = void 0, tslib_1.__values(seriesAny.dataPointColors)), _144 = _143.next(); !_144.done; _144 = _143.next()) {
1776
+ dp = _144.value;
1764
1777
  if (typeof dp.idx === "number" && typeof dp.color === "string") {
1765
1778
  overrides_2.set(dp.idx, dp.color);
1766
1779
  }
@@ -1769,20 +1782,20 @@ var BasicChart = function (_a) {
1769
1782
  catch (e_12_1) { e_12 = { error: e_12_1 }; }
1770
1783
  finally {
1771
1784
  try {
1772
- if (_143 && !_143.done && (_147 = _142.return)) _147.call(_142);
1785
+ if (_144 && !_144.done && (_148 = _143.return)) _148.call(_143);
1773
1786
  }
1774
1787
  finally { if (e_12) throw e_12.error; }
1775
1788
  }
1776
- fallback_1 = (_85 = series.color) !== null && _85 !== void 0 ? _85 : paletteColorAt(specSeriesIndex);
1777
- seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_86 = seriesEntry.itemStyle) !== null && _86 !== void 0 ? _86 : {})), { color: function (params) { var _a; return (_a = overrides_2.get(params.dataIndex)) !== null && _a !== void 0 ? _a : fallback_1; } });
1789
+ fallback_1 = (_86 = series.color) !== null && _86 !== void 0 ? _86 : paletteColorAt(specSeriesIndex);
1790
+ seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_87 = seriesEntry.itemStyle) !== null && _87 !== void 0 ? _87 : {})), { color: function (params) { var _a; return (_a = overrides_2.get(params.dataIndex)) !== null && _a !== void 0 ? _a : fallback_1; } });
1778
1791
  }
1779
1792
  else if (isCircularChart &&
1780
1793
  Array.isArray(seriesAny.dataPointColors) &&
1781
1794
  seriesAny.dataPointColors.length) {
1782
1795
  overrides_3 = new Map();
1783
1796
  try {
1784
- for (_144 = (e_13 = void 0, tslib_1.__values(seriesAny.dataPointColors)), _145 = _144.next(); !_145.done; _145 = _144.next()) {
1785
- dp = _145.value;
1797
+ for (_145 = (e_13 = void 0, tslib_1.__values(seriesAny.dataPointColors)), _146 = _145.next(); !_146.done; _146 = _145.next()) {
1798
+ dp = _146.value;
1786
1799
  if (typeof dp.idx === "number" && typeof dp.color === "string") {
1787
1800
  overrides_3.set(dp.idx, dp.color);
1788
1801
  }
@@ -1791,19 +1804,19 @@ var BasicChart = function (_a) {
1791
1804
  catch (e_13_1) { e_13 = { error: e_13_1 }; }
1792
1805
  finally {
1793
1806
  try {
1794
- if (_145 && !_145.done && (_148 = _144.return)) _148.call(_144);
1807
+ if (_146 && !_146.done && (_149 = _145.return)) _149.call(_145);
1795
1808
  }
1796
1809
  finally { if (e_13) throw e_13.error; }
1797
1810
  }
1798
- seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_87 = seriesEntry.itemStyle) !== null && _87 !== void 0 ? _87 : {})), { color: function (params) {
1811
+ seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_88 = seriesEntry.itemStyle) !== null && _88 !== void 0 ? _88 : {})), { color: function (params) {
1799
1812
  var _a, _b;
1800
1813
  return (_b = (_a = overrides_3.get(params.dataIndex)) !== null && _a !== void 0 ? _a : series.color) !== null && _b !== void 0 ? _b : paletteColorAt(params.dataIndex);
1801
1814
  } });
1802
1815
  }
1803
1816
  else if (isBarOrColumn && series.invertIfNegative) {
1804
- positiveColor_1 = (_88 = series.color) !== null && _88 !== void 0 ? _88 : paletteColorAt(specSeriesIndex);
1805
- negativeColor_1 = (_89 = series.negativeColor) !== null && _89 !== void 0 ? _89 : "#FF0000";
1806
- seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_90 = seriesEntry.itemStyle) !== null && _90 !== void 0 ? _90 : {})), { color: function (params) {
1817
+ positiveColor_1 = (_89 = series.color) !== null && _89 !== void 0 ? _89 : paletteColorAt(specSeriesIndex);
1818
+ negativeColor_1 = (_90 = series.negativeColor) !== null && _90 !== void 0 ? _90 : "#FF0000";
1819
+ seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_91 = seriesEntry.itemStyle) !== null && _91 !== void 0 ? _91 : {})), { color: function (params) {
1807
1820
  var _a, _b;
1808
1821
  var value = Array.isArray(params.data)
1809
1822
  ? params.data[1]
@@ -1814,10 +1827,10 @@ var BasicChart = function (_a) {
1814
1827
  } });
1815
1828
  }
1816
1829
  else if (series.color) {
1817
- seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_91 = seriesEntry.itemStyle) !== null && _91 !== void 0 ? _91 : {})), { color: series.color });
1818
- seriesEntry.lineStyle = tslib_1.__assign(tslib_1.__assign({}, ((_92 = seriesEntry.lineStyle) !== null && _92 !== void 0 ? _92 : {})), { color: series.color });
1830
+ seriesEntry.itemStyle = tslib_1.__assign(tslib_1.__assign({}, ((_92 = seriesEntry.itemStyle) !== null && _92 !== void 0 ? _92 : {})), { color: series.color });
1831
+ seriesEntry.lineStyle = tslib_1.__assign(tslib_1.__assign({}, ((_93 = seriesEntry.lineStyle) !== null && _93 !== void 0 ? _93 : {})), { color: series.color });
1819
1832
  if (effectiveChartType === "area") {
1820
- seriesEntry.areaStyle = tslib_1.__assign(tslib_1.__assign({}, ((_93 = seriesEntry.areaStyle) !== null && _93 !== void 0 ? _93 : {})), { color: series.color });
1833
+ seriesEntry.areaStyle = tslib_1.__assign(tslib_1.__assign({}, ((_94 = seriesEntry.areaStyle) !== null && _94 !== void 0 ? _94 : {})), { color: series.color });
1821
1834
  }
1822
1835
  }
1823
1836
  chartSeries.push(seriesEntry);
@@ -1826,24 +1839,24 @@ var BasicChart = function (_a) {
1826
1839
  }
1827
1840
  });
1828
1841
  };
1829
- _139.label = 31;
1842
+ _140.label = 31;
1830
1843
  case 31:
1831
- _139.trys.push([31, 36, 37, 38]);
1844
+ _140.trys.push([31, 36, 37, 38]);
1832
1845
  _r = tslib_1.__values(((_68 = spec.series) !== null && _68 !== void 0 ? _68 : []).entries()), _s = _r.next();
1833
- _139.label = 32;
1846
+ _140.label = 32;
1834
1847
  case 32:
1835
1848
  if (!!_s.done) return [3 /*break*/, 35];
1836
1849
  _t = tslib_1.__read(_s.value, 2), specSeriesIndex = _t[0], series = _t[1];
1837
1850
  return [5 /*yield**/, _loop_1(specSeriesIndex, series)];
1838
1851
  case 33:
1839
- _139.sent();
1840
- _139.label = 34;
1852
+ _140.sent();
1853
+ _140.label = 34;
1841
1854
  case 34:
1842
1855
  _s = _r.next();
1843
1856
  return [3 /*break*/, 32];
1844
1857
  case 35: return [3 /*break*/, 38];
1845
1858
  case 36:
1846
- e_3_1 = _139.sent();
1859
+ e_3_1 = _140.sent();
1847
1860
  e_3 = { error: e_3_1 };
1848
1861
  return [3 /*break*/, 38];
1849
1862
  case 37:
@@ -1861,7 +1874,7 @@ var BasicChart = function (_a) {
1861
1874
  }
1862
1875
  if (isOfPie) {
1863
1876
  labels = rawPrimaryDomainValues.map(function (v) { return String(v !== null && v !== void 0 ? v : ""); });
1864
- seriesEntry = (_94 = spec.series) === null || _94 === void 0 ? void 0 : _94[0];
1877
+ seriesEntry = (_95 = spec.series) === null || _95 === void 0 ? void 0 : _95[0];
1865
1878
  rawValues = seriesEntry
1866
1879
  ? flattenChartDataValues([seriesEntry], getSeriesValuesFromRange, spec.hiddenDimensionStrategy).map(function (v) { return (typeof v === "number" ? v : Number(v)); })
1867
1880
  : [];
@@ -1908,7 +1921,7 @@ var BasicChart = function (_a) {
1908
1921
  };
1909
1922
  chartSeries.push({
1910
1923
  type: "pie",
1911
- name: (_95 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _95 !== void 0 ? _95 : "",
1924
+ name: (_96 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _96 !== void 0 ? _96 : "",
1912
1925
  center: ["".concat(MAIN_CX_1 * 100, "%"), "".concat(CY_1 * 100, "%")],
1913
1926
  radius: [0, "".concat(MAIN_RADIUS_PCT_1, "%")],
1914
1927
  // Rotate the pie so the "Other" slice's angular midpoint faces
@@ -1926,7 +1939,7 @@ var BasicChart = function (_a) {
1926
1939
  if (ofPieType_1 === "pie") {
1927
1940
  chartSeries.push({
1928
1941
  type: "pie",
1929
- name: (_96 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _96 !== void 0 ? _96 : "",
1942
+ name: (_97 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _97 !== void 0 ? _97 : "",
1930
1943
  center: ["".concat(SECONDARY_CX_1 * 100, "%"), "".concat(CY_1 * 100, "%")],
1931
1944
  radius: [0, "".concat(secondaryRadiusPct_1, "%")],
1932
1945
  data: secondary.map(function (s, i) { return ({
@@ -2021,16 +2034,16 @@ var BasicChart = function (_a) {
2021
2034
  legend.data = tslib_1.__spreadArray(tslib_1.__spreadArray([], tslib_1.__read(main_1.map(function (s) { return s.label; })), false), tslib_1.__read(secondary.map(function (s) { return s.label; })), false);
2022
2035
  }
2023
2036
  else if (spec.chartType === "waterfall") {
2024
- primaryDomainSource_1 = (_99 = (_98 = (_97 = spec === null || spec === void 0 ? void 0 : spec.domains) === null || _97 === void 0 ? void 0 : _97[0]) === null || _98 === void 0 ? void 0 : _98.sources) === null || _99 === void 0 ? void 0 : _99[0];
2037
+ primaryDomainSource_1 = (_100 = (_99 = (_98 = spec === null || spec === void 0 ? void 0 : spec.domains) === null || _98 === void 0 ? void 0 : _98[0]) === null || _99 === void 0 ? void 0 : _99.sources) === null || _100 === void 0 ? void 0 : _100[0];
2025
2038
  rawDomainValues = primaryDomainSource_1
2026
- ? (0, aggregation_1.sanitizeDomainValues)((_100 = getDomainValuesFromRange(primaryDomainSource_1, spec.hiddenDimensionStrategy)) !== null && _100 !== void 0 ? _100 : [])
2039
+ ? (0, aggregation_1.sanitizeDomainValues)((_101 = getDomainValuesFromRange(primaryDomainSource_1, spec.hiddenDimensionStrategy)) !== null && _101 !== void 0 ? _101 : [])
2027
2040
  : [];
2028
2041
  labels = rawDomainValues.map(function (v) { return String(v !== null && v !== void 0 ? v : ""); });
2029
- seriesEntry = (_101 = spec.series) === null || _101 === void 0 ? void 0 : _101[0];
2042
+ seriesEntry = (_102 = spec.series) === null || _102 === void 0 ? void 0 : _102[0];
2030
2043
  rawValues_1 = seriesEntry
2031
2044
  ? flattenChartDataValues([seriesEntry], getSeriesValuesFromRange, spec.hiddenDimensionStrategy).map(function (v) { return (typeof v === "number" ? v : Number(v)); })
2032
2045
  : [];
2033
- totalIndices = new Set((_102 = spec.totalIndices) !== null && _102 !== void 0 ? _102 : []);
2046
+ totalIndices = new Set((_103 = spec.totalIndices) !== null && _103 !== void 0 ? _103 : []);
2034
2047
  steps = (0, waterfall_1.computeWaterfall)(rawValues_1, labels, totalIndices);
2035
2048
  chartDomains.length = 0;
2036
2049
  chartDomains.push({
@@ -2040,7 +2053,7 @@ var BasicChart = function (_a) {
2040
2053
  axisLine: { show: true },
2041
2054
  axisTick: { show: true },
2042
2055
  splitLine: { show: false },
2043
- name: (_103 = spec.horizontalAxisTitle) !== null && _103 !== void 0 ? _103 : "",
2056
+ name: (_104 = spec.horizontalAxisTitle) !== null && _104 !== void 0 ? _104 : "",
2044
2057
  nameLocation: "middle",
2045
2058
  nameGap: 30,
2046
2059
  });
@@ -2053,9 +2066,9 @@ var BasicChart = function (_a) {
2053
2066
  data: steps.map(function (s) { return s.placeholder; }),
2054
2067
  silent: true,
2055
2068
  });
2056
- accent_1 = (_104 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.color) !== null && _104 !== void 0 ? _104 : theme.themeColors.accent1;
2057
- decreaseColor_1 = (_106 = (_105 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.negativeColor) !== null && _105 !== void 0 ? _105 : theme.themeColors.accent2) !== null && _106 !== void 0 ? _106 : accent_1;
2058
- totalColor_1 = (_107 = theme.themeColors.accent3) !== null && _107 !== void 0 ? _107 : accent_1;
2069
+ accent_1 = (_105 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.color) !== null && _105 !== void 0 ? _105 : theme.themeColors.accent1;
2070
+ decreaseColor_1 = (_107 = (_106 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.negativeColor) !== null && _106 !== void 0 ? _106 : theme.themeColors.accent2) !== null && _107 !== void 0 ? _107 : accent_1;
2071
+ totalColor_1 = (_108 = theme.themeColors.accent3) !== null && _108 !== void 0 ? _108 : accent_1;
2059
2072
  connectors = steps.slice(0, -1).map(function (s, i) { return [
2060
2073
  { coord: [i, s.cumulative] },
2061
2074
  { coord: [i + 1, s.cumulative] },
@@ -2063,7 +2076,7 @@ var BasicChart = function (_a) {
2063
2076
  chartSeries.push({
2064
2077
  type: "bar",
2065
2078
  stack: "waterfall",
2066
- name: (_108 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _108 !== void 0 ? _108 : "",
2079
+ name: (_109 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _109 !== void 0 ? _109 : "",
2067
2080
  data: steps.map(function (s, i) { return ({
2068
2081
  value: s.value,
2069
2082
  itemStyle: {
@@ -2090,12 +2103,12 @@ var BasicChart = function (_a) {
2090
2103
  legend.data = [];
2091
2104
  }
2092
2105
  else if (spec.chartType === "funnel") {
2093
- primaryDomainSource_2 = (_111 = (_110 = (_109 = spec === null || spec === void 0 ? void 0 : spec.domains) === null || _109 === void 0 ? void 0 : _109[0]) === null || _110 === void 0 ? void 0 : _110.sources) === null || _111 === void 0 ? void 0 : _111[0];
2106
+ primaryDomainSource_2 = (_112 = (_111 = (_110 = spec === null || spec === void 0 ? void 0 : spec.domains) === null || _110 === void 0 ? void 0 : _110[0]) === null || _111 === void 0 ? void 0 : _111.sources) === null || _112 === void 0 ? void 0 : _112[0];
2094
2107
  rawDomainValues = primaryDomainSource_2
2095
- ? (0, aggregation_1.sanitizeDomainValues)((_112 = getDomainValuesFromRange(primaryDomainSource_2, spec.hiddenDimensionStrategy)) !== null && _112 !== void 0 ? _112 : [])
2108
+ ? (0, aggregation_1.sanitizeDomainValues)((_113 = getDomainValuesFromRange(primaryDomainSource_2, spec.hiddenDimensionStrategy)) !== null && _113 !== void 0 ? _113 : [])
2096
2109
  : [];
2097
2110
  labels_1 = rawDomainValues.map(function (v) { return String(v !== null && v !== void 0 ? v : ""); });
2098
- seriesEntry = (_113 = spec.series) === null || _113 === void 0 ? void 0 : _113[0];
2111
+ seriesEntry = (_114 = spec.series) === null || _114 === void 0 ? void 0 : _114[0];
2099
2112
  rawValues = seriesEntry
2100
2113
  ? flattenChartDataValues([seriesEntry], getSeriesValuesFromRange, spec.hiddenDimensionStrategy).map(function (v) { return (typeof v === "number" ? v : 0); })
2101
2114
  : [];
@@ -2103,7 +2116,7 @@ var BasicChart = function (_a) {
2103
2116
  chartSeries.length = 0;
2104
2117
  chartSeries.push({
2105
2118
  type: "funnel",
2106
- name: (_114 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _114 !== void 0 ? _114 : "",
2119
+ name: (_115 = seriesEntry === null || seriesEntry === void 0 ? void 0 : seriesEntry.dataLabel) !== null && _115 !== void 0 ? _115 : "",
2107
2120
  data: rawValues.map(function (value, i) {
2108
2121
  var _a;
2109
2122
  return ({
@@ -2124,7 +2137,7 @@ var BasicChart = function (_a) {
2124
2137
  outlierPoints = [];
2125
2138
  meanPoints = [];
2126
2139
  try {
2127
- for (_v = tslib_1.__values((_115 = spec.series) !== null && _115 !== void 0 ? _115 : []), _w = _v.next(); !_w.done; _w = _v.next()) {
2140
+ for (_v = tslib_1.__values((_116 = spec.series) !== null && _116 !== void 0 ? _116 : []), _w = _v.next(); !_w.done; _w = _v.next()) {
2128
2141
  seriesEntry = _w.value;
2129
2142
  label = seriesEntry.dataLabel && !(0, utils_1.isAFormula)(seriesEntry.dataLabel)
2130
2143
  ? seriesEntry.dataLabel
@@ -2173,7 +2186,7 @@ var BasicChart = function (_a) {
2173
2186
  axisLine: { show: true },
2174
2187
  axisTick: { show: true },
2175
2188
  splitLine: { show: false },
2176
- name: (_116 = spec.horizontalAxisTitle) !== null && _116 !== void 0 ? _116 : "",
2189
+ name: (_117 = spec.horizontalAxisTitle) !== null && _117 !== void 0 ? _117 : "",
2177
2190
  nameLocation: "middle",
2178
2191
  nameGap: 30,
2179
2192
  });
@@ -2183,7 +2196,7 @@ var BasicChart = function (_a) {
2183
2196
  name: "",
2184
2197
  data: boxStats,
2185
2198
  };
2186
- boxColor = (_118 = (_117 = spec.series) === null || _117 === void 0 ? void 0 : _117[0]) === null || _118 === void 0 ? void 0 : _118.color;
2199
+ boxColor = (_119 = (_118 = spec.series) === null || _118 === void 0 ? void 0 : _118[0]) === null || _119 === void 0 ? void 0 : _119.color;
2187
2200
  if (boxColor) {
2188
2201
  boxSeries.itemStyle = { color: boxColor, borderColor: boxColor };
2189
2202
  }
@@ -2215,18 +2228,18 @@ var BasicChart = function (_a) {
2215
2228
  axisLine: { show: true },
2216
2229
  axisTick: { show: true },
2217
2230
  splitLine: { show: false },
2218
- name: (_119 = spec.horizontalAxisTitle) !== null && _119 !== void 0 ? _119 : "",
2231
+ name: (_120 = spec.horizontalAxisTitle) !== null && _120 !== void 0 ? _120 : "",
2219
2232
  nameLocation: "middle",
2220
2233
  nameGap: 30,
2221
2234
  });
2222
2235
  chartSeries.length = 0;
2223
2236
  histogramSeries = {
2224
2237
  type: "bar",
2225
- name: (_122 = (_121 = (_120 = spec.series) === null || _120 === void 0 ? void 0 : _120[0]) === null || _121 === void 0 ? void 0 : _121.dataLabel) !== null && _122 !== void 0 ? _122 : "",
2238
+ name: (_123 = (_122 = (_121 = spec.series) === null || _121 === void 0 ? void 0 : _121[0]) === null || _122 === void 0 ? void 0 : _122.dataLabel) !== null && _123 !== void 0 ? _123 : "",
2226
2239
  data: counts,
2227
2240
  barCategoryGap: "1%",
2228
2241
  };
2229
- histogramColor = (_124 = (_123 = spec.series) === null || _123 === void 0 ? void 0 : _123[0]) === null || _124 === void 0 ? void 0 : _124.color;
2242
+ histogramColor = (_125 = (_124 = spec.series) === null || _124 === void 0 ? void 0 : _124[0]) === null || _125 === void 0 ? void 0 : _125.color;
2230
2243
  if (histogramColor) {
2231
2244
  histogramSeries.itemStyle = { color: histogramColor };
2232
2245
  }
@@ -2263,20 +2276,20 @@ var BasicChart = function (_a) {
2263
2276
  isPareto = spec.chartType === "histogram" && (0, histogram_1.isParetoSpec)(spec);
2264
2277
  hasSecondaryAxis = !isCircularChart &&
2265
2278
  !isHorizontalBarChart &&
2266
- (((_125 = spec.series) !== null && _125 !== void 0 ? _125 : []).some(function (s) { return s.useSecondaryAxis; }) || isPareto);
2279
+ (((_126 = spec.series) !== null && _126 !== void 0 ? _126 : []).some(function (s) { return s.useSecondaryAxis; }) || isPareto);
2267
2280
  isPercentStackedBars = spec.stackedType === "PERCENT_STACKED" &&
2268
2281
  (spec.chartType === "bar" || spec.chartType === "column");
2269
2282
  primaryAxisNumberFormat = isPercentStackedBars
2270
2283
  ? undefined
2271
2284
  : (0, axis_number_format_1.resolveValueAxisNumberFormat)({
2272
2285
  axisOptions: spec.valueAxisOptions,
2273
- series: ((_126 = spec.series) !== null && _126 !== void 0 ? _126 : []).filter(function (s) { return !s.useSecondaryAxis; }),
2286
+ series: ((_127 = spec.series) !== null && _127 !== void 0 ? _127 : []).filter(function (s) { return !s.useSecondaryAxis; }),
2274
2287
  getFormattingFromRange: getFormattingFromRange,
2275
2288
  hiddenDimensionStrategy: spec.hiddenDimensionStrategy,
2276
2289
  });
2277
2290
  secondaryAxisNumberFormat = (0, axis_number_format_1.resolveValueAxisNumberFormat)({
2278
2291
  axisOptions: spec.secondaryValueAxisOptions,
2279
- series: ((_127 = spec.series) !== null && _127 !== void 0 ? _127 : []).filter(function (s) { return s.useSecondaryAxis; }),
2292
+ series: ((_128 = spec.series) !== null && _128 !== void 0 ? _128 : []).filter(function (s) { return s.useSecondaryAxis; }),
2280
2293
  getFormattingFromRange: getFormattingFromRange,
2281
2294
  hiddenDimensionStrategy: spec.hiddenDimensionStrategy,
2282
2295
  });
@@ -2298,24 +2311,24 @@ var BasicChart = function (_a) {
2298
2311
  trigger: isCircularChart ? "item" : "axis",
2299
2312
  formatter: isCircularChart
2300
2313
  ? primaryAxisNumberFormat
2301
- ? (0, axis_number_format_1.circularTooltipFormatter)(primaryAxisNumberFormat)
2314
+ ? (0, axis_number_format_1.circularTooltipFormatter)(primaryAxisNumberFormat, locale)
2302
2315
  : "{b}: {c} ({d}%)"
2303
2316
  : undefined,
2304
2317
  };
2305
2318
  finalLegend = (0, overrides_1.applyLegendOverrides)(legend, spec.legend);
2306
2319
  bottomAxisNameGap = isHorizontalBarChart
2307
2320
  ? valueAxisBase.nameGap
2308
- : Number((_129 = (_128 = chartDomains[0]) === null || _128 === void 0 ? void 0 : _128.nameGap) !== null && _129 !== void 0 ? _129 : CATEGORY_AXIS_NAME_GAP);
2321
+ : Number((_130 = (_129 = chartDomains[0]) === null || _129 === void 0 ? void 0 : _129.nameGap) !== null && _130 !== void 0 ? _130 : CATEGORY_AXIS_NAME_GAP);
2309
2322
  legendBand = (0, legend_layout_1.reserveEchartsLegendBand)({
2310
- position: (_130 = spec.legend) === null || _130 === void 0 ? void 0 : _130.position,
2323
+ position: (_131 = spec.legend) === null || _131 === void 0 ? void 0 : _131.position,
2311
2324
  visible: finalLegend.show !== false,
2312
2325
  labels: (0, legend_layout_1.legendLabelsFrom)(finalLegend.data, chartSeries.map(function (s) { return s === null || s === void 0 ? void 0 : s.name; })),
2313
- legendFontSize: (_135 = (_132 = (_131 = finalLegend.textStyle) === null || _131 === void 0 ? void 0 : _131.fontSize) !== null && _132 !== void 0 ? _132 : (_134 = (_133 = spec.legend) === null || _133 === void 0 ? void 0 : _133.textFormat) === null || _134 === void 0 ? void 0 : _134.fontSize) !== null && _135 !== void 0 ? _135 : 12,
2326
+ legendFontSize: (_136 = (_133 = (_132 = finalLegend.textStyle) === null || _132 === void 0 ? void 0 : _132.fontSize) !== null && _133 !== void 0 ? _133 : (_135 = (_134 = spec.legend) === null || _134 === void 0 ? void 0 : _134.textFormat) === null || _135 === void 0 ? void 0 : _135.fontSize) !== null && _136 !== void 0 ? _136 : 12,
2314
2327
  legendItemWidth: defaultLegendConfig.itemWidth,
2315
2328
  width: width !== null && width !== void 0 ? width : 0,
2316
2329
  height: height !== null && height !== void 0 ? height : 0,
2317
2330
  hasTitle: Boolean(title),
2318
- titleFontSize: (_137 = (_136 = spec.titleTextFormat) === null || _136 === void 0 ? void 0 : _136.fontSize) !== null && _137 !== void 0 ? _137 : 16,
2331
+ titleFontSize: (_138 = (_137 = spec.titleTextFormat) === null || _137 === void 0 ? void 0 : _137.fontSize) !== null && _138 !== void 0 ? _138 : 16,
2319
2332
  hasBottomAxisTitle: !isCircularChart && Boolean(spec.horizontalAxisTitle),
2320
2333
  bottomAxisNameGap: bottomAxisNameGap,
2321
2334
  hasLeftAxisTitle: !isCircularChart && Boolean(spec.verticalAxisTitle),
@@ -2338,7 +2351,7 @@ var BasicChart = function (_a) {
2338
2351
  dataLabelOptions = spec.dataLabels;
2339
2352
  seriesLabelOptionFor = function (s) {
2340
2353
  return (0, overrides_1.buildSeriesLabelOption)(dataLabelOptions && !dataLabelOptions.numberFormatPattern
2341
- ? tslib_1.__assign(tslib_1.__assign({}, dataLabelOptions), { numberFormatPattern: seriesNumberFormatFor(s) }) : dataLabelOptions);
2354
+ ? tslib_1.__assign(tslib_1.__assign({}, dataLabelOptions), { numberFormatPattern: seriesNumberFormatFor(s) }) : dataLabelOptions, s === null || s === void 0 ? void 0 : s.type, locale);
2342
2355
  };
2343
2356
  isDoughnut = spec.chartType === "doughnut";
2344
2357
  doughnutHoleSize = spec.doughnutHoleSize;
@@ -2415,7 +2428,7 @@ var BasicChart = function (_a) {
2415
2428
  // Tooltip values of the value-axis series (a boxplot / candlestick
2416
2429
  // tooltip lists its own statistics and keeps echarts' default).
2417
2430
  var seriesTooltipValueFormatter = VALUE_TOOLTIP_SERIES_TYPES.has(s === null || s === void 0 ? void 0 : s.type)
2418
- ? (0, axis_number_format_1.valueAxisLabelFormatter)(seriesNumberFormatFor(s))
2431
+ ? (0, axis_number_format_1.valueAxisLabelFormatter)(seriesNumberFormatFor(s), locale)
2419
2432
  : undefined;
2420
2433
  if (seriesTooltipValueFormatter && ((_b = s === null || s === void 0 ? void 0 : s.tooltip) === null || _b === void 0 ? void 0 : _b.show) !== false) {
2421
2434
  next.tooltip = tslib_1.__assign(tslib_1.__assign({}, ((_c = s === null || s === void 0 ? void 0 : s.tooltip) !== null && _c !== void 0 ? _c : {})), { valueFormatter: seriesTooltipValueFormatter });
@@ -2423,7 +2436,7 @@ var BasicChart = function (_a) {
2423
2436
  if (next.type === "pie") {
2424
2437
  var pieNumberFormat = seriesNumberFormatFor(s);
2425
2438
  if (pieNumberFormat && ((_d = s === null || s === void 0 ? void 0 : s.tooltip) === null || _d === void 0 ? void 0 : _d.show) !== false) {
2426
- next.tooltip = tslib_1.__assign(tslib_1.__assign({}, ((_e = s === null || s === void 0 ? void 0 : s.tooltip) !== null && _e !== void 0 ? _e : {})), { formatter: (0, axis_number_format_1.circularTooltipFormatter)(pieNumberFormat) });
2439
+ next.tooltip = tslib_1.__assign(tslib_1.__assign({}, ((_e = s === null || s === void 0 ? void 0 : s.tooltip) !== null && _e !== void 0 ? _e : {})), { formatter: (0, axis_number_format_1.circularTooltipFormatter)(pieNumberFormat, locale) });
2427
2440
  }
2428
2441
  if (explosionOffset > 0 && Array.isArray(next.data)) {
2429
2442
  next.selectedMode = "multiple";
@@ -2443,7 +2456,7 @@ var BasicChart = function (_a) {
2443
2456
  return next;
2444
2457
  });
2445
2458
  // Update charts
2446
- (_138 = chartRef.current) === null || _138 === void 0 ? void 0 : _138.setOption({
2459
+ (_139 = chartRef.current) === null || _139 === void 0 ? void 0 : _139.setOption({
2447
2460
  xAxis: (function () {
2448
2461
  var _a, _b;
2449
2462
  if (isOfPie) {
@@ -2487,7 +2500,7 @@ var BasicChart = function (_a) {
2487
2500
  }
2488
2501
  if (isHorizontalBarChart) {
2489
2502
  return [
2490
- (0, overrides_1.applyAxisOverrides)(tslib_1.__assign(tslib_1.__assign({}, valueAxisBase), { name: (_a = spec.horizontalAxisTitle) !== null && _a !== void 0 ? _a : "" }), spec.valueAxisOptions, primaryAxisNumberFormat),
2503
+ (0, overrides_1.applyAxisOverrides)(tslib_1.__assign(tslib_1.__assign({}, valueAxisBase), { name: (_a = spec.horizontalAxisTitle) !== null && _a !== void 0 ? _a : "" }), spec.valueAxisOptions, primaryAxisNumberFormat, locale),
2491
2504
  ];
2492
2505
  }
2493
2506
  var base = chartDomains.length > 0
@@ -2565,7 +2578,8 @@ var BasicChart = function (_a) {
2565
2578
  : [];
2566
2579
  }),
2567
2580
  pattern: primaryAxisNumberFormat,
2568
- }) }), spec.valueAxisOptions, primaryAxisNumberFormat),
2581
+ locale: locale,
2582
+ }) }), spec.valueAxisOptions, primaryAxisNumberFormat, locale),
2569
2583
  ];
2570
2584
  if (hasSecondaryAxis) {
2571
2585
  axes.push((0, overrides_1.applyAxisOverrides)(tslib_1.__assign(tslib_1.__assign(tslib_1.__assign({}, valueAxisBase), { name: "", splitLine: { show: false } }), (isPareto
@@ -2574,7 +2588,7 @@ var BasicChart = function (_a) {
2574
2588
  max: 100,
2575
2589
  axisLabel: { formatter: "{value}%" },
2576
2590
  }
2577
- : {})), spec.secondaryValueAxisOptions, secondaryAxisNumberFormat));
2591
+ : {})), spec.secondaryValueAxisOptions, secondaryAxisNumberFormat, locale));
2578
2592
  }
2579
2593
  return axes;
2580
2594
  })(),
@@ -2716,6 +2730,7 @@ var BasicChart = function (_a) {
2716
2730
  getDomainValuesFromRange,
2717
2731
  getSeriesValuesFromRange,
2718
2732
  getFormattingFromRange,
2733
+ locale,
2719
2734
  glUpgradeTick,
2720
2735
  ]);
2721
2736
  // Resize chart