cx 24.4.5 → 24.4.6

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
@@ -270,6 +270,7 @@ var Axis = /*#__PURE__*/ (function (_BoundedObject) {
270
270
  _proto.report = function report(context, instance) {
271
271
  return instance.calculator;
272
272
  };
273
+ _proto.reportData = function reportData(context, instance) {};
273
274
  _proto.renderTicksAndLabels = function renderTicksAndLabels(context, instance, valueFormatter) {
274
275
  var _this = this;
275
276
  if (this.hidden) return false;
@@ -503,6 +504,9 @@ var Chart = /*#__PURE__*/ (function (_BoundedObject) {
503
504
  };
504
505
  _proto.exploreCleanup = function exploreCleanup(context, instance) {
505
506
  context.pop("axes");
507
+ for (var axis in instance.axes) {
508
+ instance.axes[axis].widget.reportData(context, instance.axes[axis]);
509
+ }
506
510
  };
507
511
  _proto.prepare = function prepare(context, instance) {
508
512
  context.push("axes", instance.calculators);
@@ -1672,6 +1676,8 @@ var Legend = /*#__PURE__*/ (function (_HtmlElement) {
1672
1676
  if (!context.legends) context.legends = {};
1673
1677
  instance.legends = context.legends;
1674
1678
  context.addLegendEntry = function (legendName, entry) {
1679
+ if (!legendName) return;
1680
+
1675
1681
  //case when all legends are scoped and new entry is added outside the scope
1676
1682
  if (!context.legends) return;
1677
1683
  var legend = context.legends[legendName];
@@ -4266,6 +4272,7 @@ var CategoryAxis = /*#__PURE__*/ (function (_Axis) {
4266
4272
  names: undefined,
4267
4273
  values: undefined,
4268
4274
  minSize: undefined,
4275
+ categoryCount: undefined,
4269
4276
  },
4270
4277
  ]),
4271
4278
  );
@@ -4283,6 +4290,9 @@ var CategoryAxis = /*#__PURE__*/ (function (_Axis) {
4283
4290
  minSize = _instance$data.minSize;
4284
4291
  instance.calculator.reset(inverted, uniform, values, names, minSize);
4285
4292
  };
4293
+ _proto.reportData = function reportData(context, instance) {
4294
+ instance.set("categoryCount", instance.calculator.valueList.length);
4295
+ };
4286
4296
  _proto.render = function render(context, instance, key) {
4287
4297
  var data = instance.data,
4288
4298
  calculator = instance.calculator;