@ng-matero/extensions 12.7.0 → 13.0.0

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 +458 -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 +712 -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 +709 -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 +171 -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,1083 +0,0 @@
1
- (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/cdk/overlay'), require('@angular/cdk/a11y'), require('@angular/common'), require('@angular/core'), require('@angular/material/core'), require('@angular/cdk/scrolling'), require('@angular/cdk/bidi'), require('@angular/cdk/coercion'), require('@angular/cdk/keycodes'), require('@angular/cdk/layout'), require('@angular/cdk/platform'), require('@angular/cdk/portal'), require('rxjs'), require('rxjs/operators'), require('@angular/animations')) :
3
- typeof define === 'function' && define.amd ? define('@ng-matero/extensions/tooltip', ['exports', '@angular/cdk/overlay', '@angular/cdk/a11y', '@angular/common', '@angular/core', '@angular/material/core', '@angular/cdk/scrolling', '@angular/cdk/bidi', '@angular/cdk/coercion', '@angular/cdk/keycodes', '@angular/cdk/layout', '@angular/cdk/platform', '@angular/cdk/portal', 'rxjs', 'rxjs/operators', '@angular/animations'], 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.tooltip = {}), global.ng.cdk.overlay, global.ng.cdk.a11y, global.ng.common, global.ng.core, global.ng.material.core, global.ng.cdk.scrolling, global.ng.cdk.bidi, global.ng.cdk.coercion, global.ng.cdk.keycodes, global.ng.cdk.layout, global.ng.cdk.platform, global.ng.cdk.portal, global.rxjs, global.rxjs.operators, global.ng.animations));
5
- })(this, (function (exports, overlay, a11y, common, core, core$1, scrolling, bidi, coercion, keycodes, layout, platform, portal, rxjs, operators, animations) { '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
- * Animations used by MtxTooltip.
327
- * @docs-private
328
- */
329
- var mtxTooltipAnimations = {
330
- /** Animation that transitions a tooltip in and out. */
331
- tooltipState: animations.trigger('state', [
332
- animations.state('initial, void, hidden', animations.style({ opacity: 0, transform: 'scale(0)' })),
333
- animations.state('visible', animations.style({ transform: 'scale(1)' })),
334
- animations.transition('* => visible', animations.animate('200ms cubic-bezier(0, 0, 0.2, 1)', animations.keyframes([
335
- animations.style({ opacity: 0, transform: 'scale(0)', offset: 0 }),
336
- animations.style({ opacity: 0.5, transform: 'scale(0.99)', offset: 0.5 }),
337
- animations.style({ opacity: 1, transform: 'scale(1)', offset: 1 }),
338
- ]))),
339
- animations.transition('* => hidden', animations.animate('100ms cubic-bezier(0, 0, 0.2, 1)', animations.style({ opacity: 0 }))),
340
- ]),
341
- };
342
-
343
- /** Time in ms to throttle repositioning after scroll events. */
344
- var SCROLL_THROTTLE_MS = 20;
345
- /** CSS class that will be attached to the overlay panel. */
346
- var TOOLTIP_PANEL_CLASS = 'mtx-tooltip-panel';
347
- /** Options used to bind passive event listeners. */
348
- var passiveListenerOptions = platform.normalizePassiveListenerOptions({ passive: true });
349
- /**
350
- * Time between the user putting the pointer on a tooltip
351
- * trigger and the long press event being fired.
352
- */
353
- var LONGPRESS_DELAY = 500;
354
- /**
355
- * Creates an error to be thrown if the user supplied an invalid tooltip position.
356
- * @docs-private
357
- */
358
- function getMtxTooltipInvalidPositionError(position) {
359
- return Error("Tooltip position \"" + position + "\" is invalid.");
360
- }
361
- /** Injection token that determines the scroll handling while a tooltip is visible. */
362
- var MTX_TOOLTIP_SCROLL_STRATEGY = new core.InjectionToken('mtx-tooltip-scroll-strategy');
363
- /** @docs-private */
364
- function MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY(overlay) {
365
- return function () { return overlay.scrollStrategies.reposition({ scrollThrottle: SCROLL_THROTTLE_MS }); };
366
- }
367
- /** @docs-private */
368
- var MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY_PROVIDER = {
369
- provide: MTX_TOOLTIP_SCROLL_STRATEGY,
370
- deps: [overlay.Overlay],
371
- useFactory: MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY,
372
- };
373
- /** Injection token to be used to override the default options for `matTooltip`. */
374
- var MTX_TOOLTIP_DEFAULT_OPTIONS = new core.InjectionToken('mtx-tooltip-default-options', {
375
- providedIn: 'root',
376
- factory: MTX_TOOLTIP_DEFAULT_OPTIONS_FACTORY,
377
- });
378
- /** @docs-private */
379
- function MTX_TOOLTIP_DEFAULT_OPTIONS_FACTORY() {
380
- return {
381
- showDelay: 0,
382
- hideDelay: 0,
383
- touchendHideDelay: 1500,
384
- };
385
- }
386
- /**
387
- * Directive that attaches a material design tooltip to the host element. Animates the showing and
388
- * hiding of a tooltip provided position (defaults to below the element).
389
- *
390
- * https://material.io/design/components/tooltips.html
391
- */
392
- var MtxTooltip = /** @class */ (function () {
393
- function MtxTooltip(_overlay, _elementRef, _scrollDispatcher, _viewContainerRef, _ngZone, _platform, _ariaDescriber, _focusMonitor, scrollStrategy, _dir, _defaultOptions) {
394
- var _this = this;
395
- this._overlay = _overlay;
396
- this._elementRef = _elementRef;
397
- this._scrollDispatcher = _scrollDispatcher;
398
- this._viewContainerRef = _viewContainerRef;
399
- this._ngZone = _ngZone;
400
- this._platform = _platform;
401
- this._ariaDescriber = _ariaDescriber;
402
- this._focusMonitor = _focusMonitor;
403
- this._dir = _dir;
404
- this._defaultOptions = _defaultOptions;
405
- this._position = 'below';
406
- this._disabled = false;
407
- this._viewInitialized = false;
408
- this._pointerExitEventsInitialized = false;
409
- /** The default delay in ms before showing the tooltip after show is called */
410
- this.showDelay = this._defaultOptions.showDelay;
411
- /** The default delay in ms before hiding the tooltip after hide is called */
412
- this.hideDelay = this._defaultOptions.hideDelay;
413
- /**
414
- * How touch gestures should be handled by the tooltip. On touch devices the tooltip directive
415
- * uses a long press gesture to show and hide, however it can conflict with the native browser
416
- * gestures. To work around the conflict, Angular Material disables native gestures on the
417
- * trigger, but that might not be desirable on particular elements (e.g. inputs and draggable
418
- * elements). The different values for this option configure the touch event handling as follows:
419
- * - `auto` - Enables touch gestures for all elements, but tries to avoid conflicts with native
420
- * browser gestures on particular elements. In particular, it allows text selection on inputs
421
- * and textareas, and preserves the native browser dragging on elements marked as `draggable`.
422
- * - `on` - Enables touch gestures for all elements and disables native
423
- * browser gestures with no exceptions.
424
- * - `off` - Disables touch gestures. Note that this will prevent the tooltip from
425
- * showing on touch devices.
426
- */
427
- this.touchGestures = 'auto';
428
- this._message = '';
429
- /** Manually-bound passive event listeners. */
430
- this._passiveListeners = [];
431
- /** Emits when the component is destroyed. */
432
- this._destroyed = new rxjs.Subject();
433
- /**
434
- * Handles the keydown events on the host element.
435
- * Needs to be an arrow function so that we can use it in addEventListener.
436
- */
437
- this._handleKeydown = function (event) {
438
- if (_this._isTooltipVisible() && event.keyCode === keycodes.ESCAPE && !keycodes.hasModifierKey(event)) {
439
- event.preventDefault();
440
- event.stopPropagation();
441
- _this._ngZone.run(function () { return _this.hide(0); });
442
- }
443
- };
444
- this._scrollStrategy = scrollStrategy;
445
- if (_defaultOptions) {
446
- if (_defaultOptions.position) {
447
- this.position = _defaultOptions.position;
448
- }
449
- if (_defaultOptions.touchGestures) {
450
- this.touchGestures = _defaultOptions.touchGestures;
451
- }
452
- }
453
- _ngZone.runOutsideAngular(function () {
454
- _elementRef.nativeElement.addEventListener('keydown', _this._handleKeydown);
455
- });
456
- }
457
- Object.defineProperty(MtxTooltip.prototype, "position", {
458
- /** Allows the user to define the position of the tooltip relative to the parent element */
459
- get: function () {
460
- return this._position;
461
- },
462
- set: function (value) {
463
- if (value !== this._position) {
464
- this._position = value;
465
- if (this._overlayRef) {
466
- this._updatePosition();
467
- if (this._tooltipInstance) {
468
- this._tooltipInstance.show(0);
469
- }
470
- this._overlayRef.updatePosition();
471
- }
472
- }
473
- },
474
- enumerable: false,
475
- configurable: true
476
- });
477
- Object.defineProperty(MtxTooltip.prototype, "disabled", {
478
- /** Disables the display of the tooltip. */
479
- get: function () {
480
- return this._disabled;
481
- },
482
- set: function (value) {
483
- this._disabled = coercion.coerceBooleanProperty(value);
484
- // If tooltip is disabled, hide immediately.
485
- if (this._disabled) {
486
- this.hide(0);
487
- }
488
- else {
489
- this._setupPointerEnterEventsIfNeeded();
490
- }
491
- },
492
- enumerable: false,
493
- configurable: true
494
- });
495
- Object.defineProperty(MtxTooltip.prototype, "message", {
496
- /** The message to be displayed in the tooltip */
497
- get: function () {
498
- return this._message;
499
- },
500
- set: function (value) {
501
- var _this = this;
502
- this._ariaDescriber.removeDescription(this._elementRef.nativeElement, this._message);
503
- // TODO: If the message is a TemplateRef, it's hard to support a11y.
504
- // If the message is not a string (e.g. number), convert it to a string and trim it.
505
- this._message = value instanceof core.TemplateRef ? value : value != null ? ("" + value).trim() : '';
506
- if (!this._message && this._isTooltipVisible()) {
507
- this.hide(0);
508
- }
509
- else {
510
- this._setupPointerEnterEventsIfNeeded();
511
- this._updateTooltipMessage();
512
- this._ngZone.runOutsideAngular(function () {
513
- // The `AriaDescriber` has some functionality that avoids adding a description if it's the
514
- // same as the `aria-label` of an element, however we can't know whether the tooltip trigger
515
- // has a data-bound `aria-label` or when it'll be set for the first time. We can avoid the
516
- // issue by deferring the description by a tick so Angular has time to set the `aria-label`.
517
- Promise.resolve().then(function () {
518
- _this._ariaDescriber.describe(_this._elementRef.nativeElement, _this.message);
519
- });
520
- });
521
- }
522
- },
523
- enumerable: false,
524
- configurable: true
525
- });
526
- Object.defineProperty(MtxTooltip.prototype, "tooltipClass", {
527
- /** Classes to be passed to the tooltip. Supports the same syntax as `ngClass`. */
528
- get: function () {
529
- return this._tooltipClass;
530
- },
531
- set: function (value) {
532
- this._tooltipClass = value;
533
- if (this._tooltipInstance) {
534
- this._setTooltipClass(this._tooltipClass);
535
- }
536
- },
537
- enumerable: false,
538
- configurable: true
539
- });
540
- MtxTooltip.prototype.ngAfterViewInit = function () {
541
- var _this = this;
542
- // This needs to happen after view init so the initial values for all inputs have been set.
543
- this._viewInitialized = true;
544
- this._setupPointerEnterEventsIfNeeded();
545
- this._focusMonitor
546
- .monitor(this._elementRef)
547
- .pipe(operators.takeUntil(this._destroyed))
548
- .subscribe(function (origin) {
549
- // Note that the focus monitor runs outside the Angular zone.
550
- if (!origin) {
551
- _this._ngZone.run(function () { return _this.hide(0); });
552
- }
553
- else if (origin === 'keyboard') {
554
- _this._ngZone.run(function () { return _this.show(); });
555
- }
556
- });
557
- };
558
- /**
559
- * Dispose the tooltip when destroyed.
560
- */
561
- MtxTooltip.prototype.ngOnDestroy = function () {
562
- var nativeElement = this._elementRef.nativeElement;
563
- clearTimeout(this._touchstartTimeout);
564
- if (this._overlayRef) {
565
- this._overlayRef.dispose();
566
- this._tooltipInstance = null;
567
- }
568
- // Clean up the event listeners set in the constructor
569
- nativeElement.removeEventListener('keydown', this._handleKeydown);
570
- this._passiveListeners.forEach(function (_a) {
571
- var _b = __read(_a, 2), event = _b[0], listener = _b[1];
572
- nativeElement.removeEventListener(event, listener, passiveListenerOptions);
573
- });
574
- this._passiveListeners.length = 0;
575
- this._destroyed.next();
576
- this._destroyed.complete();
577
- this._ariaDescriber.removeDescription(nativeElement, this.message);
578
- this._focusMonitor.stopMonitoring(nativeElement);
579
- };
580
- /** Shows the tooltip after the delay in ms, defaults to tooltip-delay-show or 0ms if no input */
581
- MtxTooltip.prototype.show = function (delay) {
582
- var _this = this;
583
- if (delay === void 0) { delay = this.showDelay; }
584
- if (this.disabled ||
585
- !this.message ||
586
- (this._isTooltipVisible() &&
587
- !this._tooltipInstance._showTimeoutId &&
588
- !this._tooltipInstance._hideTimeoutId)) {
589
- return;
590
- }
591
- var overlayRef = this._createOverlay();
592
- this._detach();
593
- this._portal = this._portal || new portal.ComponentPortal(TooltipComponent, this._viewContainerRef);
594
- this._tooltipInstance = overlayRef.attach(this._portal).instance;
595
- this._tooltipInstance
596
- .afterHidden()
597
- .pipe(operators.takeUntil(this._destroyed))
598
- .subscribe(function () { return _this._detach(); });
599
- this._setTooltipClass(this._tooltipClass);
600
- this._updateTooltipMessage();
601
- this._tooltipInstance.show(delay);
602
- };
603
- /** Hides the tooltip after the delay in ms, defaults to tooltip-delay-hide or 0ms if no input */
604
- MtxTooltip.prototype.hide = function (delay) {
605
- if (delay === void 0) { delay = this.hideDelay; }
606
- if (this._tooltipInstance) {
607
- this._tooltipInstance.hide(delay);
608
- }
609
- };
610
- /** Shows/hides the tooltip */
611
- MtxTooltip.prototype.toggle = function () {
612
- this._isTooltipVisible() ? this.hide() : this.show();
613
- };
614
- /** Returns true if the tooltip is currently visible to the user */
615
- MtxTooltip.prototype._isTooltipVisible = function () {
616
- return !!this._tooltipInstance && this._tooltipInstance.isVisible();
617
- };
618
- /** Create the overlay config and position strategy */
619
- MtxTooltip.prototype._createOverlay = function () {
620
- var _this = this;
621
- if (this._overlayRef) {
622
- return this._overlayRef;
623
- }
624
- var scrollableAncestors = this._scrollDispatcher.getAncestorScrollContainers(this._elementRef);
625
- // Create connected position strategy that listens for scroll events to reposition.
626
- var strategy = this._overlay
627
- .position()
628
- .flexibleConnectedTo(this._elementRef)
629
- .withTransformOriginOn('.mtx-tooltip')
630
- .withFlexibleDimensions(false)
631
- .withViewportMargin(8)
632
- .withScrollableContainers(scrollableAncestors);
633
- strategy.positionChanges.pipe(operators.takeUntil(this._destroyed)).subscribe(function (change) {
634
- if (_this._tooltipInstance) {
635
- if (change.scrollableViewProperties.isOverlayClipped && _this._tooltipInstance.isVisible()) {
636
- // After position changes occur and the overlay is clipped by
637
- // a parent scrollable then close the tooltip.
638
- _this._ngZone.run(function () { return _this.hide(0); });
639
- }
640
- }
641
- });
642
- this._overlayRef = this._overlay.create({
643
- direction: this._dir,
644
- positionStrategy: strategy,
645
- panelClass: TOOLTIP_PANEL_CLASS,
646
- scrollStrategy: this._scrollStrategy(),
647
- });
648
- this._updatePosition();
649
- this._overlayRef
650
- .detachments()
651
- .pipe(operators.takeUntil(this._destroyed))
652
- .subscribe(function () { return _this._detach(); });
653
- return this._overlayRef;
654
- };
655
- /** Detaches the currently-attached tooltip. */
656
- MtxTooltip.prototype._detach = function () {
657
- if (this._overlayRef && this._overlayRef.hasAttached()) {
658
- this._overlayRef.detach();
659
- }
660
- this._tooltipInstance = null;
661
- };
662
- /** Updates the position of the current tooltip. */
663
- MtxTooltip.prototype._updatePosition = function () {
664
- var position = this._overlayRef.getConfig()
665
- .positionStrategy;
666
- var origin = this._getOrigin();
667
- var overlay = this._getOverlayPosition();
668
- position.withPositions([
669
- Object.assign(Object.assign({}, origin.main), overlay.main),
670
- Object.assign(Object.assign({}, origin.fallback), overlay.fallback),
671
- ]);
672
- };
673
- /**
674
- * Returns the origin position and a fallback position based on the user's position preference.
675
- * The fallback position is the inverse of the origin (e.g. `'below' -> 'above'`).
676
- */
677
- MtxTooltip.prototype._getOrigin = function () {
678
- var isLtr = !this._dir || this._dir.value === 'ltr';
679
- var position = this.position;
680
- var originPosition;
681
- if (position === 'above' || position === 'below') {
682
- originPosition = { originX: 'center', originY: position === 'above' ? 'top' : 'bottom' };
683
- }
684
- else if (position === 'before' ||
685
- (position === 'left' && isLtr) ||
686
- (position === 'right' && !isLtr)) {
687
- originPosition = { originX: 'start', originY: 'center' };
688
- }
689
- else if (position === 'after' ||
690
- (position === 'right' && isLtr) ||
691
- (position === 'left' && !isLtr)) {
692
- originPosition = { originX: 'end', originY: 'center' };
693
- }
694
- else {
695
- throw getMtxTooltipInvalidPositionError(position);
696
- }
697
- var _a = this._invertPosition(originPosition.originX, originPosition.originY), x = _a.x, y = _a.y;
698
- return {
699
- main: originPosition,
700
- fallback: { originX: x, originY: y },
701
- };
702
- };
703
- /** Returns the overlay position and a fallback position based on the user's preference */
704
- MtxTooltip.prototype._getOverlayPosition = function () {
705
- var isLtr = !this._dir || this._dir.value === 'ltr';
706
- var position = this.position;
707
- var overlayPosition;
708
- if (position === 'above') {
709
- overlayPosition = { overlayX: 'center', overlayY: 'bottom' };
710
- }
711
- else if (position === 'below') {
712
- overlayPosition = { overlayX: 'center', overlayY: 'top' };
713
- }
714
- else if (position === 'before' ||
715
- (position === 'left' && isLtr) ||
716
- (position === 'right' && !isLtr)) {
717
- overlayPosition = { overlayX: 'end', overlayY: 'center' };
718
- }
719
- else if (position === 'after' ||
720
- (position === 'right' && isLtr) ||
721
- (position === 'left' && !isLtr)) {
722
- overlayPosition = { overlayX: 'start', overlayY: 'center' };
723
- }
724
- else {
725
- throw getMtxTooltipInvalidPositionError(position);
726
- }
727
- var _a = this._invertPosition(overlayPosition.overlayX, overlayPosition.overlayY), x = _a.x, y = _a.y;
728
- return {
729
- main: overlayPosition,
730
- fallback: { overlayX: x, overlayY: y },
731
- };
732
- };
733
- /** Updates the tooltip message and repositions the overlay according to the new message length */
734
- MtxTooltip.prototype._updateTooltipMessage = function () {
735
- var _this = this;
736
- // Must wait for the message to be painted to the tooltip so that the overlay can properly
737
- // calculate the correct positioning based on the size of the text.
738
- if (this._tooltipInstance) {
739
- this._tooltipInstance.message = this.message;
740
- this._tooltipInstance._markForCheck();
741
- this._ngZone.onMicrotaskEmpty
742
- .asObservable()
743
- .pipe(operators.take(1), operators.takeUntil(this._destroyed))
744
- .subscribe(function () {
745
- if (_this._tooltipInstance) {
746
- _this._overlayRef.updatePosition();
747
- }
748
- });
749
- }
750
- };
751
- /** Updates the tooltip class */
752
- MtxTooltip.prototype._setTooltipClass = function (tooltipClass) {
753
- if (this._tooltipInstance) {
754
- this._tooltipInstance.tooltipClass = tooltipClass;
755
- this._tooltipInstance._markForCheck();
756
- }
757
- };
758
- /** Inverts an overlay position. */
759
- MtxTooltip.prototype._invertPosition = function (x, y) {
760
- if (this.position === 'above' || this.position === 'below') {
761
- if (y === 'top') {
762
- y = 'bottom';
763
- }
764
- else if (y === 'bottom') {
765
- y = 'top';
766
- }
767
- }
768
- else {
769
- if (x === 'end') {
770
- x = 'start';
771
- }
772
- else if (x === 'start') {
773
- x = 'end';
774
- }
775
- }
776
- return { x: x, y: y };
777
- };
778
- /** Binds the pointer events to the tooltip trigger. */
779
- MtxTooltip.prototype._setupPointerEnterEventsIfNeeded = function () {
780
- var _this = this;
781
- // Optimization: Defer hooking up events if there's no message or the tooltip is disabled.
782
- if (this._disabled ||
783
- !this.message ||
784
- !this._viewInitialized ||
785
- this._passiveListeners.length) {
786
- return;
787
- }
788
- // The mouse events shouldn't be bound on mobile devices, because they can prevent the
789
- // first tap from firing its click event or can cause the tooltip to open for clicks.
790
- if (this._platformSupportsMouseEvents()) {
791
- this._passiveListeners.push([
792
- 'mouseenter',
793
- function () {
794
- _this._setupPointerExitEventsIfNeeded();
795
- _this.show();
796
- },
797
- ]);
798
- }
799
- else if (this.touchGestures !== 'off') {
800
- this._disableNativeGesturesIfNecessary();
801
- this._passiveListeners.push([
802
- 'touchstart',
803
- function () {
804
- // Note that it's important that we don't `preventDefault` here,
805
- // because it can prevent click events from firing on the element.
806
- _this._setupPointerExitEventsIfNeeded();
807
- clearTimeout(_this._touchstartTimeout);
808
- _this._touchstartTimeout = setTimeout(function () { return _this.show(); }, LONGPRESS_DELAY);
809
- },
810
- ]);
811
- }
812
- this._addListeners(this._passiveListeners);
813
- };
814
- MtxTooltip.prototype._setupPointerExitEventsIfNeeded = function () {
815
- var _a;
816
- var _this = this;
817
- if (this._pointerExitEventsInitialized) {
818
- return;
819
- }
820
- this._pointerExitEventsInitialized = true;
821
- var exitListeners = [];
822
- if (this._platformSupportsMouseEvents()) {
823
- exitListeners.push(['mouseleave', function () { return _this.hide(); }]);
824
- }
825
- else if (this.touchGestures !== 'off') {
826
- this._disableNativeGesturesIfNecessary();
827
- var touchendListener = function () {
828
- clearTimeout(_this._touchstartTimeout);
829
- _this.hide(_this._defaultOptions.touchendHideDelay);
830
- };
831
- exitListeners.push(['touchend', touchendListener], ['touchcancel', touchendListener]);
832
- }
833
- this._addListeners(exitListeners);
834
- (_a = this._passiveListeners).push.apply(_a, __spreadArray([], __read(exitListeners)));
835
- };
836
- MtxTooltip.prototype._addListeners = function (listeners) {
837
- var _this = this;
838
- listeners.forEach(function (_a) {
839
- var _b = __read(_a, 2), event = _b[0], listener = _b[1];
840
- _this._elementRef.nativeElement.addEventListener(event, listener, passiveListenerOptions);
841
- });
842
- };
843
- MtxTooltip.prototype._platformSupportsMouseEvents = function () {
844
- return !this._platform.IOS && !this._platform.ANDROID;
845
- };
846
- /** Disables the native browser gestures, based on how the tooltip has been configured. */
847
- MtxTooltip.prototype._disableNativeGesturesIfNecessary = function () {
848
- var gestures = this.touchGestures;
849
- if (gestures !== 'off') {
850
- var element = this._elementRef.nativeElement;
851
- var style = element.style;
852
- // If gestures are set to `auto`, we don't disable text selection on inputs and
853
- // textareas, because it prevents the user from typing into them on iOS Safari.
854
- if (gestures === 'on' || (element.nodeName !== 'INPUT' && element.nodeName !== 'TEXTAREA')) {
855
- style.userSelect =
856
- style.msUserSelect =
857
- style.webkitUserSelect =
858
- style.MozUserSelect =
859
- 'none';
860
- }
861
- // If we have `auto` gestures and the element uses native HTML dragging,
862
- // we don't set `-webkit-user-drag` because it prevents the native behavior.
863
- if (gestures === 'on' || !element.draggable) {
864
- style.webkitUserDrag = 'none';
865
- }
866
- style.touchAction = 'none';
867
- // eslint-disable-next-line @typescript-eslint/ban-ts-comment
868
- // @ts-ignore
869
- style.webkitTapHighlightColor = 'transparent';
870
- }
871
- };
872
- return MtxTooltip;
873
- }());
874
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
875
- MtxTooltip.decorators = [
876
- { type: core.Directive, args: [{
877
- selector: '[mtxTooltip]',
878
- exportAs: 'mtxTooltip',
879
- host: {
880
- class: 'mtx-tooltip-trigger',
881
- },
882
- },] }
883
- ];
884
- /**
885
- * @type {function(): !Array<(null|{
886
- * type: ?,
887
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
888
- * })>}
889
- * @nocollapse
890
- */
891
- MtxTooltip.ctorParameters = function () { return [
892
- { type: overlay.Overlay },
893
- { type: core.ElementRef },
894
- { type: scrolling.ScrollDispatcher },
895
- { type: core.ViewContainerRef },
896
- { type: core.NgZone },
897
- { type: platform.Platform },
898
- { type: a11y.AriaDescriber },
899
- { type: a11y.FocusMonitor },
900
- { type: undefined, decorators: [{ type: core.Inject, args: [MTX_TOOLTIP_SCROLL_STRATEGY,] }] },
901
- { type: bidi.Directionality, decorators: [{ type: core.Optional }] },
902
- { type: undefined, decorators: [{ type: core.Optional }, { type: core.Inject, args: [MTX_TOOLTIP_DEFAULT_OPTIONS,] }] }
903
- ]; };
904
- /** @type {!Object<string, !Array<{type: !Function, args: (undefined|!Array<?>)}>>} */
905
- MtxTooltip.propDecorators = {
906
- position: [{ type: core.Input, args: ['mtxTooltipPosition',] }],
907
- disabled: [{ type: core.Input, args: ['mtxTooltipDisabled',] }],
908
- showDelay: [{ type: core.Input, args: ['mtxTooltipShowDelay',] }],
909
- hideDelay: [{ type: core.Input, args: ['mtxTooltipHideDelay',] }],
910
- touchGestures: [{ type: core.Input, args: ['mtxTooltipTouchGestures',] }],
911
- message: [{ type: core.Input, args: ['mtxTooltip',] }],
912
- tooltipClass: [{ type: core.Input, args: ['mtxTooltipClass',] }]
913
- };
914
- /**
915
- * Internal component that wraps the tooltip's content.
916
- * @docs-private
917
- */
918
- var TooltipComponent = /** @class */ (function () {
919
- function TooltipComponent(_changeDetectorRef, _breakpointObserver) {
920
- this._changeDetectorRef = _changeDetectorRef;
921
- this._breakpointObserver = _breakpointObserver;
922
- /** Property watched by the animation framework to show or hide the tooltip */
923
- this._visibility = 'initial';
924
- /** Whether interactions on the page should close the tooltip */
925
- this._closeOnInteraction = false;
926
- /** Subject for notifying that the tooltip has been hidden from the view */
927
- this._onHide = new rxjs.Subject();
928
- /** Stream that emits whether the user has a handset-sized display. */
929
- this._isHandset = this._breakpointObserver.observe(layout.Breakpoints.Handset);
930
- }
931
- TooltipComponent.prototype._isTemplateRef = function (obj) {
932
- return obj instanceof core.TemplateRef;
933
- };
934
- /**
935
- * Shows the tooltip with an animation originating from the provided origin
936
- * @param delay Amount of milliseconds to the delay showing the tooltip.
937
- */
938
- TooltipComponent.prototype.show = function (delay) {
939
- var _this = this;
940
- // Cancel the delayed hide if it is scheduled
941
- if (this._hideTimeoutId) {
942
- clearTimeout(this._hideTimeoutId);
943
- this._hideTimeoutId = null;
944
- }
945
- // Body interactions should cancel the tooltip if there is a delay in showing.
946
- this._closeOnInteraction = true;
947
- this._showTimeoutId = setTimeout(function () {
948
- _this._visibility = 'visible';
949
- _this._showTimeoutId = null;
950
- // Mark for check so if any parent component has set the
951
- // ChangeDetectionStrategy to OnPush it will be checked anyways
952
- _this._markForCheck();
953
- }, delay);
954
- };
955
- /**
956
- * Begins the animation to hide the tooltip after the provided delay in ms.
957
- * @param delay Amount of milliseconds to delay showing the tooltip.
958
- */
959
- TooltipComponent.prototype.hide = function (delay) {
960
- var _this = this;
961
- // Cancel the delayed show if it is scheduled
962
- if (this._showTimeoutId) {
963
- clearTimeout(this._showTimeoutId);
964
- this._showTimeoutId = null;
965
- }
966
- this._hideTimeoutId = setTimeout(function () {
967
- _this._visibility = 'hidden';
968
- _this._hideTimeoutId = null;
969
- // Mark for check so if any parent component has set the
970
- // ChangeDetectionStrategy to OnPush it will be checked anyways
971
- _this._markForCheck();
972
- }, delay);
973
- };
974
- /** Returns an observable that notifies when the tooltip has been hidden from view. */
975
- TooltipComponent.prototype.afterHidden = function () {
976
- return this._onHide.asObservable();
977
- };
978
- /** Whether the tooltip is being displayed. */
979
- TooltipComponent.prototype.isVisible = function () {
980
- return this._visibility === 'visible';
981
- };
982
- TooltipComponent.prototype.ngOnDestroy = function () {
983
- this._onHide.complete();
984
- };
985
- TooltipComponent.prototype._animationStart = function () {
986
- this._closeOnInteraction = false;
987
- };
988
- TooltipComponent.prototype._animationDone = function (event) {
989
- var toState = event.toState;
990
- if (toState === 'hidden' && !this.isVisible()) {
991
- this._onHide.next();
992
- }
993
- if (toState === 'visible' || toState === 'hidden') {
994
- this._closeOnInteraction = true;
995
- }
996
- };
997
- /**
998
- * Interactions on the HTML body should close the tooltip immediately as defined in the
999
- * material design spec.
1000
- * https://material.io/design/components/tooltips.html#behavior
1001
- */
1002
- TooltipComponent.prototype._handleBodyInteraction = function () {
1003
- if (this._closeOnInteraction) {
1004
- this.hide(0);
1005
- }
1006
- };
1007
- /**
1008
- * Marks that the tooltip needs to be checked in the next change detection run.
1009
- * Mainly used for rendering the initial text before positioning a tooltip, which
1010
- * can be problematic in components with OnPush change detection.
1011
- */
1012
- TooltipComponent.prototype._markForCheck = function () {
1013
- this._changeDetectorRef.markForCheck();
1014
- };
1015
- return TooltipComponent;
1016
- }());
1017
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
1018
- TooltipComponent.decorators = [
1019
- { type: core.Component, args: [{
1020
- selector: 'mtx-tooltip-component',
1021
- template: "<div class=\"mtx-tooltip\"\n [ngClass]=\"tooltipClass\"\n [class.mtx-tooltip-handset]=\"(_isHandset | async)?.matches\"\n [@state]=\"_visibility\"\n (@state.start)=\"_animationStart()\"\n (@state.done)=\"_animationDone($event)\">\n <ng-template [ngIf]=\"_isTemplateRef(message)\" [ngIfElse]=\"msgStrTpl\">\n <ng-template [ngTemplateOutlet]=\"$any(message)\"></ng-template>\n </ng-template>\n <ng-template #msgStrTpl>{{message}}</ng-template>\n</div>\n",
1022
- encapsulation: core.ViewEncapsulation.None,
1023
- changeDetection: core.ChangeDetectionStrategy.OnPush,
1024
- animations: [mtxTooltipAnimations.tooltipState],
1025
- host: {
1026
- // Forces the element to have a layout in IE and Edge. This fixes issues where the element
1027
- // won't be rendered if the animations are disabled or there is no web animations polyfill.
1028
- '[style.zoom]': '_visibility === "visible" ? 1 : null',
1029
- '(body:click)': 'this._handleBodyInteraction()',
1030
- 'aria-hidden': 'true',
1031
- },
1032
- styles: [".mtx-tooltip-panel{pointer-events:none!important}.mtx-tooltip{color:#fff;border-radius:4px;margin:14px;max-width:250px;padding-left:8px;padding-right:8px;overflow:hidden;text-overflow:ellipsis}.cdk-high-contrast-active .mtx-tooltip{outline:solid 1px}.mtx-tooltip-handset{margin:24px;padding-left:16px;padding-right:16px}\n"]
1033
- },] }
1034
- ];
1035
- /**
1036
- * @type {function(): !Array<(null|{
1037
- * type: ?,
1038
- * decorators: (undefined|!Array<{type: !Function, args: (undefined|!Array<?>)}>),
1039
- * })>}
1040
- * @nocollapse
1041
- */
1042
- TooltipComponent.ctorParameters = function () { return [
1043
- { type: core.ChangeDetectorRef },
1044
- { type: layout.BreakpointObserver }
1045
- ]; };
1046
-
1047
- var MtxTooltipModule = /** @class */ (function () {
1048
- function MtxTooltipModule() {
1049
- }
1050
- return MtxTooltipModule;
1051
- }());
1052
- /** @type {!Array<{type: !Function, args: (undefined|!Array<?>)}>} */
1053
- MtxTooltipModule.decorators = [
1054
- { type: core.NgModule, args: [{
1055
- imports: [a11y.A11yModule, common.CommonModule, overlay.OverlayModule, core$1.MatCommonModule],
1056
- exports: [MtxTooltip, TooltipComponent, core$1.MatCommonModule, scrolling.CdkScrollableModule],
1057
- declarations: [MtxTooltip, TooltipComponent],
1058
- entryComponents: [TooltipComponent],
1059
- providers: [MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY_PROVIDER],
1060
- },] }
1061
- ];
1062
-
1063
- /**
1064
- * Generated bundle index. Do not edit.
1065
- */
1066
-
1067
- exports.MTX_TOOLTIP_DEFAULT_OPTIONS = MTX_TOOLTIP_DEFAULT_OPTIONS;
1068
- exports.MTX_TOOLTIP_DEFAULT_OPTIONS_FACTORY = MTX_TOOLTIP_DEFAULT_OPTIONS_FACTORY;
1069
- exports.MTX_TOOLTIP_SCROLL_STRATEGY = MTX_TOOLTIP_SCROLL_STRATEGY;
1070
- exports.MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY = MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY;
1071
- exports.MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY_PROVIDER = MTX_TOOLTIP_SCROLL_STRATEGY_FACTORY_PROVIDER;
1072
- exports.MtxTooltip = MtxTooltip;
1073
- exports.MtxTooltipModule = MtxTooltipModule;
1074
- exports.SCROLL_THROTTLE_MS = SCROLL_THROTTLE_MS;
1075
- exports.TOOLTIP_PANEL_CLASS = TOOLTIP_PANEL_CLASS;
1076
- exports.TooltipComponent = TooltipComponent;
1077
- exports.getMtxTooltipInvalidPositionError = getMtxTooltipInvalidPositionError;
1078
- exports.mtxTooltipAnimations = mtxTooltipAnimations;
1079
-
1080
- Object.defineProperty(exports, '__esModule', { value: true });
1081
-
1082
- }));
1083
- //# sourceMappingURL=mtxTooltip.umd.js.map