@ng-matero/extensions 12.7.0 → 13.0.2

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 (537) hide show
  1. package/README.md +2 -16
  2. package/_all-color.scss +1 -1
  3. package/_index.scss +1 -1
  4. package/_theming.scss +1 -1
  5. package/alert/_alert-theme.scss +2 -2
  6. package/alert/alert.component.d.ts +3 -0
  7. package/alert/alert.module.d.ts +6 -0
  8. package/alert/mtxAlert.d.ts +1 -0
  9. package/alert/package.json +5 -6
  10. package/button/button-loading.directive.d.ts +3 -0
  11. package/button/button.module.d.ts +8 -0
  12. package/button/mtxButton.d.ts +1 -0
  13. package/button/package.json +5 -6
  14. package/checkbox-group/checkbox-group.component.d.ts +3 -0
  15. package/checkbox-group/checkbox-group.module.d.ts +9 -0
  16. package/checkbox-group/mtxCheckboxGroup.d.ts +1 -0
  17. package/checkbox-group/package.json +5 -6
  18. package/colorpicker/_colorpicker-theme.scss +2 -2
  19. package/colorpicker/colorpicker-input.d.ts +3 -0
  20. package/colorpicker/colorpicker-module.d.ts +13 -0
  21. package/colorpicker/colorpicker-toggle.d.ts +5 -0
  22. package/colorpicker/colorpicker.d.ts +6 -1
  23. package/colorpicker/mtxColorpicker.d.ts +1 -0
  24. package/colorpicker/package.json +5 -6
  25. package/column-resize/column-resize-directives/column-resize-flex.d.ts +3 -0
  26. package/column-resize/column-resize-directives/column-resize.d.ts +3 -0
  27. package/column-resize/column-resize-module.d.ts +6 -7
  28. package/column-resize/column-resize-notifier.d.ts +5 -7
  29. package/column-resize/column-resize.d.ts +3 -0
  30. package/column-resize/column-size-store.d.ts +3 -7
  31. package/column-resize/event-dispatcher.d.ts +3 -0
  32. package/column-resize/mtxColumnResize.d.ts +1 -0
  33. package/column-resize/overlay-handle.d.ts +3 -0
  34. package/column-resize/package.json +5 -6
  35. package/column-resize/resizable.d.ts +3 -0
  36. package/column-resize/resize-strategy.d.ts +7 -0
  37. package/core/datetime/datetime.module.d.ts +8 -0
  38. package/core/datetime/native-datetime-adapter.d.ts +3 -0
  39. package/core/density/private/_compatibility.scss +74 -0
  40. package/core/mtxCore.d.ts +1 -0
  41. package/core/package.json +5 -6
  42. package/{pipes/public-api.d.ts → core/pipes/index.d.ts} +0 -0
  43. package/core/pipes/pipes.module.d.ts +8 -0
  44. package/{pipes → core/pipes}/to-observable.pipe.d.ts +3 -0
  45. package/core/public-api.d.ts +1 -0
  46. package/core/style/_elevation.scss +197 -0
  47. package/core/style/_private.scss +41 -0
  48. package/core/style/_variables.scss +44 -0
  49. package/core/style/_vendor-prefixes.scss +60 -0
  50. package/core/theming/_palette.scss +746 -0
  51. package/core/theming/_theming.scss +430 -0
  52. package/core/typography/_typography-utils.scss +101 -0
  53. package/core/typography/_typography.scss +273 -0
  54. package/datetimepicker/_datetimepicker-theme.scss +5 -5
  55. package/datetimepicker/calendar-body.d.ts +3 -0
  56. package/datetimepicker/calendar-body.scss +5 -4
  57. package/datetimepicker/calendar.d.ts +4 -1
  58. package/datetimepicker/clock.d.ts +3 -0
  59. package/datetimepicker/datetimepicker-input.d.ts +3 -0
  60. package/datetimepicker/datetimepicker-module.d.ts +18 -0
  61. package/datetimepicker/datetimepicker-toggle.d.ts +5 -0
  62. package/datetimepicker/datetimepicker-types.d.ts +1 -0
  63. package/datetimepicker/datetimepicker.d.ts +7 -2
  64. package/datetimepicker/month-view.d.ts +4 -1
  65. package/datetimepicker/mtxDatetimepicker.d.ts +1 -0
  66. package/datetimepicker/multi-year-view.d.ts +4 -1
  67. package/datetimepicker/package.json +5 -6
  68. package/datetimepicker/public-api.d.ts +1 -0
  69. package/datetimepicker/year-view.d.ts +4 -1
  70. package/dialog/dialog.component.d.ts +3 -0
  71. package/dialog/dialog.d.ts +3 -0
  72. package/dialog/dialog.module.d.ts +10 -0
  73. package/dialog/mtxDialog.d.ts +1 -0
  74. package/dialog/package.json +5 -6
  75. package/esm2020/alert/alert.component.mjs +52 -0
  76. package/esm2020/alert/alert.module.mjs +18 -0
  77. package/{esm2015/alert/mtxAlert.js → esm2020/alert/mtxAlert.mjs} +0 -0
  78. package/{esm2015/alert/public-api.js → esm2020/alert/public-api.mjs} +0 -0
  79. package/esm2020/button/button-loading.directive.mjs +79 -0
  80. package/esm2020/button/button.module.mjs +20 -0
  81. package/{esm2015/button/mtxButton.js → esm2020/button/mtxButton.mjs} +0 -0
  82. package/{esm2015/button/public-api.js → esm2020/button/public-api.mjs} +0 -0
  83. package/esm2020/checkbox-group/checkbox-group.component.mjs +234 -0
  84. package/{esm2015/checkbox-group/checkbox-group.interface.js → esm2020/checkbox-group/checkbox-group.interface.mjs} +0 -0
  85. package/esm2020/checkbox-group/checkbox-group.module.mjs +21 -0
  86. package/{esm2015/checkbox-group/mtxCheckboxGroup.js → esm2020/checkbox-group/mtxCheckboxGroup.mjs} +0 -0
  87. package/{esm2015/checkbox-group/public-api.js → esm2020/checkbox-group/public-api.mjs} +0 -0
  88. package/{esm2015/colorpicker/colorpicker-animations.js → esm2020/colorpicker/colorpicker-animations.mjs} +0 -0
  89. package/esm2020/colorpicker/colorpicker-input.mjs +228 -0
  90. package/esm2020/colorpicker/colorpicker-module.mjs +65 -0
  91. package/esm2020/colorpicker/colorpicker-toggle.mjs +90 -0
  92. package/esm2020/colorpicker/colorpicker.mjs +363 -0
  93. package/{esm2015/colorpicker/mtxColorpicker.js → esm2020/colorpicker/mtxColorpicker.mjs} +0 -0
  94. package/{esm2015/colorpicker/public-api.js → esm2020/colorpicker/public-api.mjs} +0 -0
  95. package/esm2020/column-resize/column-resize-directives/column-resize-flex.mjs +45 -0
  96. package/esm2020/column-resize/column-resize-directives/column-resize.mjs +45 -0
  97. package/{esm2015/column-resize/column-resize-directives/constants.js → esm2020/column-resize/column-resize-directives/constants.mjs} +0 -0
  98. package/esm2020/column-resize/column-resize-module.mjs +28 -0
  99. package/esm2020/column-resize/column-resize-notifier.mjs +47 -0
  100. package/esm2020/column-resize/column-resize.mjs +82 -0
  101. package/esm2020/column-resize/column-size-store.mjs +20 -0
  102. package/esm2020/column-resize/event-dispatcher.mjs +67 -0
  103. package/{esm2015/column-resize/mtxColumnResize.js → esm2020/column-resize/mtxColumnResize.mjs} +0 -0
  104. package/esm2020/column-resize/overlay-handle.mjs +146 -0
  105. package/{esm2015/column-resize/polyfill.js → esm2020/column-resize/polyfill.mjs} +0 -0
  106. package/{esm2015/column-resize/public-api.js → esm2020/column-resize/public-api.mjs} +0 -0
  107. package/esm2020/column-resize/resizable.mjs +199 -0
  108. package/{esm2015/column-resize/resize-ref.js → esm2020/column-resize/resize-ref.mjs} +0 -0
  109. package/esm2020/column-resize/resize-strategy.mjs +232 -0
  110. package/{esm2015/column-resize/selectors.js → esm2020/column-resize/selectors.mjs} +0 -0
  111. package/{esm2015/core/datetime/datetime-adapter.js → esm2020/core/datetime/datetime-adapter.mjs} +0 -0
  112. package/{esm2015/core/datetime/datetime-formats.js → esm2020/core/datetime/datetime-formats.mjs} +0 -0
  113. package/esm2020/core/datetime/datetime.module.mjs +42 -0
  114. package/{esm2015/core/datetime/index.js → esm2020/core/datetime/index.mjs} +0 -0
  115. package/esm2020/core/datetime/native-datetime-adapter.mjs +138 -0
  116. package/{esm2015/core/datetime/native-datetime-formats.js → esm2020/core/datetime/native-datetime-formats.mjs} +0 -0
  117. package/{esm2015/core/mtxCore.js → esm2020/core/mtxCore.mjs} +0 -0
  118. package/esm2020/core/pipes/index.mjs +3 -0
  119. package/esm2020/core/pipes/pipes.module.mjs +18 -0
  120. package/esm2020/core/pipes/to-observable.pipe.mjs +15 -0
  121. package/{esm2015/core/public-api.js → esm2020/core/public-api.mjs} +2 -1
  122. package/esm2020/datetimepicker/calendar-body.mjs +78 -0
  123. package/esm2020/datetimepicker/calendar.mjs +618 -0
  124. package/esm2020/datetimepicker/clock.mjs +277 -0
  125. package/{esm2015/datetimepicker/datetimepicker-animations.js → esm2020/datetimepicker/datetimepicker-animations.mjs} +0 -0
  126. package/{esm2015/datetimepicker/datetimepicker-errors.js → esm2020/datetimepicker/datetimepicker-errors.mjs} +0 -0
  127. package/{esm2015/datetimepicker/datetimepicker-filtertype.js → esm2020/datetimepicker/datetimepicker-filtertype.mjs} +0 -0
  128. package/esm2020/datetimepicker/datetimepicker-input.mjs +344 -0
  129. package/esm2020/datetimepicker/datetimepicker-module.mjs +75 -0
  130. package/esm2020/datetimepicker/datetimepicker-toggle.mjs +94 -0
  131. package/esm2020/datetimepicker/datetimepicker-types.mjs +2 -0
  132. package/esm2020/datetimepicker/datetimepicker.mjs +492 -0
  133. package/esm2020/datetimepicker/month-view.mjs +148 -0
  134. package/{esm2015/datetimepicker/mtxDatetimepicker.js → esm2020/datetimepicker/mtxDatetimepicker.mjs} +0 -0
  135. package/esm2020/datetimepicker/multi-year-view.mjs +214 -0
  136. package/{esm2015/datetimepicker/public-api.js → esm2020/datetimepicker/public-api.mjs} +2 -1
  137. package/esm2020/datetimepicker/year-view.mjs +138 -0
  138. package/{esm2015/dialog/dialog-config.js → esm2020/dialog/dialog-config.mjs} +0 -0
  139. package/esm2020/dialog/dialog.component.mjs +33 -0
  140. package/esm2020/dialog/dialog.mjs +74 -0
  141. package/esm2020/dialog/dialog.module.mjs +24 -0
  142. package/{esm2015/dialog/mtxDialog.js → esm2020/dialog/mtxDialog.mjs} +0 -0
  143. package/{esm2015/dialog/public-api.js → esm2020/dialog/public-api.mjs} +0 -0
  144. package/esm2020/form-group/form-group.component.mjs +37 -0
  145. package/esm2020/form-group/form-group.module.mjs +18 -0
  146. package/{esm2015/form-group/mtxFormGroup.js → esm2020/form-group/mtxFormGroup.mjs} +0 -0
  147. package/{esm2015/form-group/public-api.js → esm2020/form-group/public-api.mjs} +0 -0
  148. package/esm2020/grid/cell.component.mjs +108 -0
  149. package/esm2020/grid/column-menu.component.mjs +95 -0
  150. package/esm2020/grid/column-resize/column-resize-directives/column-resize-flex.mjs +37 -0
  151. package/esm2020/grid/column-resize/column-resize-directives/column-resize.mjs +37 -0
  152. package/{esm2015/grid/column-resize/column-resize-directives/common.js → esm2020/grid/column-resize/column-resize-directives/common.mjs} +0 -0
  153. package/esm2020/grid/column-resize/column-resize-module.mjs +42 -0
  154. package/esm2020/grid/column-resize/overlay-handle.mjs +60 -0
  155. package/{esm2015/grid/column-resize/resizable-directives/common.js → esm2020/grid/column-resize/resizable-directives/common.mjs} +0 -0
  156. package/esm2020/grid/column-resize/resizable-directives/resizable.mjs +62 -0
  157. package/esm2020/grid/column-resize/resize-strategy.mjs +42 -0
  158. package/esm2020/grid/expansion-toggle.directive.mjs +64 -0
  159. package/esm2020/grid/grid.component.mjs +556 -0
  160. package/{esm2015/grid/grid.interface.js → esm2020/grid/grid.interface.mjs} +0 -0
  161. package/esm2020/grid/grid.module.mjs +117 -0
  162. package/esm2020/grid/grid.service.mjs +44 -0
  163. package/{esm2015/grid/mtxGrid.js → esm2020/grid/mtxGrid.mjs} +0 -0
  164. package/esm2020/grid/public-api.mjs +16 -0
  165. package/esm2020/loader/loader.component.mjs +63 -0
  166. package/esm2020/loader/loader.module.mjs +20 -0
  167. package/{esm2015/loader/mtxLoader.js → esm2020/loader/mtxLoader.mjs} +0 -0
  168. package/{esm2015/loader/public-api.js → esm2020/loader/public-api.mjs} +0 -0
  169. package/esm2020/ng-matero-extensions.mjs +5 -0
  170. package/{esm2015/popover/mtxPopover.js → esm2020/popover/mtxPopover.mjs} +0 -0
  171. package/{esm2015/popover/popover-animations.js → esm2020/popover/popover-animations.mjs} +0 -0
  172. package/{esm2015/popover/popover-errors.js → esm2020/popover/popover-errors.mjs} +0 -0
  173. package/{esm2015/popover/popover-interfaces.js → esm2020/popover/popover-interfaces.mjs} +0 -0
  174. package/esm2020/popover/popover-module.mjs +22 -0
  175. package/esm2020/popover/popover-target.mjs +17 -0
  176. package/esm2020/popover/popover-trigger.mjs +441 -0
  177. package/{esm2015/popover/popover-types.js → esm2020/popover/popover-types.mjs} +0 -0
  178. package/esm2020/popover/popover.mjs +334 -0
  179. package/{esm2015/popover/public-api.js → esm2020/popover/public-api.mjs} +0 -0
  180. package/{esm2015/progress/mtxProgress.js → esm2020/progress/mtxProgress.mjs} +0 -0
  181. package/esm2020/progress/progress.component.mjs +55 -0
  182. package/esm2020/progress/progress.module.mjs +18 -0
  183. package/{esm2015/progress/public-api.js → esm2020/progress/public-api.mjs} +0 -0
  184. package/esm2020/public-api.mjs +5 -0
  185. package/{esm2015/select/mtxSelect.js → esm2020/select/mtxSelect.mjs} +0 -0
  186. package/{esm2015/select/option.component.js → esm2020/select/option.component.mjs} +18 -26
  187. package/{esm2015/select/public-api.js → esm2020/select/public-api.mjs} +0 -0
  188. package/esm2020/select/select.component.mjs +459 -0
  189. package/esm2020/select/select.module.mjs +74 -0
  190. package/esm2020/select/templates.directive.mjs +124 -0
  191. package/{esm2015/slider/mtxSlider.js → esm2020/slider/mtxSlider.mjs} +0 -0
  192. package/{esm2015/slider/public-api.js → esm2020/slider/public-api.mjs} +0 -0
  193. package/esm2020/slider/slider-module.mjs +19 -0
  194. package/esm2020/slider/slider.mjs +1115 -0
  195. package/{esm2015/split/interface.js → esm2020/split/interface.mjs} +0 -0
  196. package/{esm2015/split/mtxSplit.js → esm2020/split/mtxSplit.mjs} +0 -0
  197. package/{esm2015/split/public-api.js → esm2020/split/public-api.mjs} +0 -0
  198. package/esm2020/split/split-pane.directive.mjs +149 -0
  199. package/esm2020/split/split.component.mjs +619 -0
  200. package/esm2020/split/split.module.mjs +19 -0
  201. package/{esm2015/split/utils.js → esm2020/split/utils.mjs} +0 -0
  202. package/{esm2015/text3d/mtxText3d.js → esm2020/text3d/mtxText3d.mjs} +0 -0
  203. package/{esm2015/text3d/public-api.js → esm2020/text3d/public-api.mjs} +0 -0
  204. package/esm2020/text3d/text3d.component.mjs +45 -0
  205. package/esm2020/text3d/text3d.module.mjs +18 -0
  206. package/{esm2015/tooltip/mtxTooltip.js → esm2020/tooltip/mtxTooltip.mjs} +0 -0
  207. package/{esm2015/tooltip/public-api.js → esm2020/tooltip/public-api.mjs} +0 -0
  208. package/{esm2015/tooltip/tooltip-animations.js → esm2020/tooltip/tooltip-animations.mjs} +0 -0
  209. package/esm2020/tooltip/tooltip-module.mjs +23 -0
  210. package/esm2020/tooltip/tooltip.mjs +674 -0
  211. package/fesm2015/mtxAlert.mjs +74 -0
  212. package/fesm2015/mtxAlert.mjs.map +1 -0
  213. package/fesm2015/mtxButton.mjs +102 -0
  214. package/fesm2015/mtxButton.mjs.map +1 -0
  215. package/fesm2015/mtxCheckboxGroup.mjs +257 -0
  216. package/fesm2015/mtxCheckboxGroup.mjs.map +1 -0
  217. package/fesm2015/mtxColorpicker.mjs +754 -0
  218. package/fesm2015/mtxColorpicker.mjs.map +1 -0
  219. package/fesm2015/{mtxColumnResize.js → mtxColumnResize.mjs} +108 -145
  220. package/fesm2015/mtxColumnResize.mjs.map +1 -0
  221. package/fesm2015/mtxCore.mjs +362 -0
  222. package/fesm2015/mtxCore.mjs.map +1 -0
  223. package/fesm2015/mtxDatetimepicker.mjs +2474 -0
  224. package/fesm2015/mtxDatetimepicker.mjs.map +1 -0
  225. package/fesm2015/mtxDialog.mjs +128 -0
  226. package/fesm2015/mtxDialog.mjs.map +1 -0
  227. package/fesm2015/mtxFormGroup.mjs +59 -0
  228. package/fesm2015/mtxFormGroup.mjs.map +1 -0
  229. package/fesm2015/mtxGrid.mjs +1271 -0
  230. package/fesm2015/mtxGrid.mjs.map +1 -0
  231. package/fesm2015/mtxLoader.mjs +87 -0
  232. package/fesm2015/mtxLoader.mjs.map +1 -0
  233. package/fesm2015/mtxPopover.mjs +865 -0
  234. package/fesm2015/mtxPopover.mjs.map +1 -0
  235. package/fesm2015/mtxProgress.mjs +77 -0
  236. package/fesm2015/mtxProgress.mjs.map +1 -0
  237. package/fesm2015/mtxSelect.mjs +713 -0
  238. package/fesm2015/mtxSelect.mjs.map +1 -0
  239. package/fesm2015/mtxSlider.mjs +1139 -0
  240. package/fesm2015/mtxSlider.mjs.map +1 -0
  241. package/fesm2015/{mtxSplit.js → mtxSplit.mjs} +75 -85
  242. package/fesm2015/mtxSplit.mjs.map +1 -0
  243. package/fesm2015/mtxText3d.mjs +67 -0
  244. package/fesm2015/mtxText3d.mjs.map +1 -0
  245. package/fesm2015/{mtxTooltip.js → mtxTooltip.mjs} +83 -86
  246. package/fesm2015/mtxTooltip.mjs.map +1 -0
  247. package/fesm2015/ng-matero-extensions.mjs +9 -0
  248. package/fesm2015/ng-matero-extensions.mjs.map +1 -0
  249. package/fesm2020/mtxAlert.mjs +74 -0
  250. package/fesm2020/mtxAlert.mjs.map +1 -0
  251. package/fesm2020/mtxButton.mjs +102 -0
  252. package/fesm2020/mtxButton.mjs.map +1 -0
  253. package/fesm2020/mtxCheckboxGroup.mjs +257 -0
  254. package/fesm2020/mtxCheckboxGroup.mjs.map +1 -0
  255. package/{fesm2015/mtxColorpicker.js → fesm2020/mtxColorpicker.mjs} +420 -413
  256. package/fesm2020/mtxColorpicker.mjs.map +1 -0
  257. package/fesm2020/mtxColumnResize.mjs +953 -0
  258. package/fesm2020/mtxColumnResize.mjs.map +1 -0
  259. package/{fesm2015/mtxCore.js → fesm2020/mtxCore.mjs} +75 -42
  260. package/fesm2020/mtxCore.mjs.map +1 -0
  261. package/{fesm2015/mtxDatetimepicker.js → fesm2020/mtxDatetimepicker.mjs} +1300 -1306
  262. package/fesm2020/mtxDatetimepicker.mjs.map +1 -0
  263. package/fesm2020/mtxDialog.mjs +129 -0
  264. package/fesm2020/mtxDialog.mjs.map +1 -0
  265. package/fesm2020/mtxFormGroup.mjs +59 -0
  266. package/fesm2020/mtxFormGroup.mjs.map +1 -0
  267. package/fesm2020/mtxGrid.mjs +1259 -0
  268. package/fesm2020/mtxGrid.mjs.map +1 -0
  269. package/fesm2020/mtxLoader.mjs +87 -0
  270. package/fesm2020/mtxLoader.mjs.map +1 -0
  271. package/{fesm2015/mtxPopover.js → fesm2020/mtxPopover.mjs} +120 -111
  272. package/fesm2020/mtxPopover.mjs.map +1 -0
  273. package/fesm2020/mtxProgress.mjs +77 -0
  274. package/fesm2020/mtxProgress.mjs.map +1 -0
  275. package/fesm2020/mtxSelect.mjs +710 -0
  276. package/fesm2020/mtxSelect.mjs.map +1 -0
  277. package/{fesm2015/mtxSlider.js → fesm2020/mtxSlider.mjs} +97 -94
  278. package/fesm2020/mtxSlider.mjs.map +1 -0
  279. package/fesm2020/mtxSplit.mjs +1007 -0
  280. package/fesm2020/mtxSplit.mjs.map +1 -0
  281. package/fesm2020/mtxText3d.mjs +67 -0
  282. package/fesm2020/mtxText3d.mjs.map +1 -0
  283. package/fesm2020/mtxTooltip.mjs +718 -0
  284. package/fesm2020/mtxTooltip.mjs.map +1 -0
  285. package/fesm2020/ng-matero-extensions.mjs +9 -0
  286. package/fesm2020/ng-matero-extensions.mjs.map +1 -0
  287. package/form-group/_form-group-theme.scss +1 -1
  288. package/form-group/form-group.component.d.ts +3 -0
  289. package/form-group/form-group.module.d.ts +6 -0
  290. package/form-group/mtxFormGroup.d.ts +1 -0
  291. package/form-group/package.json +5 -6
  292. package/grid/_grid-theme.scss +1 -1
  293. package/grid/cell.component.d.ts +3 -0
  294. package/grid/column-menu.component.d.ts +3 -0
  295. package/grid/column-menu.component.scss +1 -1
  296. package/grid/column-resize/_column-resize.scss +3 -3
  297. package/grid/column-resize/column-resize-directives/column-resize-flex.d.ts +3 -0
  298. package/grid/column-resize/column-resize-directives/column-resize.d.ts +3 -0
  299. package/grid/column-resize/column-resize-module.d.ts +12 -7
  300. package/grid/column-resize/overlay-handle.d.ts +3 -0
  301. package/grid/column-resize/resizable-directives/resizable.d.ts +3 -0
  302. package/grid/column-resize/resize-strategy.d.ts +3 -0
  303. package/grid/expansion-toggle.directive.d.ts +3 -0
  304. package/grid/grid.component.d.ts +20 -1
  305. package/grid/grid.module.d.ts +26 -0
  306. package/grid/grid.service.d.ts +3 -0
  307. package/grid/mtxGrid.d.ts +1 -0
  308. package/grid/package.json +5 -6
  309. package/grid/public-api.d.ts +0 -1
  310. package/loader/_loader-theme.scss +1 -1
  311. package/loader/loader.component.d.ts +3 -0
  312. package/loader/loader.module.d.ts +8 -0
  313. package/loader/mtxLoader.d.ts +1 -0
  314. package/loader/package.json +5 -6
  315. package/{extensions.d.ts → ng-matero-extensions.d.ts} +1 -0
  316. package/package.json +178 -15
  317. package/popover/_popover-theme.scss +1 -1
  318. package/popover/mtxPopover.d.ts +1 -0
  319. package/popover/package.json +5 -6
  320. package/popover/popover-module.d.ts +10 -0
  321. package/popover/popover-target.d.ts +3 -0
  322. package/popover/popover-trigger.d.ts +3 -0
  323. package/popover/popover.d.ts +3 -0
  324. package/progress/_progress-theme.scss +2 -2
  325. package/progress/mtxProgress.d.ts +1 -0
  326. package/progress/package.json +5 -6
  327. package/progress/progress.component.d.ts +3 -0
  328. package/progress/progress.module.d.ts +6 -0
  329. package/public-api.d.ts +2 -19
  330. package/select/_select-theme.scss +1 -1
  331. package/select/mtxSelect.d.ts +1 -0
  332. package/select/option.component.d.ts +3 -0
  333. package/select/package.json +5 -6
  334. package/select/select.component.d.ts +3 -0
  335. package/select/select.component.scss +1 -1
  336. package/select/select.module.d.ts +10 -0
  337. package/select/templates.directive.d.ts +23 -0
  338. package/slider/_slider-theme.scss +4 -4
  339. package/slider/mtxSlider.d.ts +1 -0
  340. package/slider/package.json +5 -6
  341. package/slider/slider-module.d.ts +7 -0
  342. package/slider/slider.d.ts +4 -1
  343. package/slider/slider.scss +7 -7
  344. package/split/_split-theme.scss +1 -1
  345. package/split/mtxSplit.d.ts +1 -0
  346. package/split/package.json +5 -6
  347. package/split/split-pane.directive.d.ts +3 -0
  348. package/split/split.component.d.ts +4 -1
  349. package/split/split.module.d.ts +7 -0
  350. package/text3d/_text3d-theme.scss +2 -2
  351. package/text3d/mtxText3d.d.ts +1 -0
  352. package/text3d/package.json +5 -6
  353. package/text3d/text3d.component.d.ts +3 -0
  354. package/text3d/text3d.module.d.ts +6 -0
  355. package/tooltip/_tooltip-theme.scss +3 -3
  356. package/tooltip/mtxTooltip.d.ts +1 -0
  357. package/tooltip/package.json +5 -6
  358. package/tooltip/tooltip-module.d.ts +10 -0
  359. package/tooltip/tooltip.d.ts +5 -0
  360. package/tooltip/tooltip.scss +1 -1
  361. package/alert/mtxAlert.metadata.json +0 -1
  362. package/bundles/extensions.umd.js +0 -164
  363. package/bundles/extensions.umd.js.map +0 -1
  364. package/bundles/mtxAlert.umd.js +0 -101
  365. package/bundles/mtxAlert.umd.js.map +0 -1
  366. package/bundles/mtxButton.umd.js +0 -119
  367. package/bundles/mtxButton.umd.js.map +0 -1
  368. package/bundles/mtxCheckboxGroup.umd.js +0 -284
  369. package/bundles/mtxCheckboxGroup.umd.js.map +0 -1
  370. package/bundles/mtxColorpicker.umd.js +0 -1123
  371. package/bundles/mtxColorpicker.umd.js.map +0 -1
  372. package/bundles/mtxColumnResize.umd.js +0 -1339
  373. package/bundles/mtxColumnResize.umd.js.map +0 -1
  374. package/bundles/mtxCore.umd.js +0 -670
  375. package/bundles/mtxCore.umd.js.map +0 -1
  376. package/bundles/mtxDatetimepicker.umd.js +0 -3045
  377. package/bundles/mtxDatetimepicker.umd.js.map +0 -1
  378. package/bundles/mtxDialog.umd.js +0 -158
  379. package/bundles/mtxDialog.umd.js.map +0 -1
  380. package/bundles/mtxFormGroup.umd.js +0 -73
  381. package/bundles/mtxFormGroup.umd.js.map +0 -1
  382. package/bundles/mtxGrid.umd.js +0 -1581
  383. package/bundles/mtxGrid.umd.js.map +0 -1
  384. package/bundles/mtxLoader.umd.js +0 -107
  385. package/bundles/mtxLoader.umd.js.map +0 -1
  386. package/bundles/mtxPipes.umd.js +0 -44
  387. package/bundles/mtxPipes.umd.js.map +0 -1
  388. package/bundles/mtxPopover.umd.js +0 -1260
  389. package/bundles/mtxPopover.umd.js.map +0 -1
  390. package/bundles/mtxProgress.umd.js +0 -92
  391. package/bundles/mtxProgress.umd.js.map +0 -1
  392. package/bundles/mtxSelect.umd.js +0 -1097
  393. package/bundles/mtxSelect.umd.js.map +0 -1
  394. package/bundles/mtxSlider.umd.js +0 -1551
  395. package/bundles/mtxSlider.umd.js.map +0 -1
  396. package/bundles/mtxSplit.umd.js +0 -1431
  397. package/bundles/mtxSplit.umd.js.map +0 -1
  398. package/bundles/mtxText3d.umd.js +0 -84
  399. package/bundles/mtxText3d.umd.js.map +0 -1
  400. package/bundles/mtxTooltip.umd.js +0 -1083
  401. package/bundles/mtxTooltip.umd.js.map +0 -1
  402. package/button/mtxButton.metadata.json +0 -1
  403. package/checkbox-group/mtxCheckboxGroup.metadata.json +0 -1
  404. package/colorpicker/mtxColorpicker.metadata.json +0 -1
  405. package/column-resize/mtxColumnResize.metadata.json +0 -1
  406. package/core/mtxCore.metadata.json +0 -1
  407. package/datetimepicker/mtxDatetimepicker.metadata.json +0 -1
  408. package/dialog/mtxDialog.metadata.json +0 -1
  409. package/esm2015/alert/alert.component.js +0 -63
  410. package/esm2015/alert/alert.module.js +0 -14
  411. package/esm2015/button/button-loading.directive.js +0 -89
  412. package/esm2015/button/button.module.js +0 -16
  413. package/esm2015/checkbox-group/checkbox-group.component.js +0 -235
  414. package/esm2015/checkbox-group/checkbox-group.module.js +0 -17
  415. package/esm2015/colorpicker/colorpicker-input.js +0 -228
  416. package/esm2015/colorpicker/colorpicker-module.js +0 -41
  417. package/esm2015/colorpicker/colorpicker-toggle.js +0 -97
  418. package/esm2015/colorpicker/colorpicker.js +0 -372
  419. package/esm2015/column-resize/column-resize-directives/column-resize-flex.js +0 -54
  420. package/esm2015/column-resize/column-resize-directives/column-resize.js +0 -54
  421. package/esm2015/column-resize/column-resize-module.js +0 -24
  422. package/esm2015/column-resize/column-resize-notifier.js +0 -54
  423. package/esm2015/column-resize/column-resize.js +0 -80
  424. package/esm2015/column-resize/column-size-store.js +0 -18
  425. package/esm2015/column-resize/event-dispatcher.js +0 -75
  426. package/esm2015/column-resize/overlay-handle.js +0 -144
  427. package/esm2015/column-resize/resizable.js +0 -197
  428. package/esm2015/column-resize/resize-strategy.js +0 -245
  429. package/esm2015/core/datetime/datetime.module.js +0 -32
  430. package/esm2015/core/datetime/native-datetime-adapter.js +0 -144
  431. package/esm2015/datetimepicker/calendar-body.js +0 -76
  432. package/esm2015/datetimepicker/calendar.js +0 -614
  433. package/esm2015/datetimepicker/clock.js +0 -283
  434. package/esm2015/datetimepicker/datetimepicker-input.js +0 -336
  435. package/esm2015/datetimepicker/datetimepicker-module.js +0 -52
  436. package/esm2015/datetimepicker/datetimepicker-toggle.js +0 -103
  437. package/esm2015/datetimepicker/datetimepicker.js +0 -490
  438. package/esm2015/datetimepicker/month-view.js +0 -150
  439. package/esm2015/datetimepicker/multi-year-view.js +0 -215
  440. package/esm2015/datetimepicker/year-view.js +0 -141
  441. package/esm2015/dialog/dialog.component.js +0 -40
  442. package/esm2015/dialog/dialog.js +0 -81
  443. package/esm2015/dialog/dialog.module.js +0 -21
  444. package/esm2015/extensions-experimental.module.js +0 -13
  445. package/esm2015/extensions.js +0 -5
  446. package/esm2015/extensions.module.js +0 -40
  447. package/esm2015/form-group/form-group.component.js +0 -40
  448. package/esm2015/form-group/form-group.module.js +0 -14
  449. package/esm2015/grid/cell-selection.directive.js +0 -62
  450. package/esm2015/grid/cell.component.js +0 -115
  451. package/esm2015/grid/column-menu.component.js +0 -72
  452. package/esm2015/grid/column-resize/column-resize-directives/column-resize-flex.js +0 -47
  453. package/esm2015/grid/column-resize/column-resize-directives/column-resize.js +0 -47
  454. package/esm2015/grid/column-resize/column-resize-module.js +0 -36
  455. package/esm2015/grid/column-resize/overlay-handle.js +0 -68
  456. package/esm2015/grid/column-resize/resizable-directives/resizable.js +0 -75
  457. package/esm2015/grid/column-resize/resize-strategy.js +0 -45
  458. package/esm2015/grid/expansion-toggle.directive.js +0 -62
  459. package/esm2015/grid/grid.component.js +0 -418
  460. package/esm2015/grid/grid.module.js +0 -69
  461. package/esm2015/grid/grid.service.js +0 -50
  462. package/esm2015/grid/public-api.js +0 -17
  463. package/esm2015/loader/loader.component.js +0 -69
  464. package/esm2015/loader/loader.module.js +0 -16
  465. package/esm2015/pipes/mtxPipes.js +0 -5
  466. package/esm2015/pipes/pipes.module.js +0 -14
  467. package/esm2015/pipes/public-api.js +0 -3
  468. package/esm2015/pipes/to-observable.pipe.js +0 -12
  469. package/esm2015/popover/popover-module.js +0 -18
  470. package/esm2015/popover/popover-target.js +0 -24
  471. package/esm2015/popover/popover-trigger.js +0 -434
  472. package/esm2015/popover/popover.js +0 -326
  473. package/esm2015/progress/progress.component.js +0 -54
  474. package/esm2015/progress/progress.module.js +0 -14
  475. package/esm2015/public-api.js +0 -23
  476. package/esm2015/select/select.component.js +0 -380
  477. package/esm2015/select/select.module.js +0 -46
  478. package/esm2015/select/templates.directive.js +0 -211
  479. package/esm2015/slider/slider-module.js +0 -15
  480. package/esm2015/slider/slider.js +0 -1115
  481. package/esm2015/split/split-pane.directive.js +0 -156
  482. package/esm2015/split/split.component.js +0 -624
  483. package/esm2015/split/split.module.js +0 -15
  484. package/esm2015/text3d/text3d.component.js +0 -45
  485. package/esm2015/text3d/text3d.module.js +0 -14
  486. package/esm2015/tooltip/tooltip-module.js +0 -20
  487. package/esm2015/tooltip/tooltip.js +0 -683
  488. package/extensions-experimental.module.d.ts +0 -2
  489. package/extensions.metadata.json +0 -1
  490. package/extensions.module.d.ts +0 -2
  491. package/fesm2015/extensions.js +0 -80
  492. package/fesm2015/extensions.js.map +0 -1
  493. package/fesm2015/mtxAlert.js +0 -82
  494. package/fesm2015/mtxAlert.js.map +0 -1
  495. package/fesm2015/mtxButton.js +0 -108
  496. package/fesm2015/mtxButton.js.map +0 -1
  497. package/fesm2015/mtxCheckboxGroup.js +0 -255
  498. package/fesm2015/mtxCheckboxGroup.js.map +0 -1
  499. package/fesm2015/mtxColorpicker.js.map +0 -1
  500. package/fesm2015/mtxColumnResize.js.map +0 -1
  501. package/fesm2015/mtxCore.js.map +0 -1
  502. package/fesm2015/mtxDatetimepicker.js.map +0 -1
  503. package/fesm2015/mtxDialog.js +0 -141
  504. package/fesm2015/mtxDialog.js.map +0 -1
  505. package/fesm2015/mtxFormGroup.js +0 -59
  506. package/fesm2015/mtxFormGroup.js.map +0 -1
  507. package/fesm2015/mtxGrid.js +0 -1186
  508. package/fesm2015/mtxGrid.js.map +0 -1
  509. package/fesm2015/mtxLoader.js +0 -90
  510. package/fesm2015/mtxLoader.js.map +0 -1
  511. package/fesm2015/mtxPipes.js +0 -31
  512. package/fesm2015/mtxPipes.js.map +0 -1
  513. package/fesm2015/mtxPopover.js.map +0 -1
  514. package/fesm2015/mtxProgress.js +0 -73
  515. package/fesm2015/mtxProgress.js.map +0 -1
  516. package/fesm2015/mtxSelect.js +0 -700
  517. package/fesm2015/mtxSelect.js.map +0 -1
  518. package/fesm2015/mtxSlider.js.map +0 -1
  519. package/fesm2015/mtxSplit.js.map +0 -1
  520. package/fesm2015/mtxText3d.js +0 -64
  521. package/fesm2015/mtxText3d.js.map +0 -1
  522. package/fesm2015/mtxTooltip.js.map +0 -1
  523. package/form-group/mtxFormGroup.metadata.json +0 -1
  524. package/grid/cell-selection.directive.d.ts +0 -17
  525. package/grid/mtxGrid.metadata.json +0 -1
  526. package/loader/mtxLoader.metadata.json +0 -1
  527. package/pipes/mtxPipes.d.ts +0 -4
  528. package/pipes/mtxPipes.metadata.json +0 -1
  529. package/pipes/package.json +0 -11
  530. package/pipes/pipes.module.d.ts +0 -2
  531. package/popover/mtxPopover.metadata.json +0 -1
  532. package/progress/mtxProgress.metadata.json +0 -1
  533. package/select/mtxSelect.metadata.json +0 -1
  534. package/slider/mtxSlider.metadata.json +0 -1
  535. package/split/mtxSplit.metadata.json +0 -1
  536. package/text3d/mtxText3d.metadata.json +0 -1
  537. package/tooltip/mtxTooltip.metadata.json +0 -1
@@ -1,1339 +0,0 @@
1
- (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('rxjs'), require('rxjs/operators'), require('@angular/cdk/table'), require('@angular/common'), require('@angular/cdk/coercion'), require('@angular/cdk/portal'), require('@angular/cdk/keycodes')) :
3
- typeof define === 'function' && define.amd ? define('@ng-matero/extensions/column-resize', ['exports', '@angular/core', 'rxjs', 'rxjs/operators', '@angular/cdk/table', '@angular/common', '@angular/cdk/coercion', '@angular/cdk/portal', '@angular/cdk/keycodes'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["ng-matero"] = global["ng-matero"] || {}, global["ng-matero"].extensions = global["ng-matero"].extensions || {}, global["ng-matero"].extensions["column-resize"] = {}), global.ng.core, global.rxjs, global.rxjs.operators, global.ng.cdk.table, global.ng.common, global.ng.cdk.coercion, global.ng.cdk.portal, global.ng.cdk.keycodes));
5
- })(this, (function (exports, core, rxjs, operators, table, common, coercion, portal, keycodes) { 'use strict';
6
-
7
- /*! *****************************************************************************
8
- Copyright (c) Microsoft Corporation.
9
-
10
- Permission to use, copy, modify, and/or distribute this software for any
11
- purpose with or without fee is hereby granted.
12
-
13
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
14
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
15
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
16
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
17
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
18
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19
- PERFORMANCE OF THIS SOFTWARE.
20
- ***************************************************************************** */
21
- /* global Reflect, Promise */
22
- var extendStatics = function (d, b) {
23
- extendStatics = Object.setPrototypeOf ||
24
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
25
- function (d, b) { for (var p in b)
26
- if (Object.prototype.hasOwnProperty.call(b, p))
27
- d[p] = b[p]; };
28
- return extendStatics(d, b);
29
- };
30
- function __extends(d, b) {
31
- if (typeof b !== "function" && b !== null)
32
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
33
- extendStatics(d, b);
34
- function __() { this.constructor = d; }
35
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
36
- }
37
- var __assign = function () {
38
- __assign = Object.assign || function __assign(t) {
39
- for (var s, i = 1, n = arguments.length; i < n; i++) {
40
- s = arguments[i];
41
- for (var p in s)
42
- if (Object.prototype.hasOwnProperty.call(s, p))
43
- t[p] = s[p];
44
- }
45
- return t;
46
- };
47
- return __assign.apply(this, arguments);
48
- };
49
- function __rest(s, e) {
50
- var t = {};
51
- for (var p in s)
52
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
53
- t[p] = s[p];
54
- if (s != null && typeof Object.getOwnPropertySymbols === "function")
55
- for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
56
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
57
- t[p[i]] = s[p[i]];
58
- }
59
- return t;
60
- }
61
- function __decorate(decorators, target, key, desc) {
62
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
63
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
64
- r = Reflect.decorate(decorators, target, key, desc);
65
- else
66
- for (var i = decorators.length - 1; i >= 0; i--)
67
- if (d = decorators[i])
68
- r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
69
- return c > 3 && r && Object.defineProperty(target, key, r), r;
70
- }
71
- function __param(paramIndex, decorator) {
72
- return function (target, key) { decorator(target, key, paramIndex); };
73
- }
74
- function __metadata(metadataKey, metadataValue) {
75
- if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
76
- return Reflect.metadata(metadataKey, metadataValue);
77
- }
78
- function __awaiter(thisArg, _arguments, P, generator) {
79
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
80
- return new (P || (P = Promise))(function (resolve, reject) {
81
- function fulfilled(value) { try {
82
- step(generator.next(value));
83
- }
84
- catch (e) {
85
- reject(e);
86
- } }
87
- function rejected(value) { try {
88
- step(generator["throw"](value));
89
- }
90
- catch (e) {
91
- reject(e);
92
- } }
93
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
94
- step((generator = generator.apply(thisArg, _arguments || [])).next());
95
- });
96
- }
97
- function __generator(thisArg, body) {
98
- var _ = { label: 0, sent: function () { if (t[0] & 1)
99
- throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
100
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g;
101
- function verb(n) { return function (v) { return step([n, v]); }; }
102
- function step(op) {
103
- if (f)
104
- throw new TypeError("Generator is already executing.");
105
- while (_)
106
- try {
107
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
108
- return t;
109
- if (y = 0, t)
110
- op = [op[0] & 2, t.value];
111
- switch (op[0]) {
112
- case 0:
113
- case 1:
114
- t = op;
115
- break;
116
- case 4:
117
- _.label++;
118
- return { value: op[1], done: false };
119
- case 5:
120
- _.label++;
121
- y = op[1];
122
- op = [0];
123
- continue;
124
- case 7:
125
- op = _.ops.pop();
126
- _.trys.pop();
127
- continue;
128
- default:
129
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
130
- _ = 0;
131
- continue;
132
- }
133
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {
134
- _.label = op[1];
135
- break;
136
- }
137
- if (op[0] === 6 && _.label < t[1]) {
138
- _.label = t[1];
139
- t = op;
140
- break;
141
- }
142
- if (t && _.label < t[2]) {
143
- _.label = t[2];
144
- _.ops.push(op);
145
- break;
146
- }
147
- if (t[2])
148
- _.ops.pop();
149
- _.trys.pop();
150
- continue;
151
- }
152
- op = body.call(thisArg, _);
153
- }
154
- catch (e) {
155
- op = [6, e];
156
- y = 0;
157
- }
158
- finally {
159
- f = t = 0;
160
- }
161
- if (op[0] & 5)
162
- throw op[1];
163
- return { value: op[0] ? op[1] : void 0, done: true };
164
- }
165
- }
166
- var __createBinding = Object.create ? (function (o, m, k, k2) {
167
- if (k2 === undefined)
168
- k2 = k;
169
- Object.defineProperty(o, k2, { enumerable: true, get: function () { return m[k]; } });
170
- }) : (function (o, m, k, k2) {
171
- if (k2 === undefined)
172
- k2 = k;
173
- o[k2] = m[k];
174
- });
175
- function __exportStar(m, o) {
176
- for (var p in m)
177
- if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
178
- __createBinding(o, m, p);
179
- }
180
- function __values(o) {
181
- var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
182
- if (m)
183
- return m.call(o);
184
- if (o && typeof o.length === "number")
185
- return {
186
- next: function () {
187
- if (o && i >= o.length)
188
- o = void 0;
189
- return { value: o && o[i++], done: !o };
190
- }
191
- };
192
- throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
193
- }
194
- function __read(o, n) {
195
- var m = typeof Symbol === "function" && o[Symbol.iterator];
196
- if (!m)
197
- return o;
198
- var i = m.call(o), r, ar = [], e;
199
- try {
200
- while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
201
- ar.push(r.value);
202
- }
203
- catch (error) {
204
- e = { error: error };
205
- }
206
- finally {
207
- try {
208
- if (r && !r.done && (m = i["return"]))
209
- m.call(i);
210
- }
211
- finally {
212
- if (e)
213
- throw e.error;
214
- }
215
- }
216
- return ar;
217
- }
218
- /** @deprecated */
219
- function __spread() {
220
- for (var ar = [], i = 0; i < arguments.length; i++)
221
- ar = ar.concat(__read(arguments[i]));
222
- return ar;
223
- }
224
- /** @deprecated */
225
- function __spreadArrays() {
226
- for (var s = 0, i = 0, il = arguments.length; i < il; i++)
227
- s += arguments[i].length;
228
- for (var r = Array(s), k = 0, i = 0; i < il; i++)
229
- for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
230
- r[k] = a[j];
231
- return r;
232
- }
233
- function __spreadArray(to, from, pack) {
234
- if (pack || arguments.length === 2)
235
- for (var i = 0, l = from.length, ar; i < l; i++) {
236
- if (ar || !(i in from)) {
237
- if (!ar)
238
- ar = Array.prototype.slice.call(from, 0, i);
239
- ar[i] = from[i];
240
- }
241
- }
242
- return to.concat(ar || from);
243
- }
244
- function __await(v) {
245
- return this instanceof __await ? (this.v = v, this) : new __await(v);
246
- }
247
- function __asyncGenerator(thisArg, _arguments, generator) {
248
- if (!Symbol.asyncIterator)
249
- throw new TypeError("Symbol.asyncIterator is not defined.");
250
- var g = generator.apply(thisArg, _arguments || []), i, q = [];
251
- return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
252
- function verb(n) { if (g[n])
253
- i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
254
- function resume(n, v) { try {
255
- step(g[n](v));
256
- }
257
- catch (e) {
258
- settle(q[0][3], e);
259
- } }
260
- function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
261
- function fulfill(value) { resume("next", value); }
262
- function reject(value) { resume("throw", value); }
263
- function settle(f, v) { if (f(v), q.shift(), q.length)
264
- resume(q[0][0], q[0][1]); }
265
- }
266
- function __asyncDelegator(o) {
267
- var i, p;
268
- return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
269
- function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === "return" } : f ? f(v) : v; } : f; }
270
- }
271
- function __asyncValues(o) {
272
- if (!Symbol.asyncIterator)
273
- throw new TypeError("Symbol.asyncIterator is not defined.");
274
- var m = o[Symbol.asyncIterator], i;
275
- return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
276
- function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
277
- function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }
278
- }
279
- function __makeTemplateObject(cooked, raw) {
280
- if (Object.defineProperty) {
281
- Object.defineProperty(cooked, "raw", { value: raw });
282
- }
283
- else {
284
- cooked.raw = raw;
285
- }
286
- return cooked;
287
- }
288
- ;
289
- var __setModuleDefault = Object.create ? (function (o, v) {
290
- Object.defineProperty(o, "default", { enumerable: true, value: v });
291
- }) : function (o, v) {
292
- o["default"] = v;
293
- };
294
- function __importStar(mod) {
295
- if (mod && mod.__esModule)
296
- return mod;
297
- var result = {};
298
- if (mod != null)
299
- for (var k in mod)
300
- if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
301
- __createBinding(result, mod, k);
302
- __setModuleDefault(result, mod);
303
- return result;
304
- }
305
- function __importDefault(mod) {
306
- return (mod && mod.__esModule) ? mod : { default: mod };
307
- }
308
- function __classPrivateFieldGet(receiver, state, kind, f) {
309
- if (kind === "a" && !f)
310
- throw new TypeError("Private accessor was defined without a getter");
311
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
312
- throw new TypeError("Cannot read private member from an object whose class did not declare it");
313
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
314
- }
315
- function __classPrivateFieldSet(receiver, state, value, kind, f) {
316
- if (kind === "m")
317
- throw new TypeError("Private method is not writable");
318
- if (kind === "a" && !f)
319
- throw new TypeError("Private accessor was defined without a setter");
320
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
321
- throw new TypeError("Cannot write private member to an object whose class did not declare it");
322
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
323
- }
324
-
325
- /**
326
- * @license
327
- * Copyright Google LLC All Rights Reserved.
328
- *
329
- * Use of this source code is governed by an MIT-style license that can be
330
- * found in the LICENSE file at https://angular.io/license
331
- */
332
- // TODO: Figure out how to remove `mat-` classes from the CDK part of the
333
- // column resize implementation.
334
- var HEADER_CELL_SELECTOR = '.cdk-header-cell, .mat-header-cell';
335
- var HEADER_ROW_SELECTOR = '.cdk-header-row, .mat-header-row';
336
- var RESIZE_OVERLAY_SELECTOR = '.mat-column-resize-overlay-thumb';
337
-
338
- /**
339
- * @license
340
- * Copyright Google LLC All Rights Reserved.
341
- *
342
- * Use of this source code is governed by an MIT-style license that can be
343
- * found in the LICENSE file at https://angular.io/license
344
- */
345
- /** IE 11 compatible matches implementation. */
346
- function matches(element, selector) {
347
- return element.matches ? element.matches(selector) : element.msMatchesSelector(selector);
348
- }
349
- /** IE 11 compatible closest implementation that is able to start from non-Element Nodes. */
350
- function closest(element, selector) {
351
- if (!(element instanceof Node)) {
352
- return null;
353
- }
354
- var curr = element;
355
- while (curr != null && !(curr instanceof Element)) {
356
- curr = curr.parentNode;
357
- }
358
- return (curr &&
359
- (hasNativeClosest
360
- ? curr.closest(selector)
361
- : polyfillClosest(curr, selector)));
362
- }
363
- /** Polyfill for browsers without Element.closest. */
364
- function polyfillClosest(element, selector) {
365
- var curr = element;
366
- while (curr != null && !(curr instanceof Element && matches(curr, selector))) {
367
- curr = curr.parentNode;
368
- }
369
- return (curr || null);
370
- }
371
- var hasNativeClosest = !!Element.prototype.closest;
372
-
373
- var HOVER_OR_ACTIVE_CLASS = 'cdk-column-resize-hover-or-active';
374
- var WITH_RESIZED_COLUMN_CLASS = 'cdk-column-resize-with-resized-column';
375
- var nextId = 0;
376
- /**
377
- * Base class for ColumnResize directives which attach to mat-table elements to
378
- * provide common events and services for column resizing.
379
- */
380
- var ColumnResize = /** @class */ (function () {
381
- function ColumnResize() {
382
- this.destroyed = new rxjs.Subject();
383
- /** Unique ID for this table instance. */
384
- this.selectorId = "" + ++nextId;
385
- }
386
- ColumnResize.prototype.ngAfterViewInit = function () {
387
- this.elementRef.nativeElement.classList.add(this.getUniqueCssClass());
388
- this._listenForRowHoverEvents();
389
- this._listenForResizeActivity();
390
- this._listenForHoverActivity();
391
- };
392
- ColumnResize.prototype.ngOnDestroy = function () {
393
- this.destroyed.next();
394
- this.destroyed.complete();
395
- };
396
- /** Gets the unique CSS class name for this table instance. */
397
- ColumnResize.prototype.getUniqueCssClass = function () {
398
- return "cdk-column-resize-" + this.selectorId;
399
- };
400
- /** Called when a column in the table is resized. Applies a css class to the table element. */
401
- ColumnResize.prototype.setResized = function () {
402
- this.elementRef.nativeElement.classList.add(WITH_RESIZED_COLUMN_CLASS);
403
- };
404
- ColumnResize.prototype._listenForRowHoverEvents = function () {
405
- var _this = this;
406
- this.ngZone.runOutsideAngular(function () {
407
- var element = _this.elementRef.nativeElement;
408
- rxjs.fromEvent(element, 'mouseover')
409
- .pipe(operators.map(function (event) { return closest(event.target, HEADER_CELL_SELECTOR); }), operators.takeUntil(_this.destroyed))
410
- .subscribe(_this.eventDispatcher.headerCellHovered);
411
- rxjs.fromEvent(element, 'mouseleave')
412
- .pipe(operators.filter(function (event) { return !!event.relatedTarget &&
413
- !matches(event.relatedTarget, RESIZE_OVERLAY_SELECTOR); }), operators.mapTo(null), operators.takeUntil(_this.destroyed))
414
- .subscribe(_this.eventDispatcher.headerCellHovered);
415
- });
416
- };
417
- ColumnResize.prototype._listenForResizeActivity = function () {
418
- var _this = this;
419
- rxjs.merge(this.eventDispatcher.overlayHandleActiveForCell.pipe(operators.mapTo(undefined)), this.notifier.triggerResize.pipe(operators.mapTo(undefined)), this.notifier.resizeCompleted.pipe(operators.mapTo(undefined)))
420
- .pipe(operators.take(1), operators.takeUntil(this.destroyed))
421
- .subscribe(function () {
422
- _this.setResized();
423
- });
424
- };
425
- ColumnResize.prototype._listenForHoverActivity = function () {
426
- this.eventDispatcher.headerRowHoveredOrActiveDistinct
427
- .pipe(operators.startWith(null), operators.pairwise(), operators.takeUntil(this.destroyed))
428
- .subscribe(function (_a) {
429
- var _b = __read(_a, 2), previousRow = _b[0], hoveredRow = _b[1];
430
- if (hoveredRow) {
431
- hoveredRow.classList.add(HOVER_OR_ACTIVE_CLASS);
432
- }
433
- if (previousRow) {
434
- previousRow.classList.remove(HOVER_OR_ACTIVE_CLASS);
435
- }
436
- });
437
- };
438
- return ColumnResize;
439
- }());
440
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
441
- ColumnResize.decorators = [
442
- { type: core.Directive }
443
- ];
444
-
445
- /**
446
- * @license
447
- * Copyright Google LLC All Rights Reserved.
448
- *
449
- * Use of this source code is governed by an MIT-style license that can be
450
- * found in the LICENSE file at https://angular.io/license
451
- */
452
- /**
453
- * Originating source of column resize events within a table.
454
- * @docs-private
455
- */
456
- var ColumnResizeNotifierSource = /** @class */ (function () {
457
- function ColumnResizeNotifierSource() {
458
- /** Emits when an in-progress resize is canceled. */
459
- this.resizeCanceled = new rxjs.Subject();
460
- /** Emits when a resize is applied. */
461
- this.resizeCompleted = new rxjs.Subject();
462
- /** Triggers a resize action. */
463
- this.triggerResize = new rxjs.Subject();
464
- }
465
- return ColumnResizeNotifierSource;
466
- }());
467
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
468
- ColumnResizeNotifierSource.decorators = [
469
- { type: core.Injectable }
470
- ];
471
- /** Service for triggering column resizes imperatively or being notified of them. */
472
- var ColumnResizeNotifier = /** @class */ (function () {
473
- function ColumnResizeNotifier(_source) {
474
- this._source = _source;
475
- /** Emits whenever a column is resized. */
476
- this.resizeCompleted = this._source.resizeCompleted;
477
- }
478
- /** Instantly resizes the specified column. */
479
- ColumnResizeNotifier.prototype.resize = function (columnId, size) {
480
- this._source.triggerResize.next({ columnId: columnId, size: size, completeImmediately: true, isStickyColumn: true });
481
- };
482
- return ColumnResizeNotifier;
483
- }());
484
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
485
- ColumnResizeNotifier.decorators = [
486
- { type: core.Injectable }
487
- ];
488
- /**
489
- * @type {function(): !Array<(null|{
490
- * type: ?,
491
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
492
- * })>}
493
- * @nocollapse
494
- */
495
- ColumnResizeNotifier.ctorParameters = function () { return [
496
- { type: ColumnResizeNotifierSource }
497
- ]; };
498
-
499
- /** Coordinates events between the column resize directives. */
500
- var HeaderRowEventDispatcher = /** @class */ (function () {
501
- function HeaderRowEventDispatcher(_ngZone) {
502
- this._ngZone = _ngZone;
503
- /**
504
- * Emits the currently hovered header cell or null when no header cells are hovered.
505
- * Exposed publicly for events to feed in, but subscribers should use headerCellHoveredDistinct,
506
- * defined below.
507
- */
508
- this.headerCellHovered = new rxjs.Subject();
509
- /**
510
- * Emits the header cell for which a user-triggered resize is active or null
511
- * when no resize is in progress.
512
- */
513
- this.overlayHandleActiveForCell = new rxjs.Subject();
514
- /** Distinct and shared version of headerCellHovered. */
515
- this.headerCellHoveredDistinct = this.headerCellHovered.pipe(operators.distinctUntilChanged(), operators.share());
516
- /**
517
- * Emits the header that is currently hovered or hosting an active resize event (with active
518
- * taking precedence).
519
- */
520
- this.headerRowHoveredOrActiveDistinct = rxjs.combineLatest(this.headerCellHoveredDistinct.pipe(operators.map(function (cell) { return closest(cell, HEADER_ROW_SELECTOR); }), operators.startWith(null), operators.distinctUntilChanged()), this.overlayHandleActiveForCell.pipe(operators.map(function (cell) { return closest(cell, HEADER_ROW_SELECTOR); }), operators.startWith(null), operators.distinctUntilChanged())).pipe(operators.skip(1), // Ignore initial [null, null] emission.
521
- operators.map(function (_a) {
522
- var _b = __read(_a, 2), hovered = _b[0], active = _b[1];
523
- return active || hovered;
524
- }), operators.distinctUntilChanged(), operators.share());
525
- this._headerRowHoveredOrActiveDistinctReenterZone = this.headerRowHoveredOrActiveDistinct.pipe(this._enterZone(), operators.share());
526
- // Optimization: Share row events observable with subsequent callers.
527
- // At startup, calls will be sequential by row (and typically there's only one).
528
- this._lastSeenRow = null;
529
- this._lastSeenRowHover = null;
530
- }
531
- /**
532
- * Emits whether the specified row should show its overlay controls.
533
- * Emission occurs within the NgZone.
534
- */
535
- HeaderRowEventDispatcher.prototype.resizeOverlayVisibleForHeaderRow = function (row) {
536
- if (row !== this._lastSeenRow) {
537
- this._lastSeenRow = row;
538
- this._lastSeenRowHover = this._headerRowHoveredOrActiveDistinctReenterZone.pipe(operators.map(function (hoveredRow) { return hoveredRow === row; }), operators.distinctUntilChanged(), operators.share());
539
- }
540
- return this._lastSeenRowHover;
541
- };
542
- HeaderRowEventDispatcher.prototype._enterZone = function () {
543
- var _this = this;
544
- return function (source) { return new rxjs.Observable(function (observer) { return source.subscribe({
545
- next: function (value) { return _this._ngZone.run(function () { return observer.next(value); }); },
546
- error: function (err) { return observer.error(err); },
547
- complete: function () { return observer.complete(); },
548
- }); }); };
549
- };
550
- return HeaderRowEventDispatcher;
551
- }());
552
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
553
- HeaderRowEventDispatcher.decorators = [
554
- { type: core.Injectable }
555
- ];
556
- /**
557
- * @type {function(): !Array<(null|{
558
- * type: ?,
559
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
560
- * })>}
561
- * @nocollapse
562
- */
563
- HeaderRowEventDispatcher.ctorParameters = function () { return [
564
- { type: core.NgZone }
565
- ]; };
566
-
567
- /**
568
- * Provides an implementation for resizing a column.
569
- * The details of how resizing works for tables for flex mat-tables are quite different.
570
- */
571
- var ResizeStrategy = /** @class */ (function () {
572
- function ResizeStrategy() {
573
- this._pendingResizeDelta = null;
574
- }
575
- /** Adjusts the width of the table element by the specified delta. */
576
- ResizeStrategy.prototype.updateTableWidthAndStickyColumns = function (delta) {
577
- var _this = this;
578
- var _a;
579
- if (this._pendingResizeDelta === null) {
580
- var tableElement_1 = this.columnResize.elementRef.nativeElement;
581
- var tableWidth_1 = getElementWidth(tableElement_1);
582
- this.styleScheduler.schedule(function () {
583
- tableElement_1.style.width = coercion.coerceCssPixelValue(tableWidth_1 + _this._pendingResizeDelta);
584
- _this._pendingResizeDelta = null;
585
- });
586
- this.styleScheduler.scheduleEnd(function () {
587
- _this.table.updateStickyColumnStyles();
588
- });
589
- }
590
- this._pendingResizeDelta = ((_a = this._pendingResizeDelta) !== null && _a !== void 0 ? _a : 0) + delta;
591
- };
592
- return ResizeStrategy;
593
- }());
594
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
595
- ResizeStrategy.decorators = [
596
- { type: core.Injectable }
597
- ];
598
- /**
599
- * The optimially performing resize strategy for &lt;table&gt; elements with table-layout: fixed.
600
- * Tested against and outperformed:
601
- * CSS selector
602
- * CSS selector w/ CSS variable
603
- * Updating all cell nodes
604
- */
605
- var TableLayoutFixedResizeStrategy = /** @class */ (function (_super) {
606
- __extends(TableLayoutFixedResizeStrategy, _super);
607
- function TableLayoutFixedResizeStrategy(columnResize, styleScheduler, table) {
608
- var _this = _super.call(this) || this;
609
- _this.columnResize = columnResize;
610
- _this.styleScheduler = styleScheduler;
611
- _this.table = table;
612
- return _this;
613
- }
614
- TableLayoutFixedResizeStrategy.prototype.applyColumnSize = function (_, columnHeader, sizeInPx, previousSizeInPx) {
615
- var delta = sizeInPx - (previousSizeInPx !== null && previousSizeInPx !== void 0 ? previousSizeInPx : getElementWidth(columnHeader));
616
- if (delta === 0) {
617
- return;
618
- }
619
- this.styleScheduler.schedule(function () {
620
- columnHeader.style.width = coercion.coerceCssPixelValue(sizeInPx);
621
- });
622
- this.updateTableWidthAndStickyColumns(delta);
623
- };
624
- TableLayoutFixedResizeStrategy.prototype.applyMinColumnSize = function (_, columnHeader, sizeInPx) {
625
- var currentWidth = getElementWidth(columnHeader);
626
- var newWidth = Math.max(currentWidth, sizeInPx);
627
- this.applyColumnSize(_, columnHeader, newWidth, currentWidth);
628
- };
629
- TableLayoutFixedResizeStrategy.prototype.applyMaxColumnSize = function (_, columnHeader, sizeInPx) {
630
- var currentWidth = getElementWidth(columnHeader);
631
- var newWidth = Math.min(currentWidth, sizeInPx);
632
- this.applyColumnSize(_, columnHeader, newWidth, currentWidth);
633
- };
634
- return TableLayoutFixedResizeStrategy;
635
- }(ResizeStrategy));
636
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
637
- TableLayoutFixedResizeStrategy.decorators = [
638
- { type: core.Injectable }
639
- ];
640
- /**
641
- * @type {function(): !Array<(null|{
642
- * type: ?,
643
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
644
- * })>}
645
- * @nocollapse
646
- */
647
- TableLayoutFixedResizeStrategy.ctorParameters = function () { return [
648
- { type: ColumnResize },
649
- { type: table._CoalescedStyleScheduler, decorators: [{ type: core.Inject, args: [table._COALESCED_STYLE_SCHEDULER,] }] },
650
- { type: table.CdkTable }
651
- ]; };
652
- /**
653
- * The optimally performing resize strategy for flex mat-tables.
654
- * Tested against and outperformed:
655
- * CSS selector w/ CSS variable
656
- * Updating all mat-cell nodes
657
- */
658
- var CdkFlexTableResizeStrategy = /** @class */ (function (_super) {
659
- __extends(CdkFlexTableResizeStrategy, _super);
660
- function CdkFlexTableResizeStrategy(columnResize, styleScheduler, table, document) {
661
- var _this = _super.call(this) || this;
662
- _this.columnResize = columnResize;
663
- _this.styleScheduler = styleScheduler;
664
- _this.table = table;
665
- _this._columnIndexes = new Map();
666
- _this._columnProperties = new Map();
667
- _this._indexSequence = 0;
668
- _this.defaultMinSize = 0;
669
- _this.defaultMaxSize = Number.MAX_SAFE_INTEGER;
670
- _this._document = document;
671
- return _this;
672
- }
673
- CdkFlexTableResizeStrategy.prototype.applyColumnSize = function (cssFriendlyColumnName, columnHeader, sizeInPx, previousSizeInPx) {
674
- // Optimization: Check applied width first as we probably set it already before reading
675
- // offsetWidth which triggers layout.
676
- var delta = sizeInPx -
677
- (previousSizeInPx !== null && previousSizeInPx !== void 0 ? previousSizeInPx : (this._getAppliedWidth(cssFriendlyColumnName) || columnHeader.offsetWidth));
678
- if (delta === 0) {
679
- return;
680
- }
681
- var cssSize = coercion.coerceCssPixelValue(sizeInPx);
682
- this._applyProperty(cssFriendlyColumnName, 'flex', "0 0.01 " + cssSize);
683
- this.updateTableWidthAndStickyColumns(delta);
684
- };
685
- CdkFlexTableResizeStrategy.prototype.applyMinColumnSize = function (cssFriendlyColumnName, _, sizeInPx) {
686
- var cssSize = coercion.coerceCssPixelValue(sizeInPx);
687
- this._applyProperty(cssFriendlyColumnName, 'min-width', cssSize, sizeInPx !== this.defaultMinSize);
688
- this.updateTableWidthAndStickyColumns(0);
689
- };
690
- CdkFlexTableResizeStrategy.prototype.applyMaxColumnSize = function (cssFriendlyColumnName, _, sizeInPx) {
691
- var cssSize = coercion.coerceCssPixelValue(sizeInPx);
692
- this._applyProperty(cssFriendlyColumnName, 'max-width', cssSize, sizeInPx !== this.defaultMaxSize);
693
- this.updateTableWidthAndStickyColumns(0);
694
- };
695
- CdkFlexTableResizeStrategy.prototype.getColumnCssClass = function (cssFriendlyColumnName) {
696
- return "cdk-column-" + cssFriendlyColumnName;
697
- };
698
- CdkFlexTableResizeStrategy.prototype.ngOnDestroy = function () {
699
- // TODO: Use remove() once we're off IE11.
700
- if (this._styleElement && this._styleElement.parentNode) {
701
- this._styleElement.parentNode.removeChild(this._styleElement);
702
- this._styleElement = undefined;
703
- }
704
- };
705
- CdkFlexTableResizeStrategy.prototype._getPropertyValue = function (cssFriendlyColumnName, key) {
706
- var properties = this._getColumnPropertiesMap(cssFriendlyColumnName);
707
- return properties.get(key);
708
- };
709
- CdkFlexTableResizeStrategy.prototype._getAppliedWidth = function (cssFriendslyColumnName) {
710
- return coercePixelsFromFlexValue(this._getPropertyValue(cssFriendslyColumnName, 'flex'));
711
- };
712
- CdkFlexTableResizeStrategy.prototype._applyProperty = function (cssFriendlyColumnName, key, value, enable) {
713
- var _this = this;
714
- if (enable === void 0) { enable = true; }
715
- var properties = this._getColumnPropertiesMap(cssFriendlyColumnName);
716
- this.styleScheduler.schedule(function () {
717
- if (enable) {
718
- properties.set(key, value);
719
- }
720
- else {
721
- properties.delete(key);
722
- }
723
- _this._applySizeCss(cssFriendlyColumnName);
724
- });
725
- };
726
- CdkFlexTableResizeStrategy.prototype._getStyleSheet = function () {
727
- if (!this._styleElement) {
728
- this._styleElement = this._document.createElement('style');
729
- this._styleElement.appendChild(this._document.createTextNode(''));
730
- this._document.head.appendChild(this._styleElement);
731
- }
732
- return this._styleElement.sheet;
733
- };
734
- CdkFlexTableResizeStrategy.prototype._getColumnPropertiesMap = function (cssFriendlyColumnName) {
735
- var properties = this._columnProperties.get(cssFriendlyColumnName);
736
- if (properties === undefined) {
737
- properties = new Map();
738
- this._columnProperties.set(cssFriendlyColumnName, properties);
739
- }
740
- return properties;
741
- };
742
- CdkFlexTableResizeStrategy.prototype._applySizeCss = function (cssFriendlyColumnName) {
743
- var properties = this._getColumnPropertiesMap(cssFriendlyColumnName);
744
- var propertyKeys = Array.from(properties.keys());
745
- var index = this._columnIndexes.get(cssFriendlyColumnName);
746
- if (index === undefined) {
747
- if (!propertyKeys.length) {
748
- // Nothing to set or unset.
749
- return;
750
- }
751
- index = this._indexSequence++;
752
- this._columnIndexes.set(cssFriendlyColumnName, index);
753
- }
754
- else {
755
- this._getStyleSheet().deleteRule(index);
756
- }
757
- var columnClassName = this.getColumnCssClass(cssFriendlyColumnName);
758
- var tableClassName = this.columnResize.getUniqueCssClass();
759
- var selector = "." + tableClassName + " ." + columnClassName;
760
- var body = propertyKeys.map(function (key) { return key + ":" + properties.get(key); }).join(';');
761
- this._getStyleSheet().insertRule(selector + " {" + body + "}", index);
762
- };
763
- return CdkFlexTableResizeStrategy;
764
- }(ResizeStrategy));
765
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
766
- CdkFlexTableResizeStrategy.decorators = [
767
- { type: core.Injectable }
768
- ];
769
- /**
770
- * @type {function(): !Array<(null|{
771
- * type: ?,
772
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
773
- * })>}
774
- * @nocollapse
775
- */
776
- CdkFlexTableResizeStrategy.ctorParameters = function () { return [
777
- { type: ColumnResize },
778
- { type: table._CoalescedStyleScheduler, decorators: [{ type: core.Inject, args: [table._COALESCED_STYLE_SCHEDULER,] }] },
779
- { type: table.CdkTable },
780
- { type: undefined, decorators: [{ type: core.Inject, args: [common.DOCUMENT,] }] }
781
- ]; };
782
- /** Converts CSS pixel values to numbers, eg "123px" to 123. Returns NaN for non pixel values. */
783
- function coercePixelsFromCssValue(cssValue) {
784
- var _a;
785
- return Number((_a = cssValue.match(/(\d+)px/)) === null || _a === void 0 ? void 0 : _a[1]);
786
- }
787
- /** Gets the style.width pixels on the specified element if present, otherwise its offsetWidth. */
788
- function getElementWidth(element) {
789
- // Optimization: Check style.width first as we probably set it already before reading
790
- // offsetWidth which triggers layout.
791
- return coercePixelsFromCssValue(element.style.width) || element.offsetWidth;
792
- }
793
- /**
794
- * Converts CSS flex values as set in CdkFlexTableResizeStrategy to numbers,
795
- * eg "0 0.01 123px" to 123.
796
- */
797
- function coercePixelsFromFlexValue(flexValue) {
798
- var _a;
799
- return Number((_a = flexValue === null || flexValue === void 0 ? void 0 : flexValue.match(/0 0\.01 (\d+)px/)) === null || _a === void 0 ? void 0 : _a[1]);
800
- }
801
- var TABLE_LAYOUT_FIXED_RESIZE_STRATEGY_PROVIDER = {
802
- provide: ResizeStrategy,
803
- useClass: TableLayoutFixedResizeStrategy,
804
- };
805
- var FLEX_RESIZE_STRATEGY_PROVIDER = {
806
- provide: ResizeStrategy,
807
- useClass: CdkFlexTableResizeStrategy,
808
- };
809
-
810
- var PROVIDERS = [
811
- ColumnResizeNotifier,
812
- HeaderRowEventDispatcher,
813
- ColumnResizeNotifierSource,
814
- ];
815
- var TABLE_PROVIDERS = __spreadArray(__spreadArray([], __read(PROVIDERS)), [
816
- TABLE_LAYOUT_FIXED_RESIZE_STRATEGY_PROVIDER,
817
- ]);
818
- var FLEX_PROVIDERS = __spreadArray(__spreadArray([], __read(PROVIDERS)), [FLEX_RESIZE_STRATEGY_PROVIDER]);
819
-
820
- /**
821
- * Explicitly enables column resizing for a table-based cdk-table.
822
- * Individual columns must be annotated specifically.
823
- */
824
- var CdkColumnResize = /** @class */ (function (_super) {
825
- __extends(CdkColumnResize, _super);
826
- function CdkColumnResize(columnResizeNotifier, elementRef, eventDispatcher, ngZone, notifier, table) {
827
- var _this = _super.call(this) || this;
828
- _this.columnResizeNotifier = columnResizeNotifier;
829
- _this.elementRef = elementRef;
830
- _this.eventDispatcher = eventDispatcher;
831
- _this.ngZone = ngZone;
832
- _this.notifier = notifier;
833
- _this.table = table;
834
- return _this;
835
- }
836
- return CdkColumnResize;
837
- }(ColumnResize));
838
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
839
- CdkColumnResize.decorators = [
840
- { type: core.Directive, args: [{
841
- selector: 'table[cdk-table][columnResize]',
842
- providers: __spreadArray(__spreadArray([], __read(TABLE_PROVIDERS)), [
843
- { provide: ColumnResize, useExisting: CdkColumnResize },
844
- ]),
845
- },] }
846
- ];
847
- /**
848
- * @type {function(): !Array<(null|{
849
- * type: ?,
850
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
851
- * })>}
852
- * @nocollapse
853
- */
854
- CdkColumnResize.ctorParameters = function () { return [
855
- { type: ColumnResizeNotifier },
856
- { type: core.ElementRef },
857
- { type: HeaderRowEventDispatcher },
858
- { type: core.NgZone },
859
- { type: ColumnResizeNotifierSource },
860
- { type: table.CdkTable }
861
- ]; };
862
-
863
- /**
864
- * Explicitly enables column resizing for a flexbox-based cdk-table.
865
- * Individual columns must be annotated specifically.
866
- */
867
- var CdkColumnResizeFlex = /** @class */ (function (_super) {
868
- __extends(CdkColumnResizeFlex, _super);
869
- function CdkColumnResizeFlex(columnResizeNotifier, elementRef, eventDispatcher, ngZone, notifier, table) {
870
- var _this = _super.call(this) || this;
871
- _this.columnResizeNotifier = columnResizeNotifier;
872
- _this.elementRef = elementRef;
873
- _this.eventDispatcher = eventDispatcher;
874
- _this.ngZone = ngZone;
875
- _this.notifier = notifier;
876
- _this.table = table;
877
- return _this;
878
- }
879
- return CdkColumnResizeFlex;
880
- }(ColumnResize));
881
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
882
- CdkColumnResizeFlex.decorators = [
883
- { type: core.Directive, args: [{
884
- selector: 'cdk-table[columnResize]',
885
- providers: __spreadArray(__spreadArray([], __read(FLEX_PROVIDERS)), [
886
- { provide: ColumnResize, useExisting: CdkColumnResizeFlex },
887
- ]),
888
- },] }
889
- ];
890
- /**
891
- * @type {function(): !Array<(null|{
892
- * type: ?,
893
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
894
- * })>}
895
- * @nocollapse
896
- */
897
- CdkColumnResizeFlex.ctorParameters = function () { return [
898
- { type: ColumnResizeNotifier },
899
- { type: core.ElementRef },
900
- { type: HeaderRowEventDispatcher },
901
- { type: core.NgZone },
902
- { type: ColumnResizeNotifierSource },
903
- { type: table.CdkTable }
904
- ]; };
905
-
906
- /**
907
- * @license
908
- * Copyright Google LLC All Rights Reserved.
909
- *
910
- * Use of this source code is governed by an MIT-style license that can be
911
- * found in the LICENSE file at https://angular.io/license
912
- */
913
- /**
914
- * One of two NgModules for use with CdkColumnResize.
915
- * When using this module, columns are not resizable by default.
916
- */
917
- var CdkColumnResizeModule = /** @class */ (function () {
918
- function CdkColumnResizeModule() {
919
- }
920
- return CdkColumnResizeModule;
921
- }());
922
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
923
- CdkColumnResizeModule.decorators = [
924
- { type: core.NgModule, args: [{
925
- declarations: [CdkColumnResize, CdkColumnResizeFlex],
926
- exports: [CdkColumnResize, CdkColumnResizeFlex],
927
- },] }
928
- ];
929
-
930
- /**
931
- * @license
932
- * Copyright Google LLC All Rights Reserved.
933
- *
934
- * Use of this source code is governed by an MIT-style license that can be
935
- * found in the LICENSE file at https://angular.io/license
936
- */
937
- /**
938
- * Can be provided by the host application to enable persistence of column resize state.
939
- */
940
- var ColumnSizeStore = /** @class */ (function () {
941
- function ColumnSizeStore() {
942
- }
943
- return ColumnSizeStore;
944
- }());
945
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
946
- ColumnSizeStore.decorators = [
947
- { type: core.Injectable }
948
- ];
949
-
950
- /**
951
- * @license
952
- * Copyright Google LLC All Rights Reserved.
953
- *
954
- * Use of this source code is governed by an MIT-style license that can be
955
- * found in the LICENSE file at https://angular.io/license
956
- */
957
- /** Tracks state of resize events in progress. */
958
- var ResizeRef = /** @class */ (function () {
959
- function ResizeRef(origin, overlayRef, minWidthPx, maxWidthPx) {
960
- this.origin = origin;
961
- this.overlayRef = overlayRef;
962
- this.minWidthPx = minWidthPx;
963
- this.maxWidthPx = maxWidthPx;
964
- }
965
- return ResizeRef;
966
- }());
967
-
968
- var OVERLAY_ACTIVE_CLASS = 'cdk-resizable-overlay-thumb-active';
969
- /**
970
- * Base class for Resizable directives which are applied to column headers to make those columns
971
- * resizable.
972
- */
973
- var Resizable = /** @class */ (function () {
974
- function Resizable() {
975
- this.isResizable = true;
976
- this.minWidthPxInternal = 0;
977
- this.maxWidthPxInternal = Number.MAX_SAFE_INTEGER;
978
- this.destroyed = new rxjs.Subject();
979
- this._viewInitialized = false;
980
- }
981
- Object.defineProperty(Resizable.prototype, "minWidthPx", {
982
- /** The minimum width to allow the column to be sized to. */
983
- get: function () {
984
- return this.minWidthPxInternal;
985
- },
986
- set: function (value) {
987
- if (value) {
988
- this.minWidthPxInternal = value;
989
- }
990
- this.columnResize.setResized();
991
- if (this.elementRef.nativeElement && this._viewInitialized) {
992
- this._applyMinWidthPx();
993
- }
994
- },
995
- enumerable: false,
996
- configurable: true
997
- });
998
- Object.defineProperty(Resizable.prototype, "maxWidthPx", {
999
- /** The maximum width to allow the column to be sized to. */
1000
- get: function () {
1001
- return this.maxWidthPxInternal;
1002
- },
1003
- set: function (value) {
1004
- if (value) {
1005
- this.maxWidthPxInternal = value;
1006
- }
1007
- this.columnResize.setResized();
1008
- if (this.elementRef.nativeElement && this._viewInitialized) {
1009
- this._applyMaxWidthPx();
1010
- }
1011
- },
1012
- enumerable: false,
1013
- configurable: true
1014
- });
1015
- Resizable.prototype.ngAfterViewInit = function () {
1016
- var _this = this;
1017
- if (this.isResizable) {
1018
- this._listenForRowHoverEvents();
1019
- this._listenForResizeEvents();
1020
- this._appendInlineHandle();
1021
- this.styleScheduler.scheduleEnd(function () {
1022
- _this._viewInitialized = true;
1023
- _this._applyMinWidthPx();
1024
- _this._applyMaxWidthPx();
1025
- });
1026
- }
1027
- };
1028
- Resizable.prototype.ngOnDestroy = function () {
1029
- this.destroyed.next();
1030
- this.destroyed.complete();
1031
- if (this.inlineHandle) {
1032
- this.elementRef.nativeElement.removeChild(this.inlineHandle);
1033
- }
1034
- if (this.overlayRef) {
1035
- this.overlayRef.dispose();
1036
- }
1037
- };
1038
- Resizable.prototype._createOverlayForHandle = function () {
1039
- // Use of overlays allows us to properly capture click events spanning parts
1040
- // of two table cells and is also useful for displaying a resize thumb
1041
- // over both cells and extending it down the table as needed.
1042
- var isRtl = this.directionality.value === 'rtl';
1043
- var positionStrategy = this.overlay
1044
- .position()
1045
- .flexibleConnectedTo(this.elementRef.nativeElement)
1046
- .withFlexibleDimensions(false)
1047
- .withGrowAfterOpen(false)
1048
- .withPush(false)
1049
- .withDefaultOffsetX(isRtl ? 1 : 0)
1050
- .withPositions([
1051
- {
1052
- originX: isRtl ? 'start' : 'end',
1053
- originY: 'top',
1054
- overlayX: 'center',
1055
- overlayY: 'top',
1056
- },
1057
- ]);
1058
- return this.overlay.create({
1059
- // Always position the overlay based on left-indexed coordinates.
1060
- direction: 'ltr',
1061
- disposeOnNavigation: true,
1062
- positionStrategy: positionStrategy,
1063
- scrollStrategy: this.overlay.scrollStrategies.reposition(),
1064
- width: '16px',
1065
- });
1066
- };
1067
- Resizable.prototype._listenForRowHoverEvents = function () {
1068
- var _this = this;
1069
- var element = this.elementRef.nativeElement;
1070
- var takeUntilDestroyed = operators.takeUntil(this.destroyed);
1071
- this.eventDispatcher
1072
- .resizeOverlayVisibleForHeaderRow(closest(element, HEADER_ROW_SELECTOR))
1073
- .pipe(takeUntilDestroyed)
1074
- .subscribe(function (hoveringRow) {
1075
- if (hoveringRow) {
1076
- if (!_this.overlayRef) {
1077
- _this.overlayRef = _this._createOverlayForHandle();
1078
- }
1079
- _this._showHandleOverlay();
1080
- }
1081
- else if (_this.overlayRef) {
1082
- // todo - can't detach during an active resize - need to work that out
1083
- _this.overlayRef.detach();
1084
- }
1085
- });
1086
- };
1087
- Resizable.prototype._listenForResizeEvents = function () {
1088
- var _this = this;
1089
- var takeUntilDestroyed = operators.takeUntil(this.destroyed);
1090
- rxjs.merge(this.resizeNotifier.resizeCanceled, this.resizeNotifier.triggerResize)
1091
- .pipe(takeUntilDestroyed, operators.filter(function (columnSize) { return columnSize.columnId === _this.columnDef.name; }))
1092
- .subscribe(function (_a) {
1093
- var size = _a.size, previousSize = _a.previousSize, completeImmediately = _a.completeImmediately;
1094
- _this.elementRef.nativeElement.classList.add(OVERLAY_ACTIVE_CLASS);
1095
- _this._applySize(size, previousSize);
1096
- if (completeImmediately) {
1097
- _this._completeResizeOperation();
1098
- }
1099
- });
1100
- rxjs.merge(this.resizeNotifier.resizeCanceled, this.resizeNotifier.resizeCompleted)
1101
- .pipe(takeUntilDestroyed)
1102
- .subscribe(function (columnSize) {
1103
- _this._cleanUpAfterResize(columnSize);
1104
- });
1105
- };
1106
- Resizable.prototype._completeResizeOperation = function () {
1107
- var _this = this;
1108
- this.ngZone.run(function () {
1109
- _this.resizeNotifier.resizeCompleted.next({
1110
- columnId: _this.columnDef.name,
1111
- size: _this.elementRef.nativeElement.offsetWidth,
1112
- });
1113
- });
1114
- };
1115
- Resizable.prototype._cleanUpAfterResize = function (columnSize) {
1116
- this.elementRef.nativeElement.classList.remove(OVERLAY_ACTIVE_CLASS);
1117
- if (this.overlayRef && this.overlayRef.hasAttached()) {
1118
- this._updateOverlayHandleHeight();
1119
- this.overlayRef.updatePosition();
1120
- if (columnSize.columnId === this.columnDef.name) {
1121
- this.inlineHandle.focus();
1122
- }
1123
- }
1124
- };
1125
- Resizable.prototype._createHandlePortal = function () {
1126
- var injector = core.Injector.create({
1127
- parent: this.injector,
1128
- providers: [
1129
- {
1130
- provide: ResizeRef,
1131
- useValue: new ResizeRef(this.elementRef, this.overlayRef, this.minWidthPx, this.maxWidthPx),
1132
- },
1133
- ],
1134
- });
1135
- return new portal.ComponentPortal(this.getOverlayHandleComponentType(), this.viewContainerRef, injector);
1136
- };
1137
- Resizable.prototype._showHandleOverlay = function () {
1138
- this._updateOverlayHandleHeight();
1139
- this.overlayRef.attach(this._createHandlePortal());
1140
- // Needed to ensure that all of the lifecycle hooks inside the overlay run immediately.
1141
- this.changeDetectorRef.markForCheck();
1142
- };
1143
- Resizable.prototype._updateOverlayHandleHeight = function () {
1144
- this.overlayRef.updateSize({ height: this.elementRef.nativeElement.offsetHeight });
1145
- };
1146
- Resizable.prototype._applySize = function (sizeInPixels, previousSize) {
1147
- var sizeToApply = Math.min(Math.max(sizeInPixels, this.minWidthPx, 0), this.maxWidthPx);
1148
- this.resizeStrategy.applyColumnSize(this.columnDef.cssClassFriendlyName, this.elementRef.nativeElement, sizeToApply, previousSize);
1149
- };
1150
- Resizable.prototype._applyMinWidthPx = function () {
1151
- this.resizeStrategy.applyMinColumnSize(this.columnDef.cssClassFriendlyName, this.elementRef.nativeElement, this.minWidthPx);
1152
- };
1153
- Resizable.prototype._applyMaxWidthPx = function () {
1154
- this.resizeStrategy.applyMaxColumnSize(this.columnDef.cssClassFriendlyName, this.elementRef.nativeElement, this.maxWidthPx);
1155
- };
1156
- Resizable.prototype._appendInlineHandle = function () {
1157
- var _this = this;
1158
- this.styleScheduler.schedule(function () {
1159
- _this.inlineHandle = _this.document.createElement('div');
1160
- _this.inlineHandle.tabIndex = 0;
1161
- _this.inlineHandle.className = _this.getInlineHandleCssClassName();
1162
- // TODO: Apply correct aria role (probably slider) after a11y spec questions resolved.
1163
- _this.elementRef.nativeElement.appendChild(_this.inlineHandle);
1164
- });
1165
- };
1166
- return Resizable;
1167
- }());
1168
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
1169
- Resizable.decorators = [
1170
- { type: core.Directive }
1171
- ];
1172
-
1173
- // TODO: Take another look at using cdk drag drop. IIRC I ran into a couple
1174
- // good reasons for not using it but I don't remember what they were at this point.
1175
- /**
1176
- * Base class for a component shown over the edge of a resizable column that is responsible
1177
- * for handling column resize mouse events and displaying any visible UI on the column edge.
1178
- */
1179
- var ResizeOverlayHandle = /** @class */ (function () {
1180
- function ResizeOverlayHandle() {
1181
- this.destroyed = new rxjs.Subject();
1182
- }
1183
- ResizeOverlayHandle.prototype.ngAfterViewInit = function () {
1184
- this._listenForMouseEvents();
1185
- };
1186
- ResizeOverlayHandle.prototype.ngOnDestroy = function () {
1187
- this.destroyed.next();
1188
- this.destroyed.complete();
1189
- };
1190
- ResizeOverlayHandle.prototype._listenForMouseEvents = function () {
1191
- var _this = this;
1192
- this.ngZone.runOutsideAngular(function () {
1193
- rxjs.fromEvent(_this.elementRef.nativeElement, 'mouseenter')
1194
- .pipe(operators.mapTo(_this.resizeRef.origin.nativeElement), operators.takeUntil(_this.destroyed))
1195
- .subscribe(function (cell) { return _this.eventDispatcher.headerCellHovered.next(cell); });
1196
- rxjs.fromEvent(_this.elementRef.nativeElement, 'mouseleave')
1197
- .pipe(operators.map(function (event) { return event.relatedTarget && closest(event.relatedTarget, HEADER_CELL_SELECTOR); }), operators.takeUntil(_this.destroyed))
1198
- .subscribe(function (cell) { return _this.eventDispatcher.headerCellHovered.next(cell); });
1199
- rxjs.fromEvent(_this.elementRef.nativeElement, 'mousedown')
1200
- .pipe(operators.takeUntil(_this.destroyed))
1201
- .subscribe(function (mousedownEvent) {
1202
- _this._dragStarted(mousedownEvent);
1203
- });
1204
- });
1205
- };
1206
- ResizeOverlayHandle.prototype._dragStarted = function (mousedownEvent) {
1207
- var _this = this;
1208
- // Only allow dragging using the left mouse button.
1209
- if (mousedownEvent.button !== 0) {
1210
- return;
1211
- }
1212
- var mouseup = rxjs.fromEvent(this.document, 'mouseup');
1213
- var mousemove = rxjs.fromEvent(this.document, 'mousemove');
1214
- var escape = rxjs.fromEvent(this.document, 'keyup').pipe(operators.filter(function (event) { return event.keyCode === keycodes.ESCAPE; }));
1215
- var startX = mousedownEvent.screenX;
1216
- var initialSize = this._getOriginWidth();
1217
- var overlayOffset = 0;
1218
- var originOffset = this._getOriginOffset();
1219
- var size = initialSize;
1220
- var overshot = 0;
1221
- this.updateResizeActive(true);
1222
- mouseup.pipe(operators.takeUntil(rxjs.merge(escape, this.destroyed))).subscribe(function (_a) {
1223
- var screenX = _a.screenX;
1224
- _this.styleScheduler.scheduleEnd(function () {
1225
- _this._notifyResizeEnded(size, screenX !== startX);
1226
- });
1227
- });
1228
- escape.pipe(operators.takeUntil(rxjs.merge(mouseup, this.destroyed))).subscribe(function () {
1229
- _this._notifyResizeEnded(initialSize);
1230
- });
1231
- mousemove
1232
- .pipe(operators.map(function (_a) {
1233
- var screenX = _a.screenX;
1234
- return screenX;
1235
- }), operators.startWith(startX), operators.distinctUntilChanged(), operators.pairwise(), operators.takeUntil(rxjs.merge(mouseup, escape, this.destroyed)))
1236
- .subscribe(function (_a) {
1237
- var _b = __read(_a, 2), prevX = _b[0], currX = _b[1];
1238
- var deltaX = currX - prevX;
1239
- // If the mouse moved further than the resize was able to match, limit the
1240
- // movement of the overlay to match the actual size and position of the origin.
1241
- if (overshot !== 0) {
1242
- if ((overshot < 0 && deltaX < 0) || (overshot > 0 && deltaX > 0)) {
1243
- overshot += deltaX;
1244
- return;
1245
- }
1246
- else {
1247
- var remainingOvershot = overshot + deltaX;
1248
- overshot =
1249
- overshot > 0 ? Math.max(remainingOvershot, 0) : Math.min(remainingOvershot, 0);
1250
- deltaX = remainingOvershot - overshot;
1251
- if (deltaX === 0) {
1252
- return;
1253
- }
1254
- }
1255
- }
1256
- var computedNewSize = size + (_this._isLtr() ? deltaX : -deltaX);
1257
- computedNewSize = Math.min(Math.max(computedNewSize, _this.resizeRef.minWidthPx, 0), _this.resizeRef.maxWidthPx);
1258
- _this.resizeNotifier.triggerResize.next({
1259
- columnId: _this.columnDef.name,
1260
- size: computedNewSize,
1261
- previousSize: size,
1262
- isStickyColumn: _this.columnDef.sticky || _this.columnDef.stickyEnd,
1263
- });
1264
- _this.styleScheduler.scheduleEnd(function () {
1265
- var originNewSize = _this._getOriginWidth();
1266
- var originNewOffset = _this._getOriginOffset();
1267
- var originOffsetDeltaX = originNewOffset - originOffset;
1268
- var originSizeDeltaX = originNewSize - size;
1269
- size = originNewSize;
1270
- originOffset = originNewOffset;
1271
- overshot += deltaX + (_this._isLtr() ? -originSizeDeltaX : originSizeDeltaX);
1272
- overlayOffset += originOffsetDeltaX + (_this._isLtr() ? originSizeDeltaX : 0);
1273
- _this._updateOverlayOffset(overlayOffset);
1274
- });
1275
- });
1276
- };
1277
- ResizeOverlayHandle.prototype.updateResizeActive = function (active) {
1278
- this.eventDispatcher.overlayHandleActiveForCell.next(active ? this.resizeRef.origin.nativeElement : null);
1279
- };
1280
- ResizeOverlayHandle.prototype._getOriginWidth = function () {
1281
- return this.resizeRef.origin.nativeElement.offsetWidth;
1282
- };
1283
- ResizeOverlayHandle.prototype._getOriginOffset = function () {
1284
- return this.resizeRef.origin.nativeElement.offsetLeft;
1285
- };
1286
- ResizeOverlayHandle.prototype._updateOverlayOffset = function (offset) {
1287
- this.resizeRef.overlayRef.overlayElement.style.transform = "translateX(" + coercion.coerceCssPixelValue(offset) + ")";
1288
- };
1289
- ResizeOverlayHandle.prototype._isLtr = function () {
1290
- return this.directionality.value === 'ltr';
1291
- };
1292
- ResizeOverlayHandle.prototype._notifyResizeEnded = function (size, completedSuccessfully) {
1293
- var _this = this;
1294
- if (completedSuccessfully === void 0) { completedSuccessfully = false; }
1295
- this.updateResizeActive(false);
1296
- this.ngZone.run(function () {
1297
- var sizeMessage = { columnId: _this.columnDef.name, size: size };
1298
- if (completedSuccessfully) {
1299
- _this.resizeNotifier.resizeCompleted.next(sizeMessage);
1300
- }
1301
- else {
1302
- _this.resizeNotifier.resizeCanceled.next(sizeMessage);
1303
- }
1304
- });
1305
- };
1306
- return ResizeOverlayHandle;
1307
- }());
1308
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
1309
- ResizeOverlayHandle.decorators = [
1310
- { type: core.Directive }
1311
- ];
1312
-
1313
- /**
1314
- * Generated bundle index. Do not edit.
1315
- */
1316
-
1317
- exports.CdkColumnResize = CdkColumnResize;
1318
- exports.CdkColumnResizeFlex = CdkColumnResizeFlex;
1319
- exports.CdkColumnResizeModule = CdkColumnResizeModule;
1320
- exports.CdkFlexTableResizeStrategy = CdkFlexTableResizeStrategy;
1321
- exports.ColumnResize = ColumnResize;
1322
- exports.ColumnResizeNotifier = ColumnResizeNotifier;
1323
- exports.ColumnResizeNotifierSource = ColumnResizeNotifierSource;
1324
- exports.ColumnSizeStore = ColumnSizeStore;
1325
- exports.FLEX_PROVIDERS = FLEX_PROVIDERS;
1326
- exports.FLEX_RESIZE_STRATEGY_PROVIDER = FLEX_RESIZE_STRATEGY_PROVIDER;
1327
- exports.HeaderRowEventDispatcher = HeaderRowEventDispatcher;
1328
- exports.Resizable = Resizable;
1329
- exports.ResizeOverlayHandle = ResizeOverlayHandle;
1330
- exports.ResizeRef = ResizeRef;
1331
- exports.ResizeStrategy = ResizeStrategy;
1332
- exports.TABLE_LAYOUT_FIXED_RESIZE_STRATEGY_PROVIDER = TABLE_LAYOUT_FIXED_RESIZE_STRATEGY_PROVIDER;
1333
- exports.TABLE_PROVIDERS = TABLE_PROVIDERS;
1334
- exports.TableLayoutFixedResizeStrategy = TableLayoutFixedResizeStrategy;
1335
-
1336
- Object.defineProperty(exports, '__esModule', { value: true });
1337
-
1338
- }));
1339
- //# sourceMappingURL=mtxColumnResize.umd.js.map