@syncfusion/ej2-gantt 21.2.3 → 21.2.4

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.
@@ -5941,7 +5941,7 @@ var Timeline = /** @__PURE__ @class */ (function () {
5941
5941
  var secondValue;
5942
5942
  var zoomingCollections = this.parent.zoomingLevels.slice();
5943
5943
  var sortedCollectons = zoomingCollections.sort(function (a, b) {
5944
- return (a.perDayWidth < b.perDayWidth) ? 1 : -1;
5944
+ return (!a.perDayWidth && !b.perDayWidth ? 0 : (a.perDayWidth < b.perDayWidth) ? 1 : -1);
5945
5945
  });
5946
5946
  if (perDayWidth === 0) { // return when the Gantt chart is not in viewable state.
5947
5947
  return;
@@ -9182,7 +9182,12 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9182
9182
  data.ganttProperties.segments.length === 0))) {
9183
9183
  if (template !== '' && !isNullOrUndefined(progressDiv) && progressDiv.length > 0) {
9184
9184
  var templateElement = this.createDivElement(template)[0];
9185
- templateElement.innerText = labelString;
9185
+ if (this.parent.disableHtmlEncode) {
9186
+ templateElement.innerText = labelString;
9187
+ }
9188
+ else {
9189
+ templateElement.innerHTML = labelString;
9190
+ }
9186
9191
  var childLabel = this.parent.labelSettings.taskLabel;
9187
9192
  if (childLabel && childLabel['elementRef'])
9188
9193
  templateElement.appendChild(tempDiv);
@@ -9848,7 +9853,12 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9848
9853
  this.taskBarHeight + 'px;"></span>';
9849
9854
  }
9850
9855
  var labelElement = this.createDivElement(labelDiv)[0];
9851
- labelElement.innerText = labelString;
9856
+ if (this.parent.disableHtmlEncode) {
9857
+ labelElement.innerText = labelString;
9858
+ }
9859
+ else {
9860
+ labelElement.innerHTML = labelString;
9861
+ }
9852
9862
  var parentLabel = this.parent.labelSettings.taskLabel;
9853
9863
  if (parentLabel && parentLabel['elementRef'])
9854
9864
  labelElement.appendChild(div);
@@ -15560,7 +15570,7 @@ var Gantt = /** @__PURE__ @class */ (function (_super) {
15560
15570
  args: [this]
15561
15571
  });
15562
15572
  }
15563
- if (this.toolbar) {
15573
+ if (this.toolbar && this.toolbar.length > 0) {
15564
15574
  modules.push({
15565
15575
  member: 'toolbar',
15566
15576
  args: [this]
@@ -22938,7 +22948,7 @@ var DialogEdit = /** @__PURE__ @class */ (function () {
22938
22948
  var ganttObj = this.parent;
22939
22949
  var rte = notesElement.ej2_instances[0];
22940
22950
  if (this.isEdit) {
22941
- if (ganttObj.columnByField[ganttObj.taskFields.notes].disableHtmlEncode) {
22951
+ if (ganttObj.columnByField[ganttObj.taskFields.notes].disableHtmlEncode === false) {
22942
22952
  this.parent.setRecordValue('notes', rte.getHtml(), this.rowData.ganttProperties, true);
22943
22953
  }
22944
22954
  else {
@@ -24383,7 +24393,7 @@ var Edit$2 = /** @__PURE__ @class */ (function () {
24383
24393
  }
24384
24394
  else if ([tasks.progress, tasks.notes, tasks.durationUnit, tasks.expandState,
24385
24395
  tasks.milestone, tasks.name, tasks.baselineStartDate,
24386
- tasks.baselineEndDate, tasks.id, tasks.segments].indexOf(key) !== -1) {
24396
+ tasks.baselineEndDate, tasks.id, tasks.segments, tasks.cssClass].indexOf(key) !== -1) {
24387
24397
  var column = ganttObj.columnByField[key];
24388
24398
  /* eslint-disable-next-line */
24389
24399
  var value = data[key];
@@ -24397,6 +24407,9 @@ var Edit$2 = /** @__PURE__ @class */ (function () {
24397
24407
  else if (key === tasks.name) {
24398
24408
  ganttPropKey = 'taskName';
24399
24409
  }
24410
+ else if (key === tasks.cssClass) {
24411
+ ganttPropKey = 'cssClass';
24412
+ }
24400
24413
  else if ((key === tasks.segments) && (!isNullOrUndefined(ganttData.ganttProperties.segments))) {
24401
24414
  ganttPropKey = 'segments';
24402
24415
  /* eslint-disable-next-line */