@syncfusion/ej2-gantt 19.4.43 → 19.4.47

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.
Files changed (60) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/ej2-gantt.umd.min.js +2 -2
  3. package/dist/ej2-gantt.umd.min.js.map +1 -1
  4. package/dist/es6/ej2-gantt.es2015.js +36 -9
  5. package/dist/es6/ej2-gantt.es2015.js.map +1 -1
  6. package/dist/es6/ej2-gantt.es5.js +36 -9
  7. package/dist/es6/ej2-gantt.es5.js.map +1 -1
  8. package/dist/global/ej2-gantt.min.js +2 -2
  9. package/dist/global/ej2-gantt.min.js.map +1 -1
  10. package/dist/global/index.d.ts +1 -1
  11. package/package.json +14 -14
  12. package/src/gantt/actions/chart-scroll.js +1 -0
  13. package/src/gantt/actions/edit.d.ts +1 -1
  14. package/src/gantt/actions/edit.js +5 -1
  15. package/src/gantt/actions/filter.js +1 -1
  16. package/src/gantt/actions/rowdragdrop.js +1 -1
  17. package/src/gantt/actions/taskbar-edit.js +3 -1
  18. package/src/gantt/base/gantt-chart.js +6 -0
  19. package/src/gantt/base/gantt.js +17 -5
  20. package/src/gantt/renderer/edit-tooltip.js +1 -0
  21. package/src/gantt/renderer/tooltip.js +1 -0
  22. package/styles/bootstrap-dark.css +9 -1
  23. package/styles/bootstrap.css +9 -1
  24. package/styles/bootstrap4.css +9 -1
  25. package/styles/bootstrap5-dark.css +9 -1
  26. package/styles/bootstrap5.css +9 -1
  27. package/styles/fabric-dark.css +9 -1
  28. package/styles/fabric.css +9 -1
  29. package/styles/gantt/_bootstrap-dark-definition.scss +0 -1
  30. package/styles/gantt/_bootstrap-definition.scss +0 -1
  31. package/styles/gantt/_bootstrap4-definition.scss +0 -1
  32. package/styles/gantt/_bootstrap5-definition.scss +0 -1
  33. package/styles/gantt/_fabric-dark-definition.scss +0 -1
  34. package/styles/gantt/_fabric-definition.scss +0 -1
  35. package/styles/gantt/_fluent-definition.scss +0 -1
  36. package/styles/gantt/_highcontrast-definition.scss +0 -1
  37. package/styles/gantt/_highcontrast-light-definition.scss +0 -1
  38. package/styles/gantt/_layout.scss +8 -1
  39. package/styles/gantt/_material-dark-definition.scss +0 -1
  40. package/styles/gantt/_material-definition.scss +0 -1
  41. package/styles/gantt/_tailwind-definition.scss +0 -1
  42. package/styles/gantt/bootstrap-dark.css +9 -1
  43. package/styles/gantt/bootstrap.css +9 -1
  44. package/styles/gantt/bootstrap4.css +9 -1
  45. package/styles/gantt/bootstrap5-dark.css +9 -1
  46. package/styles/gantt/bootstrap5.css +9 -1
  47. package/styles/gantt/fabric-dark.css +9 -1
  48. package/styles/gantt/fabric.css +9 -1
  49. package/styles/gantt/highcontrast-light.css +9 -1
  50. package/styles/gantt/highcontrast.css +9 -1
  51. package/styles/gantt/material-dark.css +9 -1
  52. package/styles/gantt/material.css +9 -1
  53. package/styles/gantt/tailwind-dark.css +9 -1
  54. package/styles/gantt/tailwind.css +9 -1
  55. package/styles/highcontrast-light.css +9 -1
  56. package/styles/highcontrast.css +9 -1
  57. package/styles/material-dark.css +9 -1
  58. package/styles/material.css +9 -1
  59. package/styles/tailwind-dark.css +9 -1
  60. package/styles/tailwind.css +9 -1
@@ -4049,6 +4049,7 @@ var ChartScroll = /** @__PURE__ @class */ (function () {
4049
4049
  */
4050
4050
  ChartScroll.prototype.setScrollTop = function (scrollTop) {
4051
4051
  this.element.scrollTop = scrollTop;
4052
+ this.parent.treeGrid.element.querySelector('.e-content').scrollTop = scrollTop;
4052
4053
  };
4053
4054
  /**
4054
4055
  * To set scroll left for chart scroll container
@@ -4439,6 +4440,12 @@ var GanttChart = /** @__PURE__ @class */ (function () {
4439
4440
  * @private
4440
4441
  */
4441
4442
  GanttChart.prototype.mouseUp = function (e) {
4443
+ if (this.parent.allowRowDragAndDrop) {
4444
+ var ganttDragElemet = this.parent.element.querySelector('.e-ganttdrag');
4445
+ if (ganttDragElemet) {
4446
+ ganttDragElemet.remove();
4447
+ }
4448
+ }
4442
4449
  if (!this.isGanttElement) {
4443
4450
  this.parent.notify('chartMouseUp', e);
4444
4451
  }
@@ -11886,6 +11893,7 @@ var Tooltip$1 = /** @__PURE__ @class */ (function () {
11886
11893
  tooltipPositionY = tooltipPositionY + 10;
11887
11894
  }
11888
11895
  args.element.style.top = tooltipPositionY + 'px';
11896
+ args.element.style.visibility = 'visible';
11889
11897
  };
11890
11898
  /**
11891
11899
  * Method to get mouse pointor position
@@ -12674,7 +12682,13 @@ var Gantt = /** @__PURE__ @class */ (function (_super) {
12674
12682
  var settingsHeight;
12675
12683
  if (typeof (this.height) !== 'number' && this.height.indexOf('%') !== -1 && (this.element.parentElement &&
12676
12684
  !this.element.parentElement.style.height || this.element.parentElement.style.height.indexOf('%') !== -1)) {
12677
- var ganttHeight = Number(this.height.split("%")[0]);
12685
+ var ganttHeight = void 0;
12686
+ if (this.element.parentElement.style.height.indexOf('%') == -1) {
12687
+ ganttHeight = Number(this.height.split("%")[0]);
12688
+ }
12689
+ else {
12690
+ ganttHeight = Number(this.element.parentElement.style.height.split("%")[0]);
12691
+ }
12678
12692
  ganttHeight = (ganttHeight * window.innerHeight) / 100;
12679
12693
  if (this.height === '100%') {
12680
12694
  ganttHeight = ganttHeight - 16;
@@ -12829,10 +12843,16 @@ var Gantt = /** @__PURE__ @class */ (function (_super) {
12829
12843
  var settingsHeight = void 0;
12830
12844
  if (this.height.indexOf('%') !== -1) {
12831
12845
  var ganttHeight = Number(this.height.split("%")[0]);
12832
- if (this.element.parentElement && (this.element.parentElement.style.height
12833
- || this.element.parentElement.style.height.indexOf('%') !== -1)) {
12834
- var containerHeight = Number(this.element.parentElement.style.height.split("px")[0]);
12835
- ganttHeight = (ganttHeight * containerHeight) / 100;
12846
+ if (this.element.parentElement && (this.element.parentElement.style.height)) {
12847
+ var containerHeight = void 0;
12848
+ if (this.element.parentElement.style.height.indexOf('%') == -1) {
12849
+ containerHeight = Number(this.element.parentElement.style.height.split("px")[0]);
12850
+ ganttHeight = (ganttHeight * containerHeight) / 100;
12851
+ }
12852
+ else {
12853
+ containerHeight = Number(this.element.parentElement.style.height.split("%")[0]);
12854
+ ganttHeight = (window.innerHeight * containerHeight) / 100;
12855
+ }
12836
12856
  }
12837
12857
  else {
12838
12858
  ganttHeight = Number(this.height.split("%")[0]);
@@ -16208,6 +16228,7 @@ var EditTooltip = /** @__PURE__ @class */ (function () {
16208
16228
  tooltipPositionX += leftEnd - (tooltipPositionX + args.element.offsetWidth);
16209
16229
  }
16210
16230
  args.element.style.left = tooltipPositionX + 'px';
16231
+ args.element.style.visibility = 'visible';
16211
16232
  };
16212
16233
  /**
16213
16234
  * To show/hide taskbar edit tooltip.
@@ -16855,7 +16876,9 @@ var TaskbarEdit = /** @__PURE__ @class */ (function (_super) {
16855
16876
  if (this.isMouseDragged && this.taskBarEditAction) {
16856
16877
  var args = {
16857
16878
  cancel: false,
16858
- requestType: 'taskbarediting'
16879
+ requestType: 'taskbarediting',
16880
+ taskBarEditAction: this.taskBarEditAction,
16881
+ data: this.taskBarEditRecord
16859
16882
  };
16860
16883
  if (this.segmentIndex !== -1) {
16861
16884
  args.requestType = 'mergeSegment';
@@ -22069,7 +22092,7 @@ var Edit$2 = /** @__PURE__ @class */ (function () {
22069
22092
  */
22070
22093
  Edit$$1.prototype.updateParentChildRecord = function (data) {
22071
22094
  var ganttRecord = data;
22072
- if (ganttRecord.hasChildRecords && this.taskbarMoved && this.parent.taskMode === 'Auto') {
22095
+ if (ganttRecord.hasChildRecords && this.taskbarMoved && this.parent.taskMode === 'Auto' && this.parent.previousRecords[data.uniqueID].resources === ganttRecord.ganttProperties['resourceNames']) {
22073
22096
  this.updateChildItems(ganttRecord);
22074
22097
  }
22075
22098
  };
@@ -23991,6 +24014,10 @@ var Edit$2 = /** @__PURE__ @class */ (function () {
23991
24014
  }
23992
24015
  this.parent.timelineModule.updateTimeLineOnEditing([tempArray], args.action);
23993
24016
  }
24017
+ var flag = getValue('doubleClickTarget', this.parent.treeGrid.editModule);
24018
+ if (flag !== null) {
24019
+ setValue('doubleClickTarget', null, this.parent.treeGrid.editModule);
24020
+ }
23994
24021
  this.addSuccess(args);
23995
24022
  args = this.constructTaskAddedEventArgs(cAddedRecord, args.modifiedRecords, 'add');
23996
24023
  this.parent.trigger('actionComplete', args);
@@ -24897,7 +24924,7 @@ var Filter$1 = /** @__PURE__ @class */ (function () {
24897
24924
  var ganttElement = closest(element, '#' + this.parent.element.id)
24898
24925
  || element.querySelector('#' + this.parent.element.id);
24899
24926
  if ((!(this.filterMenuElement.contains(element)) && !isNullOrUndefined(ganttElement)) || element.nodeName === 'HTML'
24900
- || element.nodeName === 'DIV') {
24927
+ || ((element.nodeName === 'DIV') && (!element.classList.contains('e-day')))) {
24901
24928
  remove(this.filterMenuElement);
24902
24929
  this.parent.treeGrid.grid.notify('filter-menu-close', { isOpen: false });
24903
24930
  this.filterMenuElement = null;
@@ -27678,7 +27705,7 @@ var RowDD$1 = /** @__PURE__ @class */ (function () {
27678
27705
  if (this.dropPosition === 'topSegment' || this.dropPosition === 'bottomSegment') {
27679
27706
  var rowPosition = this.dropPosition === 'topSegment' ? 'Above' : 'Below';
27680
27707
  this.parent.editModule.addRowSelectedItem = droppedRecord;
27681
- this.parent.editModule.updateRealDataSource(draggedRecord, rowPosition);
27708
+ this.parent.editModule.updateRealDataSource([draggedRecord], rowPosition);
27682
27709
  delete this.parent.editModule.addRowSelectedItem;
27683
27710
  }
27684
27711
  }