@syncfusion/ej2-gantt 19.4.55 → 20.1.47-1460716

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 (212) hide show
  1. package/CHANGELOG.md +1072 -1047
  2. package/README.md +75 -75
  3. package/dist/ej2-gantt.umd.min.js +1 -10
  4. package/dist/ej2-gantt.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-gantt.es2015.js +341 -240
  6. package/dist/es6/ej2-gantt.es2015.js.map +1 -1
  7. package/dist/es6/ej2-gantt.es5.js +713 -598
  8. package/dist/es6/ej2-gantt.es5.js.map +1 -1
  9. package/dist/global/ej2-gantt.min.js +1 -10
  10. package/dist/global/ej2-gantt.min.js.map +1 -1
  11. package/dist/global/index.d.ts +0 -9
  12. package/dist/ts/components.ts +4 -0
  13. package/dist/ts/gantt/actions/actions.ts +18 -0
  14. package/dist/ts/gantt/actions/cell-edit.ts +606 -0
  15. package/dist/ts/gantt/actions/chart-scroll.ts +167 -0
  16. package/dist/ts/gantt/actions/column-menu.ts +35 -0
  17. package/dist/ts/gantt/actions/column-reorder.ts +52 -0
  18. package/dist/ts/gantt/actions/column-resize.ts +52 -0
  19. package/dist/ts/gantt/actions/connector-line-edit.ts +829 -0
  20. package/dist/ts/gantt/actions/context-menu.ts +754 -0
  21. package/dist/ts/gantt/actions/day-markers.ts +80 -0
  22. package/dist/ts/gantt/actions/dependency.ts +692 -0
  23. package/dist/ts/gantt/actions/dialog-edit.ts +2208 -0
  24. package/dist/ts/gantt/actions/edit.ts +3499 -0
  25. package/dist/ts/gantt/actions/excel-export.ts +61 -0
  26. package/dist/ts/gantt/actions/filter.ts +302 -0
  27. package/dist/ts/gantt/actions/keyboard.ts +306 -0
  28. package/dist/ts/gantt/actions/pdf-export.ts +214 -0
  29. package/dist/ts/gantt/actions/rowdragdrop.ts +839 -0
  30. package/dist/ts/gantt/actions/selection.ts +536 -0
  31. package/dist/ts/gantt/actions/sort.ts +98 -0
  32. package/dist/ts/gantt/actions/taskbar-edit.ts +1940 -0
  33. package/dist/ts/gantt/actions/toolbar.ts +489 -0
  34. package/dist/ts/gantt/actions/virtual-scroll.ts +60 -0
  35. package/dist/ts/gantt/base/common.ts +9 -0
  36. package/dist/ts/gantt/base/constant.ts +13 -0
  37. package/dist/ts/gantt/base/css-constants.ts +148 -0
  38. package/dist/ts/gantt/base/date-processor.ts +1257 -0
  39. package/dist/ts/gantt/base/enum.ts +372 -0
  40. package/dist/ts/gantt/base/gantt-chart.ts +1248 -0
  41. package/dist/ts/gantt/base/gantt.ts +4069 -0
  42. package/dist/ts/gantt/base/interface.ts +955 -0
  43. package/dist/ts/gantt/base/splitter.ts +174 -0
  44. package/dist/ts/gantt/base/task-processor.ts +2217 -0
  45. package/dist/ts/gantt/base/tree-grid.ts +694 -0
  46. package/dist/ts/gantt/base/utils.ts +208 -0
  47. package/dist/ts/gantt/export/export-helper.ts +552 -0
  48. package/dist/ts/gantt/export/pdf-base/dictionary.ts +152 -0
  49. package/dist/ts/gantt/export/pdf-base/pdf-borders.ts +277 -0
  50. package/dist/ts/gantt/export/pdf-base/pdf-grid-table.ts +901 -0
  51. package/dist/ts/gantt/export/pdf-base/pdf-style/gantt-theme.ts +131 -0
  52. package/dist/ts/gantt/export/pdf-base/pdf-style/style.ts +91 -0
  53. package/dist/ts/gantt/export/pdf-base/treegrid-layouter.ts +414 -0
  54. package/dist/ts/gantt/export/pdf-connector-line.ts +422 -0
  55. package/dist/ts/gantt/export/pdf-gantt.ts +282 -0
  56. package/dist/ts/gantt/export/pdf-taskbar.ts +395 -0
  57. package/dist/ts/gantt/export/pdf-timeline.ts +202 -0
  58. package/dist/ts/gantt/export/pdf-treegrid.ts +406 -0
  59. package/dist/ts/gantt/models/add-dialog-field-settings.ts +33 -0
  60. package/dist/ts/gantt/models/column.ts +464 -0
  61. package/dist/ts/gantt/models/day-working-time.ts +22 -0
  62. package/dist/ts/gantt/models/edit-dialog-field-settings.ts +33 -0
  63. package/dist/ts/gantt/models/edit-settings.ts +79 -0
  64. package/dist/ts/gantt/models/event-marker.ts +27 -0
  65. package/dist/ts/gantt/models/filter-settings.ts +53 -0
  66. package/dist/ts/gantt/models/holiday.ts +34 -0
  67. package/dist/ts/gantt/models/label-settings.ts +30 -0
  68. package/dist/ts/gantt/models/models.ts +36 -0
  69. package/dist/ts/gantt/models/resource-fields.ts +38 -0
  70. package/dist/ts/gantt/models/search-settings.ts +77 -0
  71. package/dist/ts/gantt/models/selection-settings.ts +56 -0
  72. package/dist/ts/gantt/models/sort-settings.ts +50 -0
  73. package/dist/ts/gantt/models/splitter-settings.ts +47 -0
  74. package/dist/ts/gantt/models/task-fields.ts +171 -0
  75. package/dist/ts/gantt/models/timeline-settings.ts +112 -0
  76. package/dist/ts/gantt/models/tooltip-settings.ts +46 -0
  77. package/dist/ts/gantt/renderer/chart-rows.ts +1838 -0
  78. package/dist/ts/gantt/renderer/connector-line.ts +1025 -0
  79. package/dist/ts/gantt/renderer/edit-tooltip.ts +228 -0
  80. package/dist/ts/gantt/renderer/event-marker.ts +96 -0
  81. package/dist/ts/gantt/renderer/nonworking-day.ts +205 -0
  82. package/dist/ts/gantt/renderer/render.ts +5 -0
  83. package/dist/ts/gantt/renderer/timeline.ts +1397 -0
  84. package/dist/ts/gantt/renderer/tooltip.ts +450 -0
  85. package/dist/ts/gantt/renderer/virtual-content-render.ts +50 -0
  86. package/license +9 -9
  87. package/package.json +80 -80
  88. package/src/gantt/actions/cell-edit.js +2 -1
  89. package/src/gantt/actions/dialog-edit.js +2 -1
  90. package/src/gantt/actions/edit.js +36 -9
  91. package/src/gantt/actions/rowdragdrop.js +37 -15
  92. package/src/gantt/actions/selection.js +3 -2
  93. package/src/gantt/actions/taskbar-edit.js +24 -24
  94. package/src/gantt/base/date-processor.js +0 -1
  95. package/src/gantt/base/gantt-chart.js +36 -5
  96. package/src/gantt/base/gantt-model.d.ts +779 -779
  97. package/src/gantt/base/gantt.d.ts +27 -27
  98. package/src/gantt/base/gantt.js +35 -76
  99. package/src/gantt/base/splitter.js +1 -0
  100. package/src/gantt/base/task-processor.js +13 -13
  101. package/src/gantt/base/tree-grid.js +3 -1
  102. package/src/gantt/export/pdf-base/treegrid-layouter.js +13 -13
  103. package/src/gantt/export/pdf-connector-line.js +11 -11
  104. package/src/gantt/export/pdf-gantt.js +24 -24
  105. package/src/gantt/export/pdf-taskbar.js +11 -11
  106. package/src/gantt/export/pdf-treegrid.js +13 -13
  107. package/src/gantt/models/add-dialog-field-settings-model.d.ts +21 -21
  108. package/src/gantt/models/add-dialog-field-settings.js +19 -19
  109. package/src/gantt/models/day-working-time-model.d.ts +11 -11
  110. package/src/gantt/models/day-working-time.js +19 -19
  111. package/src/gantt/models/edit-dialog-field-settings-model.d.ts +21 -21
  112. package/src/gantt/models/edit-dialog-field-settings.js +19 -19
  113. package/src/gantt/models/edit-settings-model.d.ts +50 -50
  114. package/src/gantt/models/edit-settings.js +19 -19
  115. package/src/gantt/models/event-marker-model.d.ts +16 -16
  116. package/src/gantt/models/event-marker.js +19 -19
  117. package/src/gantt/models/filter-settings-model.d.ts +34 -34
  118. package/src/gantt/models/filter-settings.js +19 -19
  119. package/src/gantt/models/holiday-model.d.ts +21 -21
  120. package/src/gantt/models/holiday.js +19 -19
  121. package/src/gantt/models/label-settings-model.d.ts +16 -16
  122. package/src/gantt/models/label-settings.js +19 -19
  123. package/src/gantt/models/resource-fields-model.d.ts +21 -21
  124. package/src/gantt/models/resource-fields.js +19 -19
  125. package/src/gantt/models/search-settings-model.d.ts +56 -56
  126. package/src/gantt/models/search-settings.js +19 -19
  127. package/src/gantt/models/selection-settings-model.d.ts +35 -35
  128. package/src/gantt/models/selection-settings.js +19 -19
  129. package/src/gantt/models/sort-settings-model.d.ts +24 -24
  130. package/src/gantt/models/sort-settings.js +19 -19
  131. package/src/gantt/models/splitter-settings-model.d.ts +30 -30
  132. package/src/gantt/models/splitter-settings.js +19 -19
  133. package/src/gantt/models/task-fields-model.d.ts +110 -110
  134. package/src/gantt/models/task-fields.js +19 -19
  135. package/src/gantt/models/timeline-settings-model.d.ts +71 -71
  136. package/src/gantt/models/timeline-settings.js +19 -19
  137. package/src/gantt/models/tooltip-settings-model.d.ts +26 -26
  138. package/src/gantt/models/tooltip-settings.js +19 -19
  139. package/src/gantt/renderer/chart-rows.js +49 -37
  140. package/src/gantt/renderer/connector-line.js +22 -18
  141. package/src/gantt/renderer/event-marker.js +1 -0
  142. package/src/gantt/renderer/nonworking-day.js +13 -6
  143. package/src/gantt/renderer/timeline.d.ts +1 -0
  144. package/src/gantt/renderer/timeline.js +51 -12
  145. package/src/gantt/renderer/tooltip.js +11 -3
  146. package/styles/bootstrap-dark.css +442 -427
  147. package/styles/bootstrap.css +442 -433
  148. package/styles/bootstrap4.css +454 -479
  149. package/styles/bootstrap5-dark.css +457 -433
  150. package/styles/bootstrap5.css +457 -433
  151. package/styles/fabric-dark.css +438 -421
  152. package/styles/fabric.css +445 -428
  153. package/styles/fluent-dark.css +1938 -0
  154. package/styles/fluent-dark.scss +1 -0
  155. package/styles/fluent.css +1938 -0
  156. package/styles/fluent.scss +1 -0
  157. package/styles/gantt/_all.scss +2 -2
  158. package/styles/gantt/_bootstrap-dark-definition.scss +210 -156
  159. package/styles/gantt/_bootstrap-definition.scss +211 -157
  160. package/styles/gantt/_bootstrap4-definition.scss +213 -158
  161. package/styles/gantt/_bootstrap5-definition.scss +215 -162
  162. package/styles/gantt/_fabric-dark-definition.scss +211 -157
  163. package/styles/gantt/_fabric-definition.scss +211 -157
  164. package/styles/gantt/_fluent-dark-definition.scss +1 -0
  165. package/styles/gantt/_fluent-definition.scss +215 -162
  166. package/styles/gantt/_fusionnew-definition.scss +214 -0
  167. package/styles/gantt/_highcontrast-definition.scss +211 -157
  168. package/styles/gantt/_highcontrast-light-definition.scss +211 -157
  169. package/styles/gantt/_layout.scss +1446 -1027
  170. package/styles/gantt/_material-dark-definition.scss +212 -157
  171. package/styles/gantt/_material-definition.scss +212 -157
  172. package/styles/gantt/_material3-definition.scss +215 -0
  173. package/styles/gantt/_tailwind-definition.scss +215 -161
  174. package/styles/gantt/_theme.scss +702 -668
  175. package/styles/gantt/bootstrap-dark.css +442 -427
  176. package/styles/gantt/bootstrap.css +442 -433
  177. package/styles/gantt/bootstrap4.css +454 -479
  178. package/styles/gantt/bootstrap5-dark.css +457 -433
  179. package/styles/gantt/bootstrap5.css +457 -433
  180. package/styles/gantt/fabric-dark.css +438 -421
  181. package/styles/gantt/fabric.css +445 -428
  182. package/styles/gantt/fluent-dark.css +1938 -0
  183. package/styles/gantt/fluent-dark.scss +22 -0
  184. package/styles/gantt/fluent.css +1938 -0
  185. package/styles/gantt/fluent.scss +22 -0
  186. package/styles/gantt/highcontrast-light.css +405 -405
  187. package/styles/gantt/highcontrast.css +444 -456
  188. package/styles/gantt/icons/_bootstrap-dark.scss +124 -113
  189. package/styles/gantt/icons/_bootstrap.scss +124 -113
  190. package/styles/gantt/icons/_bootstrap4.scss +124 -113
  191. package/styles/gantt/icons/_bootstrap5.scss +124 -112
  192. package/styles/gantt/icons/_fabric-dark.scss +124 -112
  193. package/styles/gantt/icons/_fabric.scss +124 -112
  194. package/styles/gantt/icons/_fluent-dark.scss +1 -0
  195. package/styles/gantt/icons/_fluent.scss +124 -112
  196. package/styles/gantt/icons/_fusionnew.scss +120 -0
  197. package/styles/gantt/icons/_highcontrast.scss +124 -112
  198. package/styles/gantt/icons/_material-dark.scss +124 -112
  199. package/styles/gantt/icons/_material.scss +124 -112
  200. package/styles/gantt/icons/_material3.scss +124 -0
  201. package/styles/gantt/icons/_tailwind-dark.scss +124 -113
  202. package/styles/gantt/icons/_tailwind.scss +124 -113
  203. package/styles/gantt/material-dark.css +446 -417
  204. package/styles/gantt/material.css +445 -419
  205. package/styles/gantt/tailwind-dark.css +452 -482
  206. package/styles/gantt/tailwind.css +449 -479
  207. package/styles/highcontrast-light.css +405 -405
  208. package/styles/highcontrast.css +444 -456
  209. package/styles/material-dark.css +446 -417
  210. package/styles/material.css +445 -419
  211. package/styles/tailwind-dark.css +452 -482
  212. package/styles/tailwind.css +449 -479
package/package.json CHANGED
@@ -1,80 +1,80 @@
1
- {
2
- "_from": "@syncfusion/ej2-gantt@*",
3
- "_id": "@syncfusion/ej2-gantt@19.4.54",
4
- "_inBundle": false,
5
- "_integrity": "sha512-MLuEBMN++SYGBbYyb4j7PpGp/92/ztO0MBIxUC18Fhzf7uYTEXHd5aHY2reGHsAENQa+MjUaHO44cm68Fz6cvA==",
6
- "_location": "/@syncfusion/ej2-gantt",
7
- "_phantomChildren": {},
8
- "_requested": {
9
- "type": "range",
10
- "registry": true,
11
- "raw": "@syncfusion/ej2-gantt@*",
12
- "name": "@syncfusion/ej2-gantt",
13
- "escapedName": "@syncfusion%2fej2-gantt",
14
- "scope": "@syncfusion",
15
- "rawSpec": "*",
16
- "saveSpec": null,
17
- "fetchSpec": "*"
18
- },
19
- "_requiredBy": [
20
- "/",
21
- "/@syncfusion/ej2",
22
- "/@syncfusion/ej2-angular-gantt",
23
- "/@syncfusion/ej2-react-gantt",
24
- "/@syncfusion/ej2-vue-gantt"
25
- ],
26
- "_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-19.4.54.tgz",
27
- "_shasum": "3e6e2c9c949ce93b3398f386e09656607022e4d5",
28
- "_spec": "@syncfusion/ej2-gantt@*",
29
- "_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
30
- "author": {
31
- "name": "Syncfusion Inc."
32
- },
33
- "bugs": {
34
- "url": "https://github.com/syncfusion/ej2-gantt/issues"
35
- },
36
- "bundleDependencies": false,
37
- "dependencies": {
38
- "@syncfusion/ej2-base": "~19.4.52",
39
- "@syncfusion/ej2-buttons": "~19.4.55",
40
- "@syncfusion/ej2-calendars": "~19.4.55",
41
- "@syncfusion/ej2-data": "~19.4.54",
42
- "@syncfusion/ej2-dropdowns": "~19.4.55",
43
- "@syncfusion/ej2-grids": "~19.4.55",
44
- "@syncfusion/ej2-inputs": "~19.4.52",
45
- "@syncfusion/ej2-layouts": "~19.4.52",
46
- "@syncfusion/ej2-lists": "~19.4.55",
47
- "@syncfusion/ej2-navigations": "~19.4.55",
48
- "@syncfusion/ej2-popups": "~19.4.53",
49
- "@syncfusion/ej2-richtexteditor": "~19.4.55",
50
- "@syncfusion/ej2-treegrid": "~19.4.55"
51
- },
52
- "deprecated": false,
53
- "description": "Essential JS 2 Gantt Component",
54
- "devDependencies": {},
55
- "es2015": "./dist/es6/ej2-gantt.es2015.js",
56
- "homepage": "https://github.com/syncfusion/ej2-gantt#readme",
57
- "keywords": [
58
- "ej2",
59
- "syncfusion",
60
- "ej2-gantt",
61
- "web-components",
62
- "JavaScript",
63
- "TypeScript",
64
- "gantt",
65
- "ganttChart",
66
- "gantt-chart",
67
- "taskbar"
68
- ],
69
- "license": "SEE LICENSE IN license",
70
- "main": "./dist/ej2-gantt.umd.min.js",
71
- "module": "./index.js",
72
- "name": "@syncfusion/ej2-gantt",
73
- "repository": {
74
- "type": "git",
75
- "url": "git+https://github.com/syncfusion/ej2-gantt.git"
76
- },
77
- "typings": "index.d.ts",
78
- "version": "19.4.55",
79
- "sideEffects": false
80
- }
1
+ {
2
+ "_from": "@syncfusion/ej2-gantt@*",
3
+ "_id": "@syncfusion/ej2-gantt@19.10.10",
4
+ "_inBundle": false,
5
+ "_integrity": "sha512-kJWTMNP/9/2FtwxZ6khAoLriF7D+LPHkkeCwBLOYy2+QaggPgOyqD6Kxf+EUvIcy88okK5d+aRAVfm35iY0dzg==",
6
+ "_location": "/@syncfusion/ej2-gantt",
7
+ "_phantomChildren": {},
8
+ "_requested": {
9
+ "type": "range",
10
+ "registry": true,
11
+ "raw": "@syncfusion/ej2-gantt@*",
12
+ "name": "@syncfusion/ej2-gantt",
13
+ "escapedName": "@syncfusion%2fej2-gantt",
14
+ "scope": "@syncfusion",
15
+ "rawSpec": "*",
16
+ "saveSpec": null,
17
+ "fetchSpec": "*"
18
+ },
19
+ "_requiredBy": [
20
+ "/",
21
+ "/@syncfusion/ej2",
22
+ "/@syncfusion/ej2-angular-gantt",
23
+ "/@syncfusion/ej2-react-gantt",
24
+ "/@syncfusion/ej2-vue-gantt"
25
+ ],
26
+ "_resolved": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-gantt/-/ej2-gantt-19.10.10.tgz",
27
+ "_shasum": "8340614ed1ccd8ec22e6082223b54f2226d905d1",
28
+ "_spec": "@syncfusion/ej2-gantt@*",
29
+ "_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
30
+ "author": {
31
+ "name": "Syncfusion Inc."
32
+ },
33
+ "bugs": {
34
+ "url": "https://github.com/syncfusion/ej2-gantt/issues"
35
+ },
36
+ "bundleDependencies": false,
37
+ "dependencies": {
38
+ "@syncfusion/ej2-base": "~20.1.47",
39
+ "@syncfusion/ej2-buttons": "~20.1.47",
40
+ "@syncfusion/ej2-calendars": "~20.1.47",
41
+ "@syncfusion/ej2-data": "~20.1.47",
42
+ "@syncfusion/ej2-dropdowns": "~20.1.47",
43
+ "@syncfusion/ej2-grids": "~20.1.47",
44
+ "@syncfusion/ej2-inputs": "~20.1.47",
45
+ "@syncfusion/ej2-layouts": "~20.1.47",
46
+ "@syncfusion/ej2-lists": "~20.1.47",
47
+ "@syncfusion/ej2-navigations": "~20.1.47",
48
+ "@syncfusion/ej2-popups": "~20.1.47",
49
+ "@syncfusion/ej2-richtexteditor": "~20.1.47",
50
+ "@syncfusion/ej2-treegrid": "~20.1.47"
51
+ },
52
+ "deprecated": false,
53
+ "description": "Essential JS 2 Gantt Component",
54
+ "devDependencies": {},
55
+ "es2015": "./dist/es6/ej2-gantt.es2015.js",
56
+ "homepage": "https://github.com/syncfusion/ej2-gantt#readme",
57
+ "keywords": [
58
+ "ej2",
59
+ "syncfusion",
60
+ "ej2-gantt",
61
+ "web-components",
62
+ "JavaScript",
63
+ "TypeScript",
64
+ "gantt",
65
+ "ganttChart",
66
+ "gantt-chart",
67
+ "taskbar"
68
+ ],
69
+ "license": "SEE LICENSE IN license",
70
+ "main": "./dist/ej2-gantt.umd.min.js",
71
+ "module": "./index.js",
72
+ "name": "@syncfusion/ej2-gantt",
73
+ "repository": {
74
+ "type": "git",
75
+ "url": "git+https://github.com/syncfusion/ej2-gantt.git"
76
+ },
77
+ "typings": "index.d.ts",
78
+ "version": "20.1.47-1460716",
79
+ "sideEffects": false
80
+ }
@@ -48,7 +48,8 @@ var CellEdit = /** @class */ (function () {
48
48
  args.cancel = true;
49
49
  return;
50
50
  }
51
- if (data.hasChildRecords && (field === taskSettings.endDate || field === taskSettings.duration
51
+ if (data.hasChildRecords && ((field === taskSettings.endDate && ((!isNullOrUndefined(data['isManual']) &&
52
+ data['isManual'] == false) || this.parent.taskMode == 'Auto')) || field === taskSettings.duration
52
53
  || field === taskSettings.dependency || field === taskSettings.progress
53
54
  || field === taskSettings.work || field === 'taskType')) {
54
55
  args.cancel = true;
@@ -1537,7 +1537,8 @@ var DialogEdit = /** @class */ (function () {
1537
1537
  disabled = true;
1538
1538
  }
1539
1539
  if (this.editedRecord.hasChildRecords) {
1540
- if (column.field === this.parent.taskFields.endDate || column.field === this.parent.taskFields.duration ||
1540
+ if ((column.field === this.parent.taskFields.endDate && ((!isNullOrUndefined(this.editedRecord['isManual']) &&
1541
+ this.editedRecord['isManual'] == false) || this.parent.taskMode == 'Auto')) || column.field === this.parent.taskFields.duration ||
1541
1542
  column.field === this.parent.taskFields.progress || column.field === this.parent.taskFields.work ||
1542
1543
  column.field === 'taskType') {
1543
1544
  disabled = true;
@@ -2348,7 +2348,15 @@ var Edit = /** @class */ (function () {
2348
2348
  }
2349
2349
  /* data Source update */
2350
2350
  if (!isNullOrUndefined(parentItem)) {
2351
- childIndex = parentItem.childRecords.indexOf(this.addRowSelectedItem);
2351
+ if (rowPosition == 'Above') {
2352
+ childIndex = parentItem.childRecords.indexOf(this.addRowSelectedItem);
2353
+ }
2354
+ else if (rowPosition == 'Below') {
2355
+ childIndex = parentItem.childRecords.indexOf(this.addRowSelectedItem) + 1;
2356
+ }
2357
+ else {
2358
+ childIndex = parentItem.childRecords.length;
2359
+ }
2352
2360
  /*Child collection update*/
2353
2361
  parentItem.childRecords.splice(childIndex, 0, record);
2354
2362
  if ((this.parent.dataSource instanceof DataManager &&
@@ -2356,12 +2364,9 @@ var Edit = /** @class */ (function () {
2356
2364
  !isNullOrUndefined(this.parent.dataSource)) {
2357
2365
  var child = this.parent.taskFields.child;
2358
2366
  if (parentItem.taskData[child] && parentItem.taskData[child].length > 0) {
2359
- if (rowPosition === 'Above') {
2367
+ if (rowPosition === 'Above' || rowPosition === 'Below') {
2360
2368
  parentItem.taskData[child].splice(childIndex, 0, record.taskData);
2361
2369
  }
2362
- else if (rowPosition === 'Below') {
2363
- parentItem.taskData[child].splice(childIndex + 1, 0, record.taskData);
2364
- }
2365
2370
  else {
2366
2371
  parentItem.taskData[child].push(record.taskData);
2367
2372
  }
@@ -2427,11 +2432,27 @@ var Edit = /** @class */ (function () {
2427
2432
  }
2428
2433
  };
2429
2434
  Edit.prototype.refreshRecordInImmutableMode = function () {
2435
+ var _loop_1 = function (i) {
2436
+ var originalData = this_1.parent.modifiedRecords[i];
2437
+ var treeIndex = this_1.parent.allowRowDragAndDrop ? 1 : 0;
2438
+ var uniqueTaskID = this_1.parent.taskFields.id;
2439
+ originalIndex = this_1.parent.currentViewData.findIndex(function (data) {
2440
+ return (data[uniqueTaskID] == originalData[uniqueTaskID]);
2441
+ });
2442
+ if (this_1.parent.treeGrid.getRows()[originalIndex]) {
2443
+ this_1.parent.treeGrid.renderModule.cellRender({
2444
+ data: originalData, cell: this_1.parent.treeGrid.getRows()[originalIndex].cells[this_1.parent.treeColumnIndex + treeIndex],
2445
+ column: this_1.parent.treeGrid.grid.getColumns()[this_1.parent.treeColumnIndex],
2446
+ requestType: 'rowDragAndDrop'
2447
+ });
2448
+ this_1.parent.treeGrid.renderModule.RowModifier({
2449
+ data: originalData, row: this_1.parent.treeGrid.getRows()[originalIndex], rowHeight: this_1.parent.rowHeight
2450
+ });
2451
+ }
2452
+ };
2453
+ var this_1 = this, originalIndex;
2430
2454
  for (var i = 0; i < this.parent.modifiedRecords.length; i++) {
2431
- var originalData = this.parent.modifiedRecords[i];
2432
- var dataId = this.parent.viewType === 'ProjectView' ?
2433
- originalData.ganttProperties.taskId : originalData.ganttProperties.rowUniqueID;
2434
- this.parent.treeGrid.grid.setRowData(dataId, originalData);
2455
+ _loop_1(i);
2435
2456
  }
2436
2457
  };
2437
2458
  /**
@@ -2809,6 +2830,9 @@ var Edit = /** @class */ (function () {
2809
2830
  }
2810
2831
  this.addSuccess(args);
2811
2832
  args = this.constructTaskAddedEventArgs(cAddedRecord, args.modifiedRecords, 'add');
2833
+ if (this.dialogModule.isAddNewResource && !this.parent.isEdit && this.parent.taskFields.work) {
2834
+ this.parent.dataOperation.updateWorkWithDuration(cAddedRecord[0]);
2835
+ }
2812
2836
  this.parent.trigger('actionComplete', args);
2813
2837
  if (this.dialogModule.dialog && !this.dialogModule.dialogObj.isDestroyed) {
2814
2838
  this.dialogModule.dialogObj.hide();
@@ -3185,15 +3209,18 @@ var Edit = /** @class */ (function () {
3185
3209
  if (this.dropPosition === 'topSegment' || this.dropPosition === 'bottomSegment') {
3186
3210
  draggedRec[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.parentID];
3187
3211
  draggedRec.taskData[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.parentID];
3212
+ draggedRec.ganttProperties['parentId'] = droppedRec[this.parent.taskFields.parentID];
3188
3213
  }
3189
3214
  else {
3190
3215
  draggedRec[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.id];
3191
3216
  draggedRec.taskData[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.id];
3217
+ draggedRec.ganttProperties['parentId'] = droppedRec[this.parent.taskFields.id];
3192
3218
  }
3193
3219
  }
3194
3220
  else {
3195
3221
  draggedRec[this.parent.taskFields.parentID] = null;
3196
3222
  draggedRec.taskData[this.parent.taskFields.parentID] = null;
3223
+ draggedRec.ganttProperties['parentId'] = null;
3197
3224
  }
3198
3225
  }
3199
3226
  };
@@ -249,33 +249,55 @@ var RowDD = /** @class */ (function () {
249
249
  var data_1 = gObj.flatData;
250
250
  var startIndex = void 0;
251
251
  var endIndex = void 0;
252
+ var ganttData_1 = this_1.parent.dataSource;
253
+ var uniqueTaskID_1 = this_1.parent.taskFields.id;
252
254
  if (draggedRecord.index < droppedRecord.index) {
253
255
  startIndex = draggedRecord.index;
254
- endIndex = droppedRecord.index;
256
+ var _loop_2 = function (i_1) {
257
+ var currentData = this_1.parent.currentViewData.filter(function (e) {
258
+ return e[uniqueTaskID_1] === ganttData_1[i_1][uniqueTaskID_1];
259
+ })[0];
260
+ if (currentData.index > droppedRecord.index) {
261
+ endIndex = currentData.index;
262
+ return "break";
263
+ }
264
+ };
265
+ for (var i_1 = 0; i_1 < ganttData_1.length; i_1++) {
266
+ var state_2 = _loop_2(i_1);
267
+ if (state_2 === "break")
268
+ break;
269
+ }
255
270
  }
256
271
  else {
257
272
  startIndex = droppedRecord.index;
258
- var rootChildRecord = draggedRecord;
259
- if (rootChildRecord.childRecords.length > 0) {
260
- do {
261
- rootChildRecord = rootChildRecord.childRecords[rootChildRecord.childRecords.length - 1];
262
- } while (rootChildRecord.childRecords.length > 0);
273
+ var _loop_3 = function (i_2) {
274
+ var currentData = this_1.parent.currentViewData.filter(function (e) {
275
+ return e[uniqueTaskID_1] === ganttData_1[i_2][uniqueTaskID_1];
276
+ })[0];
277
+ if (currentData.index > draggedRecord.index) {
278
+ endIndex = currentData.index;
279
+ return "break";
280
+ }
281
+ };
282
+ for (var i_2 = 0; i_2 < ganttData_1.length; i_2++) {
283
+ var state_3 = _loop_3(i_2);
284
+ if (state_3 === "break")
285
+ break;
263
286
  }
264
- endIndex = rootChildRecord.index;
265
287
  }
266
- var _loop_2 = function (i_1) {
267
- if (!isNullOrUndefined(data_1[i_1])) {
268
- data_1[i_1].index = i_1;
269
- if (!isNullOrUndefined(data_1[i_1].parentItem)) {
288
+ var _loop_4 = function (i_3) {
289
+ if (!isNullOrUndefined(data_1[i_3])) {
290
+ data_1[i_3].index = i_3;
291
+ if (!isNullOrUndefined(data_1[i_3].parentItem)) {
270
292
  var updatedParent = data_1.filter(function (e) {
271
- return e.uniqueID === data_1[i_1].parentUniqueID;
293
+ return e.uniqueID === data_1[i_3].parentUniqueID;
272
294
  })[0];
273
- data_1[i_1].parentItem.index = updatedParent.index;
295
+ data_1[i_3].parentItem.index = updatedParent.index;
274
296
  }
275
297
  }
276
298
  };
277
- for (var i_1 = startIndex; i_1 <= endIndex; i_1++) {
278
- _loop_2(i_1);
299
+ for (var i_3 = startIndex; i_3 <= endIndex; i_3++) {
300
+ _loop_4(i_3);
279
301
  }
280
302
  }
281
303
  gObj.rowDragAndDropModule.refreshDataSource();
@@ -133,8 +133,9 @@ var Selection = /** @class */ (function () {
133
133
  }
134
134
  this.addRemoveClass(index);
135
135
  this.selectedRowIndexes = extend([], this.getSelectedRowIndexes(), [], true);
136
- if (this.selectedRowIndexes.length == 0) {
137
- this.parent.setProperties({ selectedRowIndex: -1 }, true);
136
+ this.parent.setProperties({ selectedRowIndex: -1 }, true);
137
+ if (this.selectedRowIndexes.length === 1) {
138
+ this.parent.setProperties({ selectedRowIndex: this.selectedRowIndexes[0] }, true);
138
139
  }
139
140
  if (!isNullOrUndefined(this.parent.toolbarModule)) {
140
141
  this.parent.toolbarModule.refreshToolbarItems();
@@ -1,27 +1,27 @@
1
- var __extends = (this && this.__extends) || (function () {
2
- var extendStatics = function (d, b) {
3
- extendStatics = Object.setPrototypeOf ||
4
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
6
- return extendStatics(d, b);
7
- };
8
- return function (d, b) {
9
- extendStatics(d, b);
10
- function __() { this.constructor = d; }
11
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
12
- };
13
- })();
14
- var __assign = (this && this.__assign) || function () {
15
- __assign = Object.assign || function(t) {
16
- for (var s, i = 1, n = arguments.length; i < n; i++) {
17
- s = arguments[i];
18
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
19
- t[p] = s[p];
20
- }
21
- return t;
22
- };
23
- return __assign.apply(this, arguments);
24
- };
1
+ var __extends = (this && this.__extends) || (function () {
2
+ var extendStatics = function (d, b) {
3
+ extendStatics = Object.setPrototypeOf ||
4
+ ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
+ function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
6
+ return extendStatics(d, b);
7
+ };
8
+ return function (d, b) {
9
+ extendStatics(d, b);
10
+ function __() { this.constructor = d; }
11
+ d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
12
+ };
13
+ })();
14
+ var __assign = (this && this.__assign) || function () {
15
+ __assign = Object.assign || function(t) {
16
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
17
+ s = arguments[i];
18
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
19
+ t[p] = s[p];
20
+ }
21
+ return t;
22
+ };
23
+ return __assign.apply(this, arguments);
24
+ };
25
25
  import { isNullOrUndefined, createElement, extend, addClass, remove, removeClass, closest, merge } from '@syncfusion/ej2-base';
26
26
  import { parentsUntil } from '../base/utils';
27
27
  import { DateProcessor } from '../base/date-processor';
@@ -282,7 +282,6 @@ var DateProcessor = /** @class */ (function () {
282
282
  tDuration = this.parent.editModule.taskbarEditModule.sumOfDuration(ganttProperties.segments);
283
283
  }
284
284
  else {
285
- // eslint-disable-next-line
286
285
  if (!isNullOrUndefined(ganttProperties.startDate) && !isNullOrUndefined(ganttProperties.endDate) &&
287
286
  (ganttProperties.startDate).getTime() === (ganttProperties.endDate).getTime() && !isNullOrUndefined(ganttData.taskData[this.parent.taskFields.milestone])) {
288
287
  tDuration = 1;
@@ -16,6 +16,7 @@ var GanttChart = /** @class */ (function () {
16
16
  this.chartTimelineContainer = null;
17
17
  this.rangeViewContainer =
18
18
  createElement('div', { className: cls.rangeContainer });
19
+ this.rangeViewContainer.setAttribute("role", "RangeContainer");
19
20
  this.virtualRender = new VirtualContentRenderer(this.parent);
20
21
  this.addEventListener();
21
22
  }
@@ -170,6 +171,7 @@ var GanttChart = /** @class */ (function () {
170
171
  GanttChart.prototype.renderTimelineContainer = function () {
171
172
  this.chartTimelineContainer =
172
173
  createElement('div', { className: cls.timelineHeaderContainer });
174
+ this.chartTimelineContainer.setAttribute("role", "TimelineHeader");
173
175
  this.chartElement.appendChild(this.chartTimelineContainer);
174
176
  };
175
177
  /**
@@ -209,8 +211,19 @@ var GanttChart = /** @class */ (function () {
209
211
  //empty row height
210
212
  var emptydivHeight = 36;
211
213
  var emptyHeight = this.parent.contentHeight === 0 ? this.parent.flatData.length > 1 ? emptydivHeight : 0 : this.parent.contentHeight;
212
- this.chartBodyContent.style.height = formatUnit(emptyHeight);
213
- //let element: HTMLElement = this.chartTimelineContainer.querySelector('.' + cls.timelineHeaderTableContainer);
214
+ var contentElement = this.parent.element.getElementsByClassName('e-chart-scroll-container e-content')[0];
215
+ if (emptyHeight >= contentElement['offsetHeight']) {
216
+ this.chartBodyContent.style.height = formatUnit(emptyHeight);
217
+ }
218
+ else {
219
+ var scrollHeight = this.parent.element.getElementsByClassName('e-chart-rows-container')[0]['offsetHeight'];
220
+ if (contentElement['offsetHeight'] >= scrollHeight) {
221
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] - 17 + 'px';
222
+ }
223
+ else {
224
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] + 'px';
225
+ }
226
+ } //let element: HTMLElement = this.chartTimelineContainer.querySelector('.' + cls.timelineHeaderTableContainer);
214
227
  this.chartBodyContent.style.width = formatUnit(this.parent.timelineModule.totalTimelineWidth);
215
228
  this.setVirtualHeight();
216
229
  this.parent.notify('updateHeight', {});
@@ -242,7 +255,21 @@ var GanttChart = /** @class */ (function () {
242
255
  if (this.chartBodyContent.clientHeight < this.chartBodyContainer.clientHeight) {
243
256
  if (lastRow) {
244
257
  addClass(lastRow.querySelectorAll('td'), 'e-lastrow');
245
- this.chartBodyContent.style.height = formatUnit(this.parent.contentHeight + 1);
258
+ var emptydivHeight = 36;
259
+ var emptyHeight = this.parent.contentHeight === 0 ? this.parent.flatData.length > 1 ? emptydivHeight : 0 : this.parent.contentHeight;
260
+ var contentElement = this.parent.element.getElementsByClassName('e-chart-scroll-container e-content')[0];
261
+ if (emptyHeight >= contentElement['offsetHeight']) {
262
+ this.chartBodyContent.style.height = formatUnit(emptyHeight);
263
+ }
264
+ else {
265
+ var scrollHeight = this.parent.element.getElementsByClassName('e-chart-rows-container')[0]['offsetHeight'];
266
+ if (contentElement['offsetHeight'] >= scrollHeight) {
267
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] - 17 + 'px';
268
+ }
269
+ else {
270
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] + 'px';
271
+ }
272
+ }
246
273
  }
247
274
  }
248
275
  }
@@ -374,7 +401,7 @@ var GanttChart = /** @class */ (function () {
374
401
  var target = e.target;
375
402
  var isOnTaskbarElement = e.target.classList.contains(cls.taskBarMainContainer)
376
403
  || closest(e.target, '.' + cls.taskBarMainContainer);
377
- if (closest(target, '.e-gantt-parent-taskbar')) {
404
+ if (closest(target, '.e-gantt-parent-taskbar') && !this.parent.editSettings.allowEditing) {
378
405
  this.chartExpandCollapseRequest(e);
379
406
  }
380
407
  else if (!isOnTaskbarElement && this.parent.autoFocusTasks) {
@@ -898,6 +925,10 @@ var GanttChart = /** @class */ (function () {
898
925
  $target.classList.contains('e-headercell') || $target.closest('.e-segmented-taskbar')) {
899
926
  e.preventDefault();
900
927
  }
928
+ if (isTab && $target.classList.contains('e-rowdragdrop')) {
929
+ this.parent.treeGrid.grid.notify('key-pressed', e);
930
+ return;
931
+ }
901
932
  if ($target.classList.contains('e-rowcell') && (nextElement && nextElement.classList.contains('e-rowcell')) ||
902
933
  $target.classList.contains('e-headercell')) { // eslint-disable-line
903
934
  if (isTab) {
@@ -940,7 +971,7 @@ var GanttChart = /** @class */ (function () {
940
971
  else {
941
972
  this.manageFocus($target, 'remove', true);
942
973
  }
943
- if (nextElement.classList.contains('e-rowcell')) {
974
+ if (nextElement.classList.contains('e-rowcell') && $target.nextElementSibling) {
944
975
  if (!$target.classList.contains('e-rowcell')) {
945
976
  this.parent.treeGrid.grid.notify('key-pressed', e);
946
977
  var fmodule = getValue('focusModule', this.parent.treeGrid.grid);