@syncfusion/ej2-gantt 19.4.54 → 19.4.55

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.
@@ -8334,7 +8334,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8334
8334
  var childTaskbarNode = null;
8335
8335
  var data = this.templateData;
8336
8336
  if (this.childTaskbarTemplateFunction) {
8337
- childTaskbarNode = this.childTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'TaskbarTemplate', this.getTemplateID('TaskbarTemplate'), false, undefined, rootElement[0]);
8337
+ childTaskbarNode = this.childTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'TaskbarTemplate', this.getTemplateID('TaskbarTemplate'), false, undefined, rootElement[0], this.parent.treeGrid['root']);
8338
8338
  }
8339
8339
  else {
8340
8340
  var labelString = '';
@@ -8773,7 +8773,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8773
8773
  var milestoneNode = null;
8774
8774
  var data = this.templateData;
8775
8775
  if (this.milestoneTemplateFunction) {
8776
- milestoneNode = this.milestoneTemplateFunction(extend({ index: i }, data), this.parent, 'MilestoneTemplate', this.getTemplateID('MilestoneTemplate'), false, undefined, rootElement[0]);
8776
+ milestoneNode = this.milestoneTemplateFunction(extend({ index: i }, data), this.parent, 'MilestoneTemplate', this.getTemplateID('MilestoneTemplate'), false, undefined, rootElement[0], this.parent.treeGrid['root']);
8777
8777
  }
8778
8778
  else {
8779
8779
  var template = '<div class="' + traceMilestone + '" style="position:absolute;">' +
@@ -8844,7 +8844,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8844
8844
  leftLabelNode[0].setAttribute('aria-label', this.generateTaskLabelAriaLabel('left'));
8845
8845
  var leftLabelTemplateNode = null;
8846
8846
  if (this.leftTaskLabelTemplateFunction) {
8847
- leftLabelTemplateNode = this.leftTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'LeftLabelTemplate', this.getTemplateID('LeftLabelTemplate'), false, undefined, leftLabelNode[0]);
8847
+ leftLabelTemplateNode = this.leftTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'LeftLabelTemplate', this.getTemplateID('LeftLabelTemplate'), false, undefined, leftLabelNode[0], this.parent.treeGrid['root']);
8848
8848
  }
8849
8849
  else {
8850
8850
  var field = this.parent.labelSettings.leftLabel;
@@ -8855,6 +8855,9 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8855
8855
  }
8856
8856
  }
8857
8857
  if (leftLabelTemplateNode && leftLabelTemplateNode.length > 0) {
8858
+ if (leftLabelTemplateNode[0]['data'] === 'null') {
8859
+ leftLabelTemplateNode[0]['data'] = '';
8860
+ }
8858
8861
  leftLabelNode[0].appendChild([].slice.call(leftLabelTemplateNode)[0]);
8859
8862
  }
8860
8863
  return leftLabelNode;
@@ -8884,7 +8887,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8884
8887
  rightLabelNode[0].setAttribute('aria-label', this.generateTaskLabelAriaLabel('right'));
8885
8888
  var rightLabelTemplateNode = null;
8886
8889
  if (this.rightTaskLabelTemplateFunction) {
8887
- rightLabelTemplateNode = this.rightTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'RightLabelTemplate', this.getTemplateID('RightLabelTemplate'), false, undefined, rightLabelNode[0]);
8890
+ rightLabelTemplateNode = this.rightTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'RightLabelTemplate', this.getTemplateID('RightLabelTemplate'), false, undefined, rightLabelNode[0], this.parent.treeGrid['root']);
8888
8891
  }
8889
8892
  else {
8890
8893
  var field = this.parent.labelSettings.rightLabel;
@@ -8895,6 +8898,9 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8895
8898
  }
8896
8899
  }
8897
8900
  if (rightLabelTemplateNode && rightLabelTemplateNode.length > 0) {
8901
+ if (rightLabelTemplateNode[0]['data'] === 'null') {
8902
+ rightLabelTemplateNode[0]['data'] = '';
8903
+ }
8898
8904
  rightLabelNode[0].appendChild([].slice.call(rightLabelTemplateNode)[0]);
8899
8905
  }
8900
8906
  return rightLabelNode;
@@ -8949,7 +8955,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
8949
8955
  var parentTaskbarNode = null;
8950
8956
  var data = this.templateData;
8951
8957
  if (this.parentTaskbarTemplateFunction) {
8952
- parentTaskbarNode = this.parentTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'ParentTaskbarTemplate', this.getTemplateID('ParentTaskbarTemplate'), false, undefined, rootElement[0]);
8958
+ parentTaskbarNode = this.parentTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'ParentTaskbarTemplate', this.getTemplateID('ParentTaskbarTemplate'), false, undefined, rootElement[0], this.parent.treeGrid['root']);
8953
8959
  }
8954
8960
  else {
8955
8961
  var labelString = '';
@@ -9063,10 +9069,19 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9063
9069
  };
9064
9070
  ChartRows.prototype.isTemplate = function (template) {
9065
9071
  var result = false;
9072
+ for (var i = 0; i < this.parent.ganttColumns.length; i++) {
9073
+ if (template === this.parent.ganttColumns[i].field) {
9074
+ result = true;
9075
+ break;
9076
+ }
9077
+ }
9066
9078
  if (typeof template !== 'string' || template.indexOf('#') === 0 || template.indexOf('<') > -1
9067
- || template.indexOf('$') > -1) {
9079
+ || template.indexOf('$') > -1 || !result) {
9068
9080
  result = true;
9069
9081
  }
9082
+ else {
9083
+ result = false;
9084
+ }
9070
9085
  return result;
9071
9086
  };
9072
9087
  /**
@@ -9081,7 +9096,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9081
9096
  ChartRows.prototype.leftLabelContainer = function () {
9082
9097
  var template = '<div class="' + ((this.leftTaskLabelTemplateFunction) ? leftLabelTempContainer :
9083
9098
  leftLabelContainer) + ' ' + '" tabindex="-1" style="height:' +
9084
- (this.parent.rowHeight - 1) + 'px;width:' + this.taskNameWidth(this.templateData) + '"></div>';
9099
+ (this.parent.rowHeight - 2) + 'px;width:' + this.taskNameWidth(this.templateData) + '"></div>';
9085
9100
  return this.createDivElement(template);
9086
9101
  };
9087
9102
  ChartRows.prototype.taskbarContainer = function () {
@@ -9104,7 +9119,7 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9104
9119
  ChartRows.prototype.rightLabelContainer = function () {
9105
9120
  var template = '<div class="' + ((this.rightTaskLabelTemplateFunction) ? rightLabelTempContainer :
9106
9121
  rightLabelContainer) + '" ' + ' tabindex="-1" style="left:' + this.getRightLabelLeft(this.templateData) + 'px;height:'
9107
- + (this.parent.rowHeight - 1) + 'px;"></div>';
9122
+ + (this.parent.rowHeight - 2) + 'px;"></div>';
9108
9123
  return this.createDivElement(template);
9109
9124
  };
9110
9125
  ChartRows.prototype.childTaskbarLeftResizer = function () {
@@ -25393,7 +25408,9 @@ var Selection$1 = /** @__PURE__ @class */ (function () {
25393
25408
  }
25394
25409
  this.addRemoveClass(index);
25395
25410
  this.selectedRowIndexes = extend([], this.getSelectedRowIndexes(), [], true);
25396
- this.parent.setProperties({ selectedRowIndex: -1 }, true);
25411
+ if (this.selectedRowIndexes.length == 0) {
25412
+ this.parent.setProperties({ selectedRowIndex: -1 }, true);
25413
+ }
25397
25414
  if (!isNullOrUndefined(this.parent.toolbarModule)) {
25398
25415
  this.parent.toolbarModule.refreshToolbarItems();
25399
25416
  }