@react-magma/charts 14.0.1-rc.0 → 15.0.0-rc.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/dist/charts.js CHANGED
@@ -1611,18 +1611,10 @@ var CarbonChart = React__namespace.forwardRef(function (props, ref) {
1611
1611
  type: 'none',
1612
1612
  } }) }), (chartToolbar ? { toolbar: { enabled: false } } : {}));
1613
1613
  var ChartType = allCharts[type];
1614
- // Adding aria-label to main SVG container
1615
- React__namespace.useEffect(function () {
1616
- if (ariaLabel) {
1617
- document.querySelectorAll('.graph-frame ').forEach(function (div) {
1618
- div.setAttribute('aria-label', ariaLabel);
1619
- });
1620
- }
1621
- });
1622
1614
  var groupsLength = Object.keys(buildColors()).length;
1623
1615
  var showTable = (chartToolbar === null || chartToolbar === void 0 ? void 0 : chartToolbar.showAsTable) !== false;
1624
1616
  return (React__namespace.createElement(FullscreenRoot, { ref: mergedRef, isInverse: isInverse, theme: theme },
1625
- React__namespace.createElement(CarbonChartWrapper, __assign({ "data-testid": testId, isInverse: isInverse, theme: theme, className: "carbon-chart-wrapper".concat(chartToolbar ? ' has-magma-toolbar' : ''), groupsLength: groupsLength < 6 ? groupsLength : 14 }, rest),
1617
+ React__namespace.createElement(CarbonChartWrapper, __assign({ "data-testid": testId, isInverse: isInverse, theme: theme, className: "carbon-chart-wrapper".concat(chartToolbar ? ' has-magma-toolbar' : ''), groupsLength: groupsLength < 6 ? groupsLength : 14, role: "region", "aria-label": ariaLabel || chartTitle, "aria-roledescription": "chart" }, rest),
1626
1618
  React__namespace.createElement(ChartContentWrapper, null,
1627
1619
  chartToolbar && (React__namespace.createElement(CarbonChartToolbar, { config: chartToolbar, dataSet: dataSet, isInverse: isInverse, isTableOpen: isTableOpen, isFullscreen: isFullscreen, onOpenTable: openTableModal, onToggleFullscreen: toggleFullscreen, theme: theme, title: chartTitle, wrapperRef: internalRef })),
1628
1620
  React__namespace.createElement(ChartType, { data: dataSet, options: newOptions }))),