@progress/kendo-charts 2.6.1 → 2.6.2-dev.202411060930

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.
@@ -1458,7 +1458,7 @@ var Chart = (function (Class) {
1458
1458
  return;
1459
1459
  }
1460
1460
 
1461
- if (focusState.focusedElement) {
1461
+ if (focusState.focusedElement && focusState.focusedElement.clearFocusFromVisual) {
1462
1462
  focusState.focusedElement.clearFocusFromVisual();
1463
1463
  this._clearElementActiveDescendant();
1464
1464
  }
@@ -11,6 +11,8 @@ import { append, deepExtend, defined, getSpacing, getTemplate, inArray, isFuncti
11
11
  limitValue, round, setDefaultOptions, last, cycleIndex } from '../../common';
12
12
  import { TRENDLINE_SERIES } from '../constants';
13
13
 
14
+ var visiblePoint = function (point) { return point.options.visible !== false; };
15
+
14
16
  var PlotAreaBase = (function (ChartElement) {
15
17
  function PlotAreaBase(series, options, chartService) {
16
18
  ChartElement.call(this, options);
@@ -1046,7 +1048,15 @@ var PlotAreaBase = (function (ChartElement) {
1046
1048
  };
1047
1049
 
1048
1050
  PlotAreaBase.prototype.getFirstPoint = function getFirstPoint () {
1049
- return this.pointsBySeriesIndex(0)[0];
1051
+ var this$1 = this;
1052
+
1053
+ for (var i = 0; i < this.series.length; i++) {
1054
+ var points = this$1.pointsBySeriesIndex(i);
1055
+ var point = points.find(visiblePoint);
1056
+ if (point) {
1057
+ return point;
1058
+ }
1059
+ }
1050
1060
  };
1051
1061
 
1052
1062
  PlotAreaBase.prototype.getPointBelow = function getPointBelow (point) {
@@ -1068,7 +1078,7 @@ var PlotAreaBase = (function (ChartElement) {
1068
1078
  PlotAreaBase.prototype._getNextPoint = function _getNextPoint (point, getPointsFunc, increment) {
1069
1079
  var this$1 = this;
1070
1080
 
1071
- var points = getPointsFunc.call(this, point);
1081
+ var points = getPointsFunc.call(this, point).filter(visiblePoint);
1072
1082
  var pointIndex = points.indexOf(point);
1073
1083
  var nextIndex = pointIndex + increment;
1074
1084
  var loopPoints = function (direction) {
@@ -1077,7 +1087,7 @@ var PlotAreaBase = (function (ChartElement) {
1077
1087
  var offset = 0;
1078
1088
  do {
1079
1089
  offset += direction;
1080
- result = getPointsFunc.call(this$1, point, offset);
1090
+ result = getPointsFunc.call(this$1, point, offset).filter(visiblePoint);
1081
1091
  } while (result.length === 0);
1082
1092
 
1083
1093
  return result;
@@ -1413,7 +1413,7 @@ class Chart extends Class {
1413
1413
  return;
1414
1414
  }
1415
1415
 
1416
- if (focusState.focusedElement) {
1416
+ if (focusState.focusedElement && focusState.focusedElement.clearFocusFromVisual) {
1417
1417
  focusState.focusedElement.clearFocusFromVisual();
1418
1418
  this._clearElementActiveDescendant();
1419
1419
  }
@@ -11,6 +11,8 @@ import { append, deepExtend, defined, getSpacing, getTemplate, inArray, isFuncti
11
11
  limitValue, round, setDefaultOptions, last, cycleIndex } from '../../common';
12
12
  import { TRENDLINE_SERIES } from '../constants';
13
13
 
14
+ const visiblePoint = (point) => point.options.visible !== false;
15
+
14
16
  class PlotAreaBase extends ChartElement {
15
17
  constructor(series, options, chartService) {
16
18
  super(options);
@@ -1014,7 +1016,13 @@ class PlotAreaBase extends ChartElement {
1014
1016
  }
1015
1017
 
1016
1018
  getFirstPoint() {
1017
- return this.pointsBySeriesIndex(0)[0];
1019
+ for (let i = 0; i < this.series.length; i++) {
1020
+ const points = this.pointsBySeriesIndex(i);
1021
+ const point = points.find(visiblePoint);
1022
+ if (point) {
1023
+ return point;
1024
+ }
1025
+ }
1018
1026
  }
1019
1027
 
1020
1028
  getPointBelow(point) {
@@ -1034,7 +1042,7 @@ class PlotAreaBase extends ChartElement {
1034
1042
  }
1035
1043
 
1036
1044
  _getNextPoint(point, getPointsFunc, increment) {
1037
- let points = getPointsFunc.call(this, point);
1045
+ let points = getPointsFunc.call(this, point).filter(visiblePoint);
1038
1046
  const pointIndex = points.indexOf(point);
1039
1047
  let nextIndex = pointIndex + increment;
1040
1048
  const loopPoints = (direction) => {
@@ -1043,7 +1051,7 @@ class PlotAreaBase extends ChartElement {
1043
1051
  let offset = 0;
1044
1052
  do {
1045
1053
  offset += direction;
1046
- result = getPointsFunc.call(this, point, offset);
1054
+ result = getPointsFunc.call(this, point, offset).filter(visiblePoint);
1047
1055
  } while (result.length === 0);
1048
1056
 
1049
1057
  return result;