@progress/kendo-angular-treeview 6.0.2-dev.202202251428 → 7.0.0-dev.202204131935

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 (328) hide show
  1. package/bundles/kendo-angular-treeview.umd.js +5 -0
  2. package/{dist/es2015/check-mode.d.ts → check-mode.d.ts} +0 -0
  3. package/{dist/es2015/check.directive.d.ts → check.directive.d.ts} +5 -2
  4. package/{dist/es2015/checkable-settings.d.ts → checkable-settings.d.ts} +0 -0
  5. package/{dist/es2015/checkbox → checkbox}/checkbox.component.d.ts +7 -4
  6. package/{dist/es2015/checkbox → checkbox}/checkbox.module.d.ts +5 -0
  7. package/{dist/es2015/checkbox → checkbox}/checked-state.d.ts +0 -0
  8. package/{dist/es2015/data-bound-component.d.ts → data-bound-component.d.ts} +3 -0
  9. package/{dist/es2015/data-change-notification.service.d.ts → data-change-notification.service.d.ts} +0 -0
  10. package/{dist/es2015/default-callbacks.d.ts → default-callbacks.d.ts} +0 -0
  11. package/{dist/es2015/disable.directive.d.ts → disable.directive.d.ts} +4 -1
  12. package/{dist/es2015/drag-and-drop → drag-and-drop}/drag-and-drop-editing.directive.d.ts +4 -1
  13. package/{dist/es2015/drag-and-drop → drag-and-drop}/drag-and-drop-utils.d.ts +0 -0
  14. package/{dist/es2015/drag-and-drop → drag-and-drop}/drag-and-drop.directive.d.ts +4 -1
  15. package/{dist/es2015/drag-and-drop → drag-and-drop}/drag-clue/drag-clue-template.directive.d.ts +3 -0
  16. package/{dist/es2015/drag-and-drop → drag-and-drop}/drag-clue/drag-clue.component.d.ts +4 -1
  17. package/{dist/es2015/drag-and-drop → drag-and-drop}/drag-clue/drag-clue.service.d.ts +3 -0
  18. package/{dist/es2015/drag-and-drop → drag-and-drop}/drop-hint/drop-hint-template.directive.d.ts +3 -0
  19. package/{dist/es2015/drag-and-drop → drag-and-drop}/drop-hint/drop-hint.component.d.ts +3 -0
  20. package/{dist/es2015/drag-and-drop → drag-and-drop}/drop-hint/drop-hint.service.d.ts +3 -0
  21. package/{dist/es2015/drag-and-drop → drag-and-drop}/editing-services/drag-and-drop-asset.service.d.ts +6 -2
  22. package/{dist/es2015/drag-and-drop → drag-and-drop}/editing-services/flat-editing.service.d.ts +0 -0
  23. package/{dist/es2015/drag-and-drop → drag-and-drop}/editing-services/hierarchy-editing.service.d.ts +0 -0
  24. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/drop-action.d.ts +0 -0
  25. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/drop-position.d.ts +0 -0
  26. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/editing-service.d.ts +0 -0
  27. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/preventable-event.d.ts +0 -0
  28. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/scroll-direction.d.ts +0 -0
  29. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/scroll-settings.d.ts +0 -0
  30. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/tree-item-filter-state.d.ts +0 -0
  31. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/treeitem-add-remove-args.d.ts +0 -0
  32. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/treeitem-drag-event.d.ts +2 -0
  33. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/treeitem-drag-start-event.d.ts +0 -0
  34. package/{dist/es2015/drag-and-drop → drag-and-drop}/models/treeitem-drop-event.d.ts +0 -0
  35. package/{dist/es2015/drag-and-drop → drag-and-drop}/models.d.ts +0 -0
  36. package/{dist/es2015 → esm2015}/check-mode.js +1 -0
  37. package/{dist/es2015 → esm2015}/check.directive.js +23 -35
  38. package/{dist/es → esm2015}/checkable-settings.js +1 -0
  39. package/{dist/es2015 → esm2015}/checkbox/checkbox.component.js +47 -51
  40. package/esm2015/checkbox/checkbox.module.js +27 -0
  41. package/{dist/es2015 → esm2015}/checkbox/checked-state.js +1 -0
  42. package/esm2015/data-bound-component.js +19 -0
  43. package/{dist/es2015 → esm2015}/data-change-notification.service.js +0 -0
  44. package/{dist/es2015 → esm2015}/default-callbacks.js +0 -0
  45. package/{dist/es2015 → esm2015}/disable.directive.js +18 -24
  46. package/{dist/es2015 → esm2015}/drag-and-drop/drag-and-drop-editing.directive.js +14 -16
  47. package/{dist/es2015 → esm2015}/drag-and-drop/drag-and-drop-utils.js +7 -11
  48. package/{dist/es2015 → esm2015}/drag-and-drop/drag-and-drop.directive.js +48 -51
  49. package/{dist/es2015 → esm2015}/drag-and-drop/drag-clue/drag-clue-template.directive.js +14 -12
  50. package/esm2015/drag-and-drop/drag-clue/drag-clue.component.js +85 -0
  51. package/{dist/es2015 → esm2015}/drag-and-drop/drag-clue/drag-clue.service.js +9 -9
  52. package/{dist/es2015 → esm2015}/drag-and-drop/drop-hint/drop-hint-template.directive.js +14 -12
  53. package/esm2015/drag-and-drop/drop-hint/drop-hint.component.js +79 -0
  54. package/{dist/es2015 → esm2015}/drag-and-drop/drop-hint/drop-hint.service.js +9 -9
  55. package/{dist/es2015 → esm2015}/drag-and-drop/editing-services/drag-and-drop-asset.service.js +7 -0
  56. package/{dist/es2015 → esm2015}/drag-and-drop/editing-services/flat-editing.service.js +0 -0
  57. package/{dist/es2015 → esm2015}/drag-and-drop/editing-services/hierarchy-editing.service.js +0 -0
  58. package/{dist/es → esm2015}/drag-and-drop/models/drop-action.js +0 -0
  59. package/{dist/es → esm2015}/drag-and-drop/models/drop-position.js +0 -0
  60. package/{dist/es2015 → esm2015}/drag-and-drop/models/editing-service.js +1 -0
  61. package/{dist/es2015 → esm2015}/drag-and-drop/models/preventable-event.js +0 -0
  62. package/{dist/es → esm2015}/drag-and-drop/models/scroll-direction.js +0 -0
  63. package/{dist/es → esm2015}/drag-and-drop/models/scroll-settings.js +1 -0
  64. package/{dist/es → esm2015}/drag-and-drop/models/tree-item-filter-state.js +1 -0
  65. package/{dist/es → esm2015}/drag-and-drop/models/treeitem-add-remove-args.js +1 -0
  66. package/{dist/es2015 → esm2015}/drag-and-drop/models/treeitem-drag-event.js +2 -0
  67. package/{dist/es2015 → esm2015}/drag-and-drop/models/treeitem-drag-start-event.js +0 -0
  68. package/{dist/es2015 → esm2015}/drag-and-drop/models/treeitem-drop-event.js +0 -0
  69. package/{dist/es → esm2015}/drag-and-drop/models.js +3 -0
  70. package/{dist/es2015 → esm2015}/expand-state.service.js +8 -10
  71. package/{dist/es2015 → esm2015}/expand.directive.js +22 -31
  72. package/esm2015/expandable-component.js +19 -0
  73. package/{dist/es → esm2015}/filter-expand-settings.interface.js +1 -0
  74. package/{dist/es → esm2015}/filter-state.interface.js +1 -0
  75. package/{dist/es2015 → esm2015}/filtering-base.js +13 -13
  76. package/{dist/es2015 → esm2015}/flat-binding.directive.js +20 -34
  77. package/{dist/es2015 → esm2015}/funcs.js +0 -0
  78. package/{dist/es2015 → esm2015}/hierarchy-binding.directive.js +23 -33
  79. package/{dist/es2015 → esm2015}/index-builder.service.js +8 -10
  80. package/{dist/es2015/shared.module.d.ts → esm2015/kendo-angular-treeview.js} +2 -3
  81. package/esm2015/load-more/load-more-button-template.directive.js +31 -0
  82. package/{dist/es → esm2015}/load-more/load-more-request-args.js +1 -0
  83. package/{dist/es2015 → esm2015}/load-more/load-more-utils.js +0 -0
  84. package/{dist/es2015 → esm2015}/load-more/load-more.directive.js +21 -28
  85. package/{dist/es → esm2015}/load-more/load-more.service.js +1 -0
  86. package/{dist/es2015 → esm2015}/loading-indicator.directive.js +18 -22
  87. package/esm2015/loading-notification.service.js +23 -0
  88. package/{dist/es → esm2015}/main.js +0 -0
  89. package/{dist/es → esm2015}/navigation/navigation-item.interface.js +1 -0
  90. package/{dist/es2015 → esm2015}/navigation/navigation-model.js +0 -4
  91. package/{dist/es → esm2015}/navigation/navigation-state.interface.js +1 -0
  92. package/{dist/es2015 → esm2015}/navigation/navigation.service.js +9 -9
  93. package/{dist/es2015 → esm2015}/node-children.service.js +8 -10
  94. package/{dist/es → esm2015}/node-click-event.interface.js +1 -0
  95. package/{dist/es2015 → esm2015}/node-template.directive.js +14 -12
  96. package/{dist/es2015 → esm2015}/package-metadata.js +1 -1
  97. package/{dist/es2015 → esm2015}/selection/select.directive.js +25 -35
  98. package/{dist/es → esm2015}/selection/selectable-settings.js +1 -0
  99. package/{dist/es → esm2015}/selection/selection-mode.js +1 -0
  100. package/{dist/es2015 → esm2015}/selection/selection.service.js +8 -10
  101. package/{dist/es2015 → esm2015}/shared.module.js +63 -16
  102. package/{dist/es → esm2015}/size.js +1 -0
  103. package/{dist/es → esm2015}/treeitem-lookup.interface.js +1 -0
  104. package/{dist/es → esm2015}/treeitem.interface.js +1 -0
  105. package/{dist/es2015 → esm2015}/treeview-filter-settings.js +0 -0
  106. package/{dist/es2015 → esm2015}/treeview-group.component.js +264 -135
  107. package/{dist/es2015 → esm2015}/treeview-item-content.directive.js +20 -30
  108. package/{dist/es2015 → esm2015}/treeview-item.directive.js +43 -81
  109. package/{dist/es2015 → esm2015}/treeview-lookup.service.js +8 -10
  110. package/{dist/es2015 → esm2015}/treeview.component.js +173 -213
  111. package/{dist/es2015 → esm2015}/treeview.module.js +26 -10
  112. package/{dist/es2015 → esm2015}/utils.js +6 -12
  113. package/{dist/es2015/expand-state.service.d.ts → expand-state.service.d.ts} +3 -0
  114. package/{dist/es2015/expand.directive.d.ts → expand.directive.d.ts} +5 -2
  115. package/{dist/es2015/expandable-component.d.ts → expandable-component.d.ts} +3 -0
  116. package/{dist/fesm2015/index.js → fesm2015/kendo-angular-treeview.js} +3415 -3313
  117. package/{dist/es2015/filter-expand-settings.interface.d.ts → filter-expand-settings.interface.d.ts} +0 -0
  118. package/{dist/es2015/filter-state.interface.d.ts → filter-state.interface.d.ts} +0 -0
  119. package/{dist/es2015/filtering-base.d.ts → filtering-base.d.ts} +6 -2
  120. package/{dist/es2015/flat-binding.directive.d.ts → flat-binding.directive.d.ts} +5 -2
  121. package/{dist/es2015/funcs.d.ts → funcs.d.ts} +0 -0
  122. package/{dist/es2015/hierarchy-binding.directive.d.ts → hierarchy-binding.directive.d.ts} +10 -6
  123. package/{dist/es2015/index-builder.service.d.ts → index-builder.service.d.ts} +3 -0
  124. package/{dist/es/treeview-filter-settings.js → kendo-angular-treeview.d.ts} +3 -6
  125. package/{dist/es2015/load-more → load-more}/load-more-button-template.directive.d.ts +3 -0
  126. package/{dist/es2015/load-more → load-more}/load-more-request-args.d.ts +0 -0
  127. package/{dist/es2015/load-more → load-more}/load-more-utils.d.ts +0 -0
  128. package/{dist/es2015/load-more → load-more}/load-more.directive.d.ts +4 -1
  129. package/{dist/es2015/load-more → load-more}/load-more.service.d.ts +0 -0
  130. package/{dist/es2015/loading-indicator.directive.d.ts → loading-indicator.directive.d.ts} +5 -1
  131. package/{dist/es2015/loading-notification.service.d.ts → loading-notification.service.d.ts} +3 -0
  132. package/{dist/es2015/main.d.ts → main.d.ts} +0 -0
  133. package/{dist/es2015/navigation → navigation}/navigation-item.interface.d.ts +0 -0
  134. package/{dist/es2015/navigation → navigation}/navigation-model.d.ts +0 -0
  135. package/{dist/es2015/navigation → navigation}/navigation-state.interface.d.ts +0 -0
  136. package/{dist/es2015/navigation → navigation}/navigation.service.d.ts +9 -5
  137. package/{dist/es2015/node-children.service.d.ts → node-children.service.d.ts} +3 -0
  138. package/{dist/es2015/node-click-event.interface.d.ts → node-click-event.interface.d.ts} +0 -0
  139. package/{dist/es2015/node-template.directive.d.ts → node-template.directive.d.ts} +3 -0
  140. package/{dist/es2015/package-metadata.d.ts → package-metadata.d.ts} +0 -0
  141. package/package.json +36 -104
  142. package/schematics/ngAdd/index.js +5 -2
  143. package/schematics/ngAdd/index.js.map +1 -1
  144. package/{dist/es2015/selection → selection}/select.directive.d.ts +6 -3
  145. package/{dist/es2015/selection → selection}/selectable-settings.d.ts +0 -0
  146. package/{dist/es2015/selection → selection}/selection-mode.d.ts +0 -0
  147. package/{dist/es2015/selection → selection}/selection.service.d.ts +3 -0
  148. package/shared.module.d.ts +36 -0
  149. package/size.d.ts +8 -0
  150. package/{dist/es2015/treeitem-lookup.interface.d.ts → treeitem-lookup.interface.d.ts} +0 -0
  151. package/{dist/es2015/treeitem.interface.d.ts → treeitem.interface.d.ts} +0 -0
  152. package/{dist/es2015/treeview-filter-settings.d.ts → treeview-filter-settings.d.ts} +0 -0
  153. package/{dist/es2015/treeview-group.component.d.ts → treeview-group.component.d.ts} +16 -7
  154. package/{dist/es2015/treeview-item-content.directive.d.ts → treeview-item-content.directive.d.ts} +3 -0
  155. package/{dist/es2015/treeview-item.directive.d.ts → treeview-item.directive.d.ts} +11 -6
  156. package/{dist/es2015/treeview-lookup.service.d.ts → treeview-lookup.service.d.ts} +3 -0
  157. package/{dist/es2015/treeview.component.d.ts → treeview.component.d.ts} +26 -15
  158. package/treeview.module.d.ts +28 -0
  159. package/{dist/es2015/utils.d.ts → utils.d.ts} +1 -1
  160. package/dist/cdn/js/kendo-angular-treeview.js +0 -20
  161. package/dist/cdn/main.js +0 -5
  162. package/dist/es/check-mode.js +0 -4
  163. package/dist/es/check.directive.js +0 -282
  164. package/dist/es/checkbox/checkbox.component.js +0 -127
  165. package/dist/es/checkbox/checkbox.module.js +0 -27
  166. package/dist/es/checkbox/checked-state.js +0 -4
  167. package/dist/es/data-bound-component.js +0 -21
  168. package/dist/es/data-change-notification.service.js +0 -18
  169. package/dist/es/default-callbacks.js +0 -32
  170. package/dist/es/disable.directive.js +0 -71
  171. package/dist/es/drag-and-drop/drag-and-drop-editing.directive.js +0 -65
  172. package/dist/es/drag-and-drop/drag-and-drop-utils.js +0 -274
  173. package/dist/es/drag-and-drop/drag-and-drop.directive.js +0 -334
  174. package/dist/es/drag-and-drop/drag-clue/drag-clue-template.directive.js +0 -34
  175. package/dist/es/drag-and-drop/drag-clue/drag-clue.component.js +0 -54
  176. package/dist/es/drag-and-drop/drag-clue/drag-clue.service.js +0 -132
  177. package/dist/es/drag-and-drop/drop-hint/drop-hint-template.directive.js +0 -31
  178. package/dist/es/drag-and-drop/drop-hint/drop-hint.component.js +0 -43
  179. package/dist/es/drag-and-drop/drop-hint/drop-hint.service.js +0 -46
  180. package/dist/es/drag-and-drop/editing-services/drag-and-drop-asset.service.js +0 -53
  181. package/dist/es/drag-and-drop/editing-services/flat-editing.service.js +0 -145
  182. package/dist/es/drag-and-drop/editing-services/hierarchy-editing.service.js +0 -90
  183. package/dist/es/drag-and-drop/models/editing-service.js +0 -4
  184. package/dist/es/drag-and-drop/models/preventable-event.js +0 -29
  185. package/dist/es/drag-and-drop/models/treeitem-drag-event.js +0 -14
  186. package/dist/es/drag-and-drop/models/treeitem-drag-start-event.js +0 -22
  187. package/dist/es/drag-and-drop/models/treeitem-drop-event.js +0 -36
  188. package/dist/es/expand-state.service.js +0 -26
  189. package/dist/es/expand.directive.js +0 -219
  190. package/dist/es/expandable-component.js +0 -21
  191. package/dist/es/filtering-base.js +0 -95
  192. package/dist/es/flat-binding.directive.js +0 -151
  193. package/dist/es/funcs.js +0 -15
  194. package/dist/es/hierarchy-binding.directive.js +0 -152
  195. package/dist/es/index-builder.service.js +0 -38
  196. package/dist/es/index.js +0 -30
  197. package/dist/es/load-more/load-more-button-template.directive.js +0 -30
  198. package/dist/es/load-more/load-more-utils.js +0 -35
  199. package/dist/es/load-more/load-more.directive.js +0 -114
  200. package/dist/es/loading-indicator.directive.js +0 -76
  201. package/dist/es/loading-notification.service.js +0 -23
  202. package/dist/es/navigation/navigation-model.js +0 -162
  203. package/dist/es/navigation/navigation.service.js +0 -243
  204. package/dist/es/node-children.service.js +0 -23
  205. package/dist/es/node-template.directive.js +0 -74
  206. package/dist/es/package-metadata.js +0 -15
  207. package/dist/es/selection/select.directive.js +0 -152
  208. package/dist/es/selection/selection.service.js +0 -34
  209. package/dist/es/shared.module.js +0 -75
  210. package/dist/es/treeview-group.component.js +0 -393
  211. package/dist/es/treeview-item-content.directive.js +0 -85
  212. package/dist/es/treeview-item.directive.js +0 -306
  213. package/dist/es/treeview-lookup.service.js +0 -93
  214. package/dist/es/treeview.component.js +0 -853
  215. package/dist/es/treeview.module.js +0 -52
  216. package/dist/es/utils.js +0 -311
  217. package/dist/es2015/checkable-settings.js +0 -4
  218. package/dist/es2015/checkbox/checkbox.module.js +0 -24
  219. package/dist/es2015/data-bound-component.js +0 -18
  220. package/dist/es2015/drag-and-drop/drag-clue/drag-clue.component.js +0 -66
  221. package/dist/es2015/drag-and-drop/drop-hint/drop-hint.component.js +0 -61
  222. package/dist/es2015/drag-and-drop/models/drop-action.js +0 -17
  223. package/dist/es2015/drag-and-drop/models/drop-position.js +0 -13
  224. package/dist/es2015/drag-and-drop/models/scroll-direction.js +0 -12
  225. package/dist/es2015/drag-and-drop/models/scroll-settings.js +0 -4
  226. package/dist/es2015/drag-and-drop/models/tree-item-filter-state.js +0 -4
  227. package/dist/es2015/drag-and-drop/models/treeitem-add-remove-args.js +0 -4
  228. package/dist/es2015/drag-and-drop/models.js +0 -11
  229. package/dist/es2015/expandable-component.js +0 -18
  230. package/dist/es2015/filter-expand-settings.interface.js +0 -4
  231. package/dist/es2015/filter-state.interface.js +0 -4
  232. package/dist/es2015/index.d.ts +0 -30
  233. package/dist/es2015/index.js +0 -30
  234. package/dist/es2015/index.metadata.json +0 -1
  235. package/dist/es2015/load-more/load-more-button-template.directive.js +0 -29
  236. package/dist/es2015/load-more/load-more-request-args.js +0 -4
  237. package/dist/es2015/load-more/load-more.service.js +0 -4
  238. package/dist/es2015/loading-notification.service.js +0 -25
  239. package/dist/es2015/main.js +0 -26
  240. package/dist/es2015/navigation/navigation-item.interface.js +0 -4
  241. package/dist/es2015/navigation/navigation-state.interface.js +0 -4
  242. package/dist/es2015/node-click-event.interface.js +0 -4
  243. package/dist/es2015/selection/selectable-settings.js +0 -4
  244. package/dist/es2015/selection/selection-mode.js +0 -4
  245. package/dist/es2015/size.d.ts +0 -14
  246. package/dist/es2015/size.js +0 -4
  247. package/dist/es2015/treeitem-lookup.interface.js +0 -4
  248. package/dist/es2015/treeitem.interface.js +0 -4
  249. package/dist/es2015/treeview.module.d.ts +0 -9
  250. package/dist/fesm5/index.js +0 -5426
  251. package/dist/npm/check-mode.js +0 -6
  252. package/dist/npm/check.directive.js +0 -285
  253. package/dist/npm/checkable-settings.js +0 -6
  254. package/dist/npm/checkbox/checkbox.component.js +0 -129
  255. package/dist/npm/checkbox/checkbox.module.js +0 -29
  256. package/dist/npm/checkbox/checked-state.js +0 -6
  257. package/dist/npm/data-bound-component.js +0 -23
  258. package/dist/npm/data-change-notification.service.js +0 -20
  259. package/dist/npm/default-callbacks.js +0 -34
  260. package/dist/npm/disable.directive.js +0 -73
  261. package/dist/npm/drag-and-drop/drag-and-drop-editing.directive.js +0 -67
  262. package/dist/npm/drag-and-drop/drag-and-drop-utils.js +0 -278
  263. package/dist/npm/drag-and-drop/drag-and-drop.directive.js +0 -336
  264. package/dist/npm/drag-and-drop/drag-clue/drag-clue-template.directive.js +0 -36
  265. package/dist/npm/drag-and-drop/drag-clue/drag-clue.component.js +0 -56
  266. package/dist/npm/drag-and-drop/drag-clue/drag-clue.service.js +0 -134
  267. package/dist/npm/drag-and-drop/drop-hint/drop-hint-template.directive.js +0 -33
  268. package/dist/npm/drag-and-drop/drop-hint/drop-hint.component.js +0 -45
  269. package/dist/npm/drag-and-drop/drop-hint/drop-hint.service.js +0 -48
  270. package/dist/npm/drag-and-drop/editing-services/drag-and-drop-asset.service.js +0 -55
  271. package/dist/npm/drag-and-drop/editing-services/flat-editing.service.js +0 -147
  272. package/dist/npm/drag-and-drop/editing-services/hierarchy-editing.service.js +0 -92
  273. package/dist/npm/drag-and-drop/models/drop-action.js +0 -19
  274. package/dist/npm/drag-and-drop/models/drop-position.js +0 -15
  275. package/dist/npm/drag-and-drop/models/editing-service.js +0 -6
  276. package/dist/npm/drag-and-drop/models/preventable-event.js +0 -31
  277. package/dist/npm/drag-and-drop/models/scroll-direction.js +0 -14
  278. package/dist/npm/drag-and-drop/models/scroll-settings.js +0 -6
  279. package/dist/npm/drag-and-drop/models/tree-item-filter-state.js +0 -6
  280. package/dist/npm/drag-and-drop/models/treeitem-add-remove-args.js +0 -6
  281. package/dist/npm/drag-and-drop/models/treeitem-drag-event.js +0 -16
  282. package/dist/npm/drag-and-drop/models/treeitem-drag-start-event.js +0 -24
  283. package/dist/npm/drag-and-drop/models/treeitem-drop-event.js +0 -38
  284. package/dist/npm/drag-and-drop/models.js +0 -14
  285. package/dist/npm/expand-state.service.js +0 -28
  286. package/dist/npm/expand.directive.js +0 -221
  287. package/dist/npm/expandable-component.js +0 -23
  288. package/dist/npm/filter-expand-settings.interface.js +0 -6
  289. package/dist/npm/filter-state.interface.js +0 -6
  290. package/dist/npm/filtering-base.js +0 -97
  291. package/dist/npm/flat-binding.directive.js +0 -154
  292. package/dist/npm/funcs.js +0 -17
  293. package/dist/npm/hierarchy-binding.directive.js +0 -154
  294. package/dist/npm/index-builder.service.js +0 -40
  295. package/dist/npm/index.js +0 -55
  296. package/dist/npm/load-more/load-more-button-template.directive.js +0 -32
  297. package/dist/npm/load-more/load-more-request-args.js +0 -6
  298. package/dist/npm/load-more/load-more-utils.js +0 -37
  299. package/dist/npm/load-more/load-more.directive.js +0 -116
  300. package/dist/npm/load-more/load-more.service.js +0 -6
  301. package/dist/npm/loading-indicator.directive.js +0 -78
  302. package/dist/npm/loading-notification.service.js +0 -25
  303. package/dist/npm/main.js +0 -50
  304. package/dist/npm/navigation/navigation-item.interface.js +0 -6
  305. package/dist/npm/navigation/navigation-model.js +0 -166
  306. package/dist/npm/navigation/navigation-state.interface.js +0 -6
  307. package/dist/npm/navigation/navigation.service.js +0 -245
  308. package/dist/npm/node-children.service.js +0 -25
  309. package/dist/npm/node-click-event.interface.js +0 -6
  310. package/dist/npm/node-template.directive.js +0 -76
  311. package/dist/npm/package-metadata.js +0 -17
  312. package/dist/npm/selection/select.directive.js +0 -154
  313. package/dist/npm/selection/selectable-settings.js +0 -6
  314. package/dist/npm/selection/selection-mode.js +0 -6
  315. package/dist/npm/selection/selection.service.js +0 -36
  316. package/dist/npm/shared.module.js +0 -77
  317. package/dist/npm/size.js +0 -6
  318. package/dist/npm/treeitem-lookup.interface.js +0 -6
  319. package/dist/npm/treeitem.interface.js +0 -6
  320. package/dist/npm/treeview-filter-settings.js +0 -14
  321. package/dist/npm/treeview-group.component.js +0 -395
  322. package/dist/npm/treeview-item-content.directive.js +0 -87
  323. package/dist/npm/treeview-item.directive.js +0 -308
  324. package/dist/npm/treeview-lookup.service.js +0 -95
  325. package/dist/npm/treeview.component.js +0 -855
  326. package/dist/npm/treeview.module.js +0 -54
  327. package/dist/npm/utils.js +0 -322
  328. package/dist/systemjs/kendo-angular-treeview.js +0 -5
@@ -1,282 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import * as tslib_1 from "tslib";
6
- import { Directive, EventEmitter, Input, Output, NgZone } from '@angular/core';
7
- import { TreeViewComponent } from './treeview.component';
8
- import { fetchLoadedDescendants, isBoolean, isPresent, noop } from './utils';
9
- import { Subscription } from 'rxjs';
10
- import { filter, take, switchMap, tap } from 'rxjs/operators';
11
- import { isChanged } from '@progress/kendo-angular-common';
12
- var indexChecked = function (keys, index) { return keys.filter(function (k) { return k === index; }).length > 0; };
13
- var ɵ0 = indexChecked;
14
- var matchKey = function (index) { return function (k) {
15
- if (index === k) {
16
- return true;
17
- }
18
- if (!k.split) {
19
- return false;
20
- }
21
- return k.split('_').reduce(function (_a, part) {
22
- var key = _a.key, result = _a.result;
23
- key += part;
24
- if (index === key || result) {
25
- return { result: true };
26
- }
27
- key += "_";
28
- return { key: key, result: false };
29
- }, { key: "", result: false }).result;
30
- }; };
31
- var ɵ1 = matchKey;
32
- /**
33
- * A directive which manages the in-memory checked state of the TreeView node
34
- * ([see example]({% slug checkboxes_treeview %})).
35
- */
36
- var CheckDirective = /** @class */ (function () {
37
- function CheckDirective(treeView, zone) {
38
- var _this = this;
39
- this.treeView = treeView;
40
- this.zone = zone;
41
- /**
42
- * Fires when the `checkedKeys` collection was updated.
43
- */
44
- this.checkedKeysChange = new EventEmitter();
45
- this.subscriptions = new Subscription();
46
- this.checkActions = {
47
- 'multiple': function (e) { return _this.checkMultiple(e); },
48
- 'single': function (e) { return _this.checkSingle(e); }
49
- };
50
- /**
51
- * Reflectes the internal `checkedKeys` state.
52
- */
53
- this.state = new Set();
54
- this.subscriptions.add(this.treeView.checkedChange
55
- .subscribe(function (e) { return _this.check(e); }));
56
- var expandedItems = [];
57
- this.subscriptions.add(this.treeView.childrenLoaded
58
- .pipe(filter(function () { return _this.options.checkChildren && _this.treeView.loadOnDemand; }), tap(function (item) { return expandedItems.push(item); }), switchMap(function () { return _this.zone.onStable.pipe(take(1)); }))
59
- .subscribe(function () { return _this.addCheckedItemsChildren(expandedItems); }));
60
- this.treeView.isChecked = this.isItemChecked.bind(this);
61
- }
62
- Object.defineProperty(CheckDirective.prototype, "isChecked", {
63
- /**
64
- * @hidden
65
- */
66
- set: function (value) {
67
- this.treeView.isChecked = value;
68
- },
69
- enumerable: true,
70
- configurable: true
71
- });
72
- Object.defineProperty(CheckDirective.prototype, "options", {
73
- get: function () {
74
- var defaultOptions = {
75
- checkChildren: true,
76
- checkParents: true,
77
- enabled: true,
78
- mode: "multiple"
79
- };
80
- if (!isPresent(this.checkable) || typeof this.checkable === 'string') {
81
- return defaultOptions;
82
- }
83
- var checkSettings = isBoolean(this.checkable)
84
- ? { enabled: this.checkable }
85
- : this.checkable;
86
- return Object.assign(defaultOptions, checkSettings);
87
- },
88
- enumerable: true,
89
- configurable: true
90
- });
91
- CheckDirective.prototype.ngOnChanges = function (changes) {
92
- if (changes.checkable) {
93
- this.treeView.checkboxes = this.options.enabled;
94
- this.toggleCheckOnClick();
95
- }
96
- if (isChanged('checkedKeys', changes, false) && changes.checkedKeys.currentValue !== this.lastChange) {
97
- this.state = new Set(changes.checkedKeys.currentValue);
98
- }
99
- };
100
- CheckDirective.prototype.ngOnDestroy = function () {
101
- this.subscriptions.unsubscribe();
102
- this.unsubscribeClick();
103
- };
104
- CheckDirective.prototype.isItemChecked = function (dataItem, index) {
105
- if (!this.checkKey) {
106
- return this.isIndexChecked(index);
107
- }
108
- var hasKey = this.state.has(this.itemKey({ dataItem: dataItem, index: index }));
109
- return hasKey ? 'checked' : 'none';
110
- };
111
- CheckDirective.prototype.isIndexChecked = function (index) {
112
- var checkedKeys = Array.from(this.state).filter(matchKey(index));
113
- if (indexChecked(checkedKeys, index)) {
114
- return 'checked';
115
- }
116
- var _a = this.options, mode = _a.mode, checkParents = _a.checkParents;
117
- if (mode === 'multiple' && checkParents && checkedKeys.length) {
118
- return 'indeterminate';
119
- }
120
- return 'none';
121
- };
122
- CheckDirective.prototype.itemKey = function (item) {
123
- if (!isPresent(this.checkKey)) {
124
- return item.index;
125
- }
126
- if (typeof this.checkKey === "string" && isPresent(item.dataItem)) {
127
- return item.dataItem[this.checkKey];
128
- }
129
- if (typeof this.checkKey === "function") {
130
- return this.checkKey(item);
131
- }
132
- };
133
- CheckDirective.prototype.check = function (e) {
134
- var _a = this.options, enabled = _a.enabled, mode = _a.mode;
135
- var performSelection = this.checkActions[mode] || noop;
136
- if (!enabled) {
137
- return;
138
- }
139
- performSelection(e);
140
- };
141
- CheckDirective.prototype.checkSingle = function (node) {
142
- var key = this.itemKey(node.item);
143
- var hasKey = this.state.has(key);
144
- this.state.clear();
145
- if (!hasKey) {
146
- this.state.add(key);
147
- }
148
- this.notify();
149
- };
150
- CheckDirective.prototype.checkMultiple = function (node) {
151
- this.checkNode(node);
152
- if (this.options.checkParents) {
153
- this.checkParents(node.parent);
154
- }
155
- this.notify();
156
- };
157
- CheckDirective.prototype.toggleCheckOnClick = function () {
158
- var _this = this;
159
- this.unsubscribeClick();
160
- if (this.options.checkOnClick) {
161
- this.clickSubscription = this.treeView.nodeClick.subscribe(function (args) {
162
- if (args.type === 'click') {
163
- var lookup = _this.treeView.itemLookup(args.item.index);
164
- _this.check(lookup);
165
- }
166
- });
167
- }
168
- };
169
- CheckDirective.prototype.unsubscribeClick = function () {
170
- if (this.clickSubscription) {
171
- this.clickSubscription.unsubscribe();
172
- this.clickSubscription = null;
173
- }
174
- };
175
- CheckDirective.prototype.checkNode = function (node) {
176
- var _this = this;
177
- if (!isPresent(node.item.dataItem) || this.treeView.isDisabled(node.item.dataItem, node.item.index)) {
178
- return;
179
- }
180
- var currentKey = this.itemKey(node.item);
181
- if (!isPresent(currentKey)) {
182
- return;
183
- }
184
- var pendingCheck = [currentKey];
185
- if (this.options.checkChildren) {
186
- var descendants = fetchLoadedDescendants(node, function (_a) {
187
- var item = _a.item;
188
- return _this.treeView.isVisible(item.dataItem, item.index) &&
189
- !_this.treeView.isDisabled(item.dataItem, item.index);
190
- })
191
- .map(function (_a) {
192
- var item = _a.item;
193
- return _this.itemKey(item);
194
- });
195
- pendingCheck.push.apply(pendingCheck, descendants);
196
- }
197
- var shouldCheck = !this.state.has(currentKey);
198
- pendingCheck.forEach(function (key) {
199
- if (shouldCheck) {
200
- _this.state.add(key);
201
- }
202
- else {
203
- _this.state.delete(key);
204
- }
205
- });
206
- };
207
- CheckDirective.prototype.checkParents = function (parent) {
208
- var _this = this;
209
- if (!isPresent(parent)) {
210
- return;
211
- }
212
- var currentParent = parent;
213
- while (currentParent) {
214
- var parentKey = this.itemKey(currentParent.item);
215
- var allChildrenSelected = currentParent.children.every(function (item) { return _this.state.has(_this.itemKey(item)); });
216
- if (allChildrenSelected) {
217
- this.state.add(parentKey);
218
- }
219
- else {
220
- this.state.delete(parentKey);
221
- }
222
- currentParent = currentParent.parent;
223
- }
224
- };
225
- CheckDirective.prototype.notify = function () {
226
- this.lastChange = Array.from(this.state);
227
- this.checkedKeysChange.emit(this.lastChange);
228
- };
229
- CheckDirective.prototype.addCheckedItemsChildren = function (lookups) {
230
- var _this = this;
231
- if (!isPresent(lookups) || lookups.length === 0) {
232
- return;
233
- }
234
- var initiallyCheckedItemsCount = this.state.size;
235
- lookups.forEach(function (lookup) {
236
- var itemKey = _this.itemKey(lookup.item);
237
- if (!_this.state.has(itemKey)) {
238
- return;
239
- }
240
- lookup.children.forEach(function (item) {
241
- // ensure both the parent item and each child node is enabled
242
- if (!_this.treeView.isDisabled(lookup.item.dataItem, lookup.item.index) &&
243
- !_this.treeView.isDisabled(item.dataItem, item.index)) {
244
- _this.state.add(_this.itemKey(item));
245
- }
246
- });
247
- });
248
- var hasNewlyCheckedItems = initiallyCheckedItemsCount !== this.state.size;
249
- if (hasNewlyCheckedItems) {
250
- this.zone.run(function () { return _this.notify(); });
251
- }
252
- };
253
- tslib_1.__decorate([
254
- Input(),
255
- tslib_1.__metadata("design:type", Function),
256
- tslib_1.__metadata("design:paramtypes", [Function])
257
- ], CheckDirective.prototype, "isChecked", null);
258
- tslib_1.__decorate([
259
- Input("checkBy"),
260
- tslib_1.__metadata("design:type", Object)
261
- ], CheckDirective.prototype, "checkKey", void 0);
262
- tslib_1.__decorate([
263
- Input(),
264
- tslib_1.__metadata("design:type", Array)
265
- ], CheckDirective.prototype, "checkedKeys", void 0);
266
- tslib_1.__decorate([
267
- Input('kendoTreeViewCheckable'),
268
- tslib_1.__metadata("design:type", Object)
269
- ], CheckDirective.prototype, "checkable", void 0);
270
- tslib_1.__decorate([
271
- Output(),
272
- tslib_1.__metadata("design:type", EventEmitter)
273
- ], CheckDirective.prototype, "checkedKeysChange", void 0);
274
- CheckDirective = tslib_1.__decorate([
275
- Directive({ selector: '[kendoTreeViewCheckable]' }),
276
- tslib_1.__metadata("design:paramtypes", [TreeViewComponent,
277
- NgZone])
278
- ], CheckDirective);
279
- return CheckDirective;
280
- }());
281
- export { CheckDirective };
282
- export { ɵ0, ɵ1 };
@@ -1,127 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import * as tslib_1 from "tslib";
6
- import { ChangeDetectorRef, Component, ElementRef, EventEmitter, HostBinding, Input, Output, Renderer2 } from '@angular/core';
7
- import { guid } from '@progress/kendo-angular-common';
8
- import { getSizeClass } from '../utils';
9
- /**
10
- * @hidden
11
- *
12
- * Represents the CheckBox component of the Kendo UI TreeView for Angular.
13
- *
14
- */
15
- var CheckBoxComponent = /** @class */ (function () {
16
- function CheckBoxComponent(element, renderer, changeDetector) {
17
- this.element = element;
18
- this.renderer = renderer;
19
- this.changeDetector = changeDetector;
20
- /**
21
- * Specifies the [`id`](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id) of the component.
22
- */
23
- this.id = "_" + guid();
24
- /**
25
- * Specifies the [`tabindex`](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex) of the component.
26
- */
27
- this.tabindex = 0;
28
- /**
29
- * Specifies the size of the component.
30
- */
31
- this.size = 'medium';
32
- /**
33
- * Fires when the user changes the check state of the component.
34
- */
35
- this.checkStateChange = new EventEmitter();
36
- this.checkState = 'none';
37
- }
38
- Object.defineProperty(CheckBoxComponent.prototype, "classWrapper", {
39
- //XXX: implement ComponentValueAccessor
40
- //XXX: focus/blur methods
41
- get: function () { return true; },
42
- enumerable: true,
43
- configurable: true
44
- });
45
- Object.defineProperty(CheckBoxComponent.prototype, "indeterminate", {
46
- get: function () {
47
- return this.checkState === 'indeterminate';
48
- },
49
- enumerable: true,
50
- configurable: true
51
- });
52
- Object.defineProperty(CheckBoxComponent.prototype, "checked", {
53
- get: function () {
54
- return this.checkState === 'checked';
55
- },
56
- enumerable: true,
57
- configurable: true
58
- });
59
- Object.defineProperty(CheckBoxComponent.prototype, "checkBoxClasses", {
60
- get: function () {
61
- return "k-checkbox " + (this.size ? getSizeClass('checkbox', this.size) : '') + " k-rounded-md";
62
- },
63
- enumerable: true,
64
- configurable: true
65
- });
66
- CheckBoxComponent.prototype.ngOnInit = function () {
67
- this.renderer.removeAttribute(this.element.nativeElement, "tabindex");
68
- };
69
- CheckBoxComponent.prototype.ngDoCheck = function () {
70
- this.checkState = this.isChecked(this.node, this.index);
71
- };
72
- CheckBoxComponent.prototype.handleChange = function (e) {
73
- var state = e.target.checked ? 'checked' : 'none';
74
- // update the View State so that Angular updates the input if the isChecked value is the same
75
- this.checkState = state;
76
- this.changeDetector.detectChanges();
77
- this.checkStateChange.emit(state);
78
- };
79
- tslib_1.__decorate([
80
- HostBinding('class.k-checkbox-wrapper'),
81
- tslib_1.__metadata("design:type", Boolean),
82
- tslib_1.__metadata("design:paramtypes", [])
83
- ], CheckBoxComponent.prototype, "classWrapper", null);
84
- tslib_1.__decorate([
85
- Input(),
86
- tslib_1.__metadata("design:type", String)
87
- ], CheckBoxComponent.prototype, "id", void 0);
88
- tslib_1.__decorate([
89
- Input(),
90
- tslib_1.__metadata("design:type", Object)
91
- ], CheckBoxComponent.prototype, "isChecked", void 0);
92
- tslib_1.__decorate([
93
- Input(),
94
- tslib_1.__metadata("design:type", Object)
95
- ], CheckBoxComponent.prototype, "node", void 0);
96
- tslib_1.__decorate([
97
- Input(),
98
- tslib_1.__metadata("design:type", String)
99
- ], CheckBoxComponent.prototype, "index", void 0);
100
- tslib_1.__decorate([
101
- Input(),
102
- tslib_1.__metadata("design:type", String)
103
- ], CheckBoxComponent.prototype, "labelText", void 0);
104
- tslib_1.__decorate([
105
- Input(),
106
- tslib_1.__metadata("design:type", Number)
107
- ], CheckBoxComponent.prototype, "tabindex", void 0);
108
- tslib_1.__decorate([
109
- Input(),
110
- tslib_1.__metadata("design:type", String)
111
- ], CheckBoxComponent.prototype, "size", void 0);
112
- tslib_1.__decorate([
113
- Output(),
114
- tslib_1.__metadata("design:type", EventEmitter)
115
- ], CheckBoxComponent.prototype, "checkStateChange", void 0);
116
- CheckBoxComponent = tslib_1.__decorate([
117
- Component({
118
- selector: 'kendo-checkbox',
119
- template: "\n <input\n type=\"checkbox\"\n [class]=\"checkBoxClasses\"\n [id]=\"id\"\n [checked]=\"checked\"\n [indeterminate]=\"indeterminate\"\n [tabindex]=\"tabindex\"\n (change)=\"handleChange($event)\"\n />\n <label\n class=\"k-checkbox-label\"\n tabindex=\"-1\"\n [for]=\"id\"\n >{{labelText}}</label>\n "
120
- }),
121
- tslib_1.__metadata("design:paramtypes", [ElementRef,
122
- Renderer2,
123
- ChangeDetectorRef])
124
- ], CheckBoxComponent);
125
- return CheckBoxComponent;
126
- }());
127
- export { CheckBoxComponent };
@@ -1,27 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import * as tslib_1 from "tslib";
6
- import { NgModule } from '@angular/core';
7
- import { CheckBoxComponent } from './checkbox.component';
8
- var COMPONENT_DIRECTIVES = [
9
- CheckBoxComponent
10
- ];
11
- /**
12
- * @hidden
13
- *
14
- * Represents the [NgModule]({{ site.data.urls.angular['ngmoduleapi'] }}) definition for the CheckBox component.
15
- */
16
- var CheckBoxModule = /** @class */ (function () {
17
- function CheckBoxModule() {
18
- }
19
- CheckBoxModule = tslib_1.__decorate([
20
- NgModule({
21
- declarations: [COMPONENT_DIRECTIVES],
22
- exports: [COMPONENT_DIRECTIVES]
23
- })
24
- ], CheckBoxModule);
25
- return CheckBoxModule;
26
- }());
27
- export { CheckBoxModule };
@@ -1,4 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
@@ -1,21 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import * as tslib_1 from "tslib";
6
- import { Injectable } from '@angular/core';
7
- /**
8
- * @hidden
9
- *
10
- * An injection token used by the data binding directives to interface with
11
- * the TreeView or the DropDownTree components.
12
- */
13
- var DataBoundComponent = /** @class */ (function () {
14
- function DataBoundComponent() {
15
- }
16
- DataBoundComponent = tslib_1.__decorate([
17
- Injectable()
18
- ], DataBoundComponent);
19
- return DataBoundComponent;
20
- }());
21
- export { DataBoundComponent };
@@ -1,18 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import { EventEmitter } from '@angular/core';
6
- /**
7
- * @hidden
8
- */
9
- var DataChangeNotificationService = /** @class */ (function () {
10
- function DataChangeNotificationService() {
11
- this.changes = new EventEmitter();
12
- }
13
- DataChangeNotificationService.prototype.notify = function () {
14
- this.changes.emit();
15
- };
16
- return DataChangeNotificationService;
17
- }());
18
- export { DataChangeNotificationService };
@@ -1,32 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- /**
6
- * @hidden
7
- */
8
- export var hasChildren = function () { return false; };
9
- /**
10
- * @hidden
11
- */
12
- export var isChecked = function () { return 'none'; };
13
- /**
14
- * @hidden
15
- */
16
- export var isDisabled = function () { return false; };
17
- /**
18
- * @hidden
19
- */
20
- export var isExpanded = function () { return true; };
21
- /**
22
- * @hidden
23
- */
24
- export var isSelected = function () { return false; };
25
- /**
26
- * @hidden
27
- */
28
- export var isVisible = function () { return true; };
29
- /**
30
- * @hidden
31
- */
32
- export var trackBy = function (_, item) { return item; };
@@ -1,71 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import * as tslib_1 from "tslib";
6
- import { ChangeDetectorRef, Directive, Input } from '@angular/core';
7
- import { TreeViewComponent } from './treeview.component';
8
- /**
9
- * A directive which manages the disabled in-memory state of the TreeView node
10
- * ([see example]({% slug disabledstate_treeview %})).
11
- */
12
- var DisableDirective = /** @class */ (function () {
13
- function DisableDirective(treeView, cdr) {
14
- var _this = this;
15
- this.treeView = treeView;
16
- this.cdr = cdr;
17
- /**
18
- * Defines the collection that will store the disabled keys.
19
- */
20
- this.disabledKeys = [];
21
- this.treeView.isDisabled = function (dataItem, index) { return (_this.disabledKeys.indexOf(_this.itemKey({ dataItem: dataItem, index: index })) > -1); };
22
- }
23
- Object.defineProperty(DisableDirective.prototype, "isDisabled", {
24
- /**
25
- * @hidden
26
- */
27
- set: function (value) {
28
- this.treeView.isDisabled = value;
29
- },
30
- enumerable: true,
31
- configurable: true
32
- });
33
- DisableDirective.prototype.ngOnChanges = function (changes) {
34
- if (changes === void 0) { changes = {}; }
35
- var disabledKeys = changes.disabledKeys;
36
- if (disabledKeys && !disabledKeys.firstChange) {
37
- this.cdr.markForCheck();
38
- }
39
- };
40
- DisableDirective.prototype.itemKey = function (e) {
41
- if (!this.disableKey) {
42
- return e.index;
43
- }
44
- if (typeof this.disableKey === "string") {
45
- return e.dataItem[this.disableKey];
46
- }
47
- if (typeof this.disableKey === "function") {
48
- return this.disableKey(e);
49
- }
50
- };
51
- tslib_1.__decorate([
52
- Input(),
53
- tslib_1.__metadata("design:type", Function),
54
- tslib_1.__metadata("design:paramtypes", [Function])
55
- ], DisableDirective.prototype, "isDisabled", null);
56
- tslib_1.__decorate([
57
- Input("kendoTreeViewDisable"),
58
- tslib_1.__metadata("design:type", Object)
59
- ], DisableDirective.prototype, "disableKey", void 0);
60
- tslib_1.__decorate([
61
- Input(),
62
- tslib_1.__metadata("design:type", Array)
63
- ], DisableDirective.prototype, "disabledKeys", void 0);
64
- DisableDirective = tslib_1.__decorate([
65
- Directive({ selector: '[kendoTreeViewDisable]' }),
66
- tslib_1.__metadata("design:paramtypes", [TreeViewComponent,
67
- ChangeDetectorRef])
68
- ], DisableDirective);
69
- return DisableDirective;
70
- }());
71
- export { DisableDirective };
@@ -1,65 +0,0 @@
1
- /**-----------------------------------------------------------------------------------------
2
- * Copyright © 2021 Progress Software Corporation. All rights reserved.
3
- * Licensed under commercial license. See LICENSE.md in the project root for more information
4
- *-------------------------------------------------------------------------------------------*/
5
- import * as tslib_1 from "tslib";
6
- import { Directive, Input } from '@angular/core';
7
- import { Subscription } from 'rxjs';
8
- import { TreeViewComponent } from '../treeview.component';
9
- import { isPresent } from '../utils';
10
- /**
11
- * A directive which enables the update of the initially provided data array during drag-and-drop.
12
- *
13
- * Either use this directive in combination with one of the data binding directives ([`kendoTreeViewHierarchyBinding`]({% slug api_treeview_hierarchybindingdirective %})
14
- * or [`kendoTreeViewFlatDataBinding`]({% slug api_treeview_flatdatabindingdirective %})) which set their own edit handlers, or provide
15
- * your own [`editService`]({% slug api_treeview_editservice %}) to this directive. The latter subscribes to and calls the
16
- * [`addItem`]({% slug api_treeview_treeviewcomponent %}#toc-additem) and [`removeItem`]({% slug api_treeview_treeviewcomponent %}#toc-removeitem)
17
- * handlers when the corresponding events are triggered by the TreeView component.
18
- */
19
- var DragAndDropEditingDirective = /** @class */ (function () {
20
- function DragAndDropEditingDirective(treeview) {
21
- this.treeview = treeview;
22
- this.subscriptions = new Subscription();
23
- this.subscriptions.add(this.treeview.addItem.subscribe(this.handleAdd.bind(this)));
24
- this.subscriptions.add(this.treeview.removeItem.subscribe(this.handleRemove.bind(this)));
25
- }
26
- Object.defineProperty(DragAndDropEditingDirective.prototype, "editService", {
27
- /**
28
- * Specifies the handlers called on drag-and-drop [`addItem`]({% slug api_treeview_treeviewcomponent %}#toc-additem)
29
- * and [`removeItem`]({% slug api_treeview_treeviewcomponent %}#toc-removeitem) events.
30
- */
31
- set: function (service) {
32
- this.treeview.editService = service;
33
- },
34
- enumerable: true,
35
- configurable: true
36
- });
37
- DragAndDropEditingDirective.prototype.ngOnDestroy = function () {
38
- this.subscriptions.unsubscribe();
39
- };
40
- DragAndDropEditingDirective.prototype.handleAdd = function (args) {
41
- if (!isPresent(this.treeview.editService)) {
42
- throw new Error('No `editService` provided. Either provide your own implementation or use this directive in combination with one of the data binding directives (`kendoTreeViewHierarchyBinding` or `kendoTreeViewFlatDataBinding`).');
43
- }
44
- this.treeview.editService.add(args);
45
- };
46
- DragAndDropEditingDirective.prototype.handleRemove = function (args) {
47
- if (!isPresent(this.treeview.editService)) {
48
- throw new Error('No `editService` provided. Either provide your own implementation or use this directive in combination with one of the data binding directives (`kendoTreeViewHierarchyBinding` or `kendoTreeViewFlatDataBinding`).');
49
- }
50
- this.treeview.editService.remove(args);
51
- };
52
- tslib_1.__decorate([
53
- Input(),
54
- tslib_1.__metadata("design:type", Object),
55
- tslib_1.__metadata("design:paramtypes", [Object])
56
- ], DragAndDropEditingDirective.prototype, "editService", null);
57
- DragAndDropEditingDirective = tslib_1.__decorate([
58
- Directive({
59
- selector: '[kendoTreeViewDragAndDropEditing]'
60
- }),
61
- tslib_1.__metadata("design:paramtypes", [TreeViewComponent])
62
- ], DragAndDropEditingDirective);
63
- return DragAndDropEditingDirective;
64
- }());
65
- export { DragAndDropEditingDirective };