@ng-matero/extensions 18.4.1 → 19.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 (285) hide show
  1. package/_index.scss +3 -1
  2. package/alert/_alert-theme.scss +19 -8
  3. package/alert/alert.d.ts +1 -2
  4. package/button/button-loading.d.ts +1 -2
  5. package/checkbox-group/checkbox-group.d.ts +12 -4
  6. package/colorpicker/_colorpicker-theme.scss +19 -8
  7. package/colorpicker/colorpicker-input.d.ts +1 -3
  8. package/colorpicker/colorpicker-toggle.d.ts +3 -3
  9. package/colorpicker/colorpicker.d.ts +4 -7
  10. package/column-resize/column-resize-directives/column-resize-flex.d.ts +2 -1
  11. package/column-resize/column-resize-directives/column-resize.d.ts +2 -1
  12. package/column-resize/column-resize-notifier.d.ts +0 -1
  13. package/column-resize/column-resize.d.ts +1 -1
  14. package/column-resize/event-dispatcher.d.ts +0 -9
  15. package/column-resize/overlay-handle.d.ts +1 -1
  16. package/column-resize/resizable.d.ts +1 -1
  17. package/column-resize/resize-strategy.d.ts +4 -4
  18. package/core/datetime/datetime-adapter.d.ts +1 -2
  19. package/core/datetime/native-datetime-adapter.d.ts +3 -3
  20. package/core/style/_button-common.scss +18 -0
  21. package/core/theming/_config-validation.scss +4 -4
  22. package/core/theming/_definition.scss +12 -2
  23. package/core/theming/prebuilt/azure-blue.scss +10 -22
  24. package/core/theming/prebuilt/cyan-orange.scss +10 -22
  25. package/core/theming/prebuilt/magenta-violet.scss +10 -22
  26. package/core/theming/prebuilt/rose-red.scss +10 -22
  27. package/core/tokens/_m3-system.scss +273 -0
  28. package/core/tokens/_m3-tokens.scss +8 -151
  29. package/core/tokens/_token-utils.scss +102 -43
  30. package/core/tokens/m2/_index.scss +2 -0
  31. package/core/tokens/m3/definitions/_index.scss +1 -0
  32. package/core/tokens/m3/definitions/_md-comp-plain-tooltip.scss +51 -0
  33. package/core/tokens/m3/index.scss +2 -0
  34. package/core/tokens/m3/mdc/_plain-tooltip.scss +15 -0
  35. package/core/tokens/m3/mtx/_alert.scss +14 -14
  36. package/core/tokens/m3/mtx/_colorpicker.scss +2 -2
  37. package/core/tokens/m3/mtx/_datetimepicker.scss +2 -2
  38. package/core/tokens/m3/mtx/_drawer.scss +2 -2
  39. package/core/tokens/m3/mtx/_grid.scss +2 -2
  40. package/core/tokens/m3/mtx/_loader.scss +2 -2
  41. package/core/tokens/m3/mtx/_popover.scss +2 -2
  42. package/core/tokens/m3/mtx/_progress.scss +2 -2
  43. package/core/tokens/m3/mtx/_select.scss +2 -2
  44. package/core/tokens/m3/mtx/_split.scss +2 -2
  45. package/datetimepicker/_datetimepicker-theme.scss +23 -10
  46. package/datetimepicker/calendar-body.d.ts +26 -4
  47. package/datetimepicker/calendar-body.scss +58 -9
  48. package/datetimepicker/calendar.d.ts +31 -31
  49. package/datetimepicker/clock.d.ts +11 -5
  50. package/datetimepicker/datetimepicker-actions.d.ts +9 -5
  51. package/datetimepicker/datetimepicker-content.scss +15 -0
  52. package/datetimepicker/datetimepicker-input.d.ts +4 -5
  53. package/datetimepicker/datetimepicker-module.d.ts +2 -2
  54. package/datetimepicker/datetimepicker-toggle.d.ts +4 -3
  55. package/datetimepicker/datetimepicker.d.ts +12 -8
  56. package/datetimepicker/month-view.d.ts +22 -7
  57. package/datetimepicker/multi-year-view.d.ts +20 -20
  58. package/datetimepicker/public-api.d.ts +2 -2
  59. package/datetimepicker/{time.d.ts → time-view.d.ts} +21 -9
  60. package/datetimepicker/{time.scss → time-view.scss} +1 -1
  61. package/datetimepicker/year-view.d.ts +21 -11
  62. package/dialog/dialog-container.d.ts +1 -2
  63. package/dialog/dialog.d.ts +0 -1
  64. package/drawer/_drawer-theme.scss +19 -8
  65. package/drawer/drawer-container.d.ts +2 -5
  66. package/drawer/drawer.d.ts +3 -5
  67. package/fesm2022/mtxAlert.mjs +15 -15
  68. package/fesm2022/mtxAlert.mjs.map +1 -1
  69. package/fesm2022/mtxButton.mjs +13 -14
  70. package/fesm2022/mtxButton.mjs.map +1 -1
  71. package/fesm2022/mtxCheckboxGroup.mjs +51 -31
  72. package/fesm2022/mtxCheckboxGroup.mjs.map +1 -1
  73. package/fesm2022/mtxColorpicker.mjs +91 -109
  74. package/fesm2022/mtxColorpicker.mjs.map +1 -1
  75. package/fesm2022/mtxColumnResize.mjs +79 -96
  76. package/fesm2022/mtxColumnResize.mjs.map +1 -1
  77. package/fesm2022/mtxCore.mjs +31 -36
  78. package/fesm2022/mtxCore.mjs.map +1 -1
  79. package/fesm2022/mtxDatetimepicker.mjs +1179 -1092
  80. package/fesm2022/mtxDatetimepicker.mjs.map +1 -1
  81. package/fesm2022/mtxDialog.mjs +30 -41
  82. package/fesm2022/mtxDialog.mjs.map +1 -1
  83. package/fesm2022/mtxDrawer.mjs +36 -52
  84. package/fesm2022/mtxDrawer.mjs.map +1 -1
  85. package/fesm2022/mtxGrid.mjs +168 -204
  86. package/fesm2022/mtxGrid.mjs.map +1 -1
  87. package/fesm2022/mtxLoader.mjs +12 -12
  88. package/fesm2022/mtxLoader.mjs.map +1 -1
  89. package/fesm2022/mtxPhotoviewer.mjs +11 -12
  90. package/fesm2022/mtxPhotoviewer.mjs.map +1 -1
  91. package/fesm2022/mtxPopover.mjs +106 -119
  92. package/fesm2022/mtxPopover.mjs.map +1 -1
  93. package/fesm2022/mtxProgress.mjs +8 -8
  94. package/fesm2022/mtxProgress.mjs.map +1 -1
  95. package/fesm2022/mtxSelect.mjs +157 -169
  96. package/fesm2022/mtxSelect.mjs.map +1 -1
  97. package/fesm2022/mtxSplit.mjs +39 -40
  98. package/fesm2022/mtxSplit.mjs.map +1 -1
  99. package/fesm2022/mtxTooltip.mjs +105 -91
  100. package/fesm2022/mtxTooltip.mjs.map +1 -1
  101. package/grid/_grid-theme.scss +23 -10
  102. package/grid/cell.d.ts +1 -4
  103. package/grid/column-resize/column-resize-directives/column-resize-flex.d.ts +0 -1
  104. package/grid/column-resize/column-resize-directives/column-resize.d.ts +0 -1
  105. package/grid/column-resize/overlay-handle.d.ts +1 -2
  106. package/grid/column-resize/resizable-directives/resizable.d.ts +2 -3
  107. package/grid/column-resize/resize-strategy.d.ts +2 -4
  108. package/grid/grid-pipes.d.ts +0 -2
  109. package/grid/grid.d.ts +5 -5
  110. package/loader/_loader-theme.scss +19 -8
  111. package/loader/loader.d.ts +0 -2
  112. package/package.json +11 -47
  113. package/photoviewer/photoviewer.d.ts +1 -2
  114. package/popover/_popover-theme.scss +19 -8
  115. package/popover/popover-content.d.ts +1 -1
  116. package/popover/popover-target.d.ts +1 -2
  117. package/popover/popover-trigger.d.ts +5 -6
  118. package/popover/popover.d.ts +1 -2
  119. package/prebuilt-themes/azure-blue.css +1 -1
  120. package/prebuilt-themes/cyan-orange.css +1 -1
  121. package/prebuilt-themes/deeppurple-amber.css +1 -1
  122. package/prebuilt-themes/indigo-pink.css +1 -1
  123. package/prebuilt-themes/magenta-violet.css +1 -1
  124. package/prebuilt-themes/pink-bluegrey.css +1 -1
  125. package/prebuilt-themes/purple-green.css +1 -1
  126. package/prebuilt-themes/rose-red.css +1 -1
  127. package/progress/_progress-theme.scss +23 -10
  128. package/select/_select-theme.scss +23 -10
  129. package/select/option.d.ts +0 -1
  130. package/select/select-intl.d.ts +2 -4
  131. package/select/select.d.ts +8 -7
  132. package/select/select.scss +3 -3
  133. package/select/templates.d.ts +0 -12
  134. package/split/_split-theme.scss +19 -8
  135. package/split/split-pane.d.ts +3 -4
  136. package/split/split.d.ts +4 -4
  137. package/split/split.scss +1 -1
  138. package/tooltip/_tooltip-theme.scss +11 -4
  139. package/tooltip/tooltip.d.ts +17 -9
  140. package/tooltip/tooltip.scss +8 -3
  141. package/esm2022/alert/alert-module.mjs +0 -17
  142. package/esm2022/alert/alert.mjs +0 -46
  143. package/esm2022/alert/mtxAlert.mjs +0 -5
  144. package/esm2022/alert/public-api.mjs +0 -3
  145. package/esm2022/button/button-loading.mjs +0 -66
  146. package/esm2022/button/button-module.mjs +0 -19
  147. package/esm2022/button/mtxButton.mjs +0 -5
  148. package/esm2022/button/public-api.mjs +0 -3
  149. package/esm2022/checkbox-group/checkbox-group-module.mjs +0 -20
  150. package/esm2022/checkbox-group/checkbox-group.mjs +0 -222
  151. package/esm2022/checkbox-group/interfaces.mjs +0 -2
  152. package/esm2022/checkbox-group/mtxCheckboxGroup.mjs +0 -5
  153. package/esm2022/checkbox-group/public-api.mjs +0 -4
  154. package/esm2022/colorpicker/colorpicker-animations.mjs +0 -16
  155. package/esm2022/colorpicker/colorpicker-input.mjs +0 -228
  156. package/esm2022/colorpicker/colorpicker-module.mjs +0 -64
  157. package/esm2022/colorpicker/colorpicker-toggle.mjs +0 -102
  158. package/esm2022/colorpicker/colorpicker.mjs +0 -363
  159. package/esm2022/colorpicker/mtxColorpicker.mjs +0 -5
  160. package/esm2022/colorpicker/public-api.mjs +0 -6
  161. package/esm2022/column-resize/column-resize-directives/column-resize-flex.mjs +0 -40
  162. package/esm2022/column-resize/column-resize-directives/column-resize.mjs +0 -40
  163. package/esm2022/column-resize/column-resize-directives/constants.mjs +0 -21
  164. package/esm2022/column-resize/column-resize-module.mjs +0 -28
  165. package/esm2022/column-resize/column-resize-notifier.mjs +0 -52
  166. package/esm2022/column-resize/column-resize.mjs +0 -82
  167. package/esm2022/column-resize/column-size-store.mjs +0 -20
  168. package/esm2022/column-resize/event-dispatcher.mjs +0 -70
  169. package/esm2022/column-resize/mtxColumnResize.mjs +0 -5
  170. package/esm2022/column-resize/overlay-handle.mjs +0 -146
  171. package/esm2022/column-resize/polyfill.mjs +0 -19
  172. package/esm2022/column-resize/public-api.mjs +0 -13
  173. package/esm2022/column-resize/resizable.mjs +0 -199
  174. package/esm2022/column-resize/resize-ref.mjs +0 -17
  175. package/esm2022/column-resize/resize-strategy.mjs +0 -238
  176. package/esm2022/column-resize/selectors.mjs +0 -13
  177. package/esm2022/core/datetime/datetime-adapter.mjs +0 -132
  178. package/esm2022/core/datetime/datetime-formats.mjs +0 -3
  179. package/esm2022/core/datetime/datetime.module.mjs +0 -38
  180. package/esm2022/core/datetime/index.mjs +0 -6
  181. package/esm2022/core/datetime/native-datetime-adapter.mjs +0 -138
  182. package/esm2022/core/datetime/native-datetime-formats.mjs +0 -20
  183. package/esm2022/core/mtxCore.mjs +0 -5
  184. package/esm2022/core/pipes/index.mjs +0 -4
  185. package/esm2022/core/pipes/is-template-ref.pipe.mjs +0 -14
  186. package/esm2022/core/pipes/pipes.module.mjs +0 -18
  187. package/esm2022/core/pipes/to-observable.pipe.mjs +0 -15
  188. package/esm2022/core/public-api.mjs +0 -3
  189. package/esm2022/datetimepicker/calendar-body.mjs +0 -77
  190. package/esm2022/datetimepicker/calendar.mjs +0 -661
  191. package/esm2022/datetimepicker/clock.mjs +0 -362
  192. package/esm2022/datetimepicker/datetimepicker-actions.mjs +0 -88
  193. package/esm2022/datetimepicker/datetimepicker-animations.mjs +0 -44
  194. package/esm2022/datetimepicker/datetimepicker-errors.mjs +0 -8
  195. package/esm2022/datetimepicker/datetimepicker-filtertype.mjs +0 -7
  196. package/esm2022/datetimepicker/datetimepicker-input.mjs +0 -349
  197. package/esm2022/datetimepicker/datetimepicker-intl.mjs +0 -63
  198. package/esm2022/datetimepicker/datetimepicker-module.mjs +0 -116
  199. package/esm2022/datetimepicker/datetimepicker-toggle.mjs +0 -105
  200. package/esm2022/datetimepicker/datetimepicker-types.mjs +0 -2
  201. package/esm2022/datetimepicker/datetimepicker.mjs +0 -580
  202. package/esm2022/datetimepicker/month-view.mjs +0 -148
  203. package/esm2022/datetimepicker/mtxDatetimepicker.mjs +0 -5
  204. package/esm2022/datetimepicker/multi-year-view.mjs +0 -215
  205. package/esm2022/datetimepicker/public-api.mjs +0 -17
  206. package/esm2022/datetimepicker/time.mjs +0 -470
  207. package/esm2022/datetimepicker/year-view.mjs +0 -139
  208. package/esm2022/dialog/dialog-config.mjs +0 -2
  209. package/esm2022/dialog/dialog-container.mjs +0 -43
  210. package/esm2022/dialog/dialog-module.mjs +0 -40
  211. package/esm2022/dialog/dialog.mjs +0 -75
  212. package/esm2022/dialog/mtxDialog.mjs +0 -5
  213. package/esm2022/dialog/public-api.mjs +0 -5
  214. package/esm2022/drawer/drawer-animations.mjs +0 -18
  215. package/esm2022/drawer/drawer-config.mjs +0 -35
  216. package/esm2022/drawer/drawer-container.mjs +0 -88
  217. package/esm2022/drawer/drawer-module.mjs +0 -21
  218. package/esm2022/drawer/drawer-ref.mjs +0 -99
  219. package/esm2022/drawer/drawer.mjs +0 -144
  220. package/esm2022/drawer/mtxDrawer.mjs +0 -5
  221. package/esm2022/drawer/public-api.mjs +0 -7
  222. package/esm2022/grid/cell.mjs +0 -132
  223. package/esm2022/grid/column-menu.mjs +0 -133
  224. package/esm2022/grid/column-resize/column-resize-directives/column-resize-flex.mjs +0 -38
  225. package/esm2022/grid/column-resize/column-resize-directives/column-resize.mjs +0 -38
  226. package/esm2022/grid/column-resize/column-resize-directives/common.mjs +0 -27
  227. package/esm2022/grid/column-resize/column-resize-module.mjs +0 -42
  228. package/esm2022/grid/column-resize/index.mjs +0 -8
  229. package/esm2022/grid/column-resize/overlay-handle.mjs +0 -66
  230. package/esm2022/grid/column-resize/resizable-directives/common.mjs +0 -29
  231. package/esm2022/grid/column-resize/resizable-directives/resizable.mjs +0 -64
  232. package/esm2022/grid/column-resize/resize-strategy.mjs +0 -47
  233. package/esm2022/grid/expansion-toggle.mjs +0 -65
  234. package/esm2022/grid/grid-module.mjs +0 -151
  235. package/esm2022/grid/grid-pipes.mjs +0 -129
  236. package/esm2022/grid/grid-utils.mjs +0 -56
  237. package/esm2022/grid/grid.mjs +0 -644
  238. package/esm2022/grid/interfaces.mjs +0 -2
  239. package/esm2022/grid/mtxGrid.mjs +0 -5
  240. package/esm2022/grid/public-api.mjs +0 -18
  241. package/esm2022/grid/selectable-cell.mjs +0 -53
  242. package/esm2022/loader/loader-module.mjs +0 -19
  243. package/esm2022/loader/loader.mjs +0 -57
  244. package/esm2022/loader/mtxLoader.mjs +0 -5
  245. package/esm2022/loader/public-api.mjs +0 -3
  246. package/esm2022/ng-matero-extensions.mjs +0 -5
  247. package/esm2022/photoviewer/mtxPhotoviewer.mjs +0 -5
  248. package/esm2022/photoviewer/photoviewer-module.mjs +0 -16
  249. package/esm2022/photoviewer/photoviewer.mjs +0 -64
  250. package/esm2022/photoviewer/public-api.mjs +0 -3
  251. package/esm2022/popover/mtxPopover.mjs +0 -5
  252. package/esm2022/popover/popover-animations.mjs +0 -25
  253. package/esm2022/popover/popover-content.mjs +0 -91
  254. package/esm2022/popover/popover-errors.mjs +0 -27
  255. package/esm2022/popover/popover-interfaces.mjs +0 -2
  256. package/esm2022/popover/popover-module.mjs +0 -39
  257. package/esm2022/popover/popover-target.mjs +0 -18
  258. package/esm2022/popover/popover-trigger.mjs +0 -480
  259. package/esm2022/popover/popover-types.mjs +0 -2
  260. package/esm2022/popover/popover.mjs +0 -325
  261. package/esm2022/popover/public-api.mjs +0 -9
  262. package/esm2022/progress/mtxProgress.mjs +0 -5
  263. package/esm2022/progress/progress-module.mjs +0 -17
  264. package/esm2022/progress/progress.mjs +0 -43
  265. package/esm2022/progress/public-api.mjs +0 -3
  266. package/esm2022/public-api.mjs +0 -5
  267. package/esm2022/select/mtxSelect.mjs +0 -5
  268. package/esm2022/select/option.mjs +0 -52
  269. package/esm2022/select/public-api.mjs +0 -6
  270. package/esm2022/select/select-intl.mjs +0 -32
  271. package/esm2022/select/select-module.mjs +0 -89
  272. package/esm2022/select/select.mjs +0 -611
  273. package/esm2022/select/templates.mjs +0 -135
  274. package/esm2022/split/interfaces.mjs +0 -2
  275. package/esm2022/split/mtxSplit.mjs +0 -5
  276. package/esm2022/split/public-api.mjs +0 -6
  277. package/esm2022/split/split-module.mjs +0 -18
  278. package/esm2022/split/split-pane.mjs +0 -161
  279. package/esm2022/split/split.mjs +0 -634
  280. package/esm2022/split/utils.mjs +0 -219
  281. package/esm2022/tooltip/mtxTooltip.mjs +0 -5
  282. package/esm2022/tooltip/public-api.mjs +0 -4
  283. package/esm2022/tooltip/tooltip-animations.mjs +0 -17
  284. package/esm2022/tooltip/tooltip-module.mjs +0 -41
  285. package/esm2022/tooltip/tooltip.mjs +0 -915
@@ -1,16 +1,15 @@
1
1
  import * as i0 from '@angular/core';
2
- import { Component, ViewEncapsulation, ChangeDetectionStrategy, Inject, Injectable, NgModule } from '@angular/core';
2
+ import { inject, Component, ViewEncapsulation, ChangeDetectionStrategy, Injectable, NgModule } from '@angular/core';
3
3
  import { AsyncPipe, CommonModule } from '@angular/common';
4
- import * as i1 from '@angular/material/dialog';
5
- import { MAT_DIALOG_DATA, MatDialogModule } from '@angular/material/dialog';
6
- import { MatButton, MatIconButton, MatFabButton, MatMiniFabButton, MatButtonModule } from '@angular/material/button';
4
+ import { MatDialogRef, MAT_DIALOG_DATA, MatDialog, MatDialogModule } from '@angular/material/dialog';
5
+ import { MatButton, MatIconButton, MatButtonModule } from '@angular/material/button';
7
6
  import { MatIcon, MatIconModule } from '@angular/material/icon';
8
7
  import { MtxToObservablePipe, MtxPipesModule } from '@ng-matero/extensions/core';
9
8
 
10
9
  class MtxDialogContainer {
11
- constructor(dialogRef, data) {
12
- this.dialogRef = dialogRef;
13
- this.data = data;
10
+ constructor() {
11
+ this.dialogRef = inject(MatDialogRef);
12
+ this.data = inject(MAT_DIALOG_DATA);
14
13
  }
15
14
  _onClick(fn) {
16
15
  if (fn) {
@@ -21,39 +20,28 @@ class MtxDialogContainer {
21
20
  _onClose() {
22
21
  this.dialogRef.close();
23
22
  }
24
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialogContainer, deps: [{ token: i1.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component }); }
25
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.0", type: MtxDialogContainer, isStandalone: true, selector: "mtx-dialog-container", host: { classAttribute: "mtx-dialog-container" }, exportAs: ["mtxDialogContainer"], ngImport: i0, template: "@if (data.title) {\n <h1 class=\"mtx-dialog-title\">\n <span>{{data.title | toObservable | async}}</span>\n @if (data.showCloseIcon) {\n <button mat-icon-button (click)=\"_onClose()\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </h1>\n}\n@if (data.description) {\n <div class=\"mtx-dialog-content\">\n <p>{{data.description | toObservable | async}}</p>\n </div>\n}\n<div class=\"mtx-dialog-actions\">\n @for (btn of data.buttons; track btn) {\n @switch (btn.type) {\n @case ('raised') {\n @if (btn.focusInitial) {\n <button mat-raised-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-raised-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('stroked') {\n @if (btn.focusInitial) {\n <button mat-stroked-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-stroked-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('flat') {\n @if (btn.focusInitial) {\n <button mat-flat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-flat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @default {\n @if (btn.focusInitial) {\n <button mat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n }\n }\n</div>\n", styles: [".mtx-dialog-title{display:flex;justify-content:space-between;align-items:center;padding:8px 24px;margin:0;line-height:48px;font-weight:500;font-size:20px}.mtx-dialog-title .mat-mdc-button-base{margin-right:-16px}[dir=rtl] .mtx-dialog-title .mat-mdc-button-base{margin-right:0;margin-left:-16px}.mtx-dialog-content{display:block;max-height:65vh;padding:0 24px;overflow:auto;-webkit-overflow-scrolling:touch}.mtx-dialog-content p{margin-top:0}.mtx-dialog-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;padding:8px}.mtx-dialog-actions .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mtx-dialog-actions .mat-mdc-button-base{margin-left:0;margin-right:8px}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "pipe", type: MtxToObservablePipe, name: "toObservable" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
23
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialogContainer, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
24
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.4", type: MtxDialogContainer, isStandalone: true, selector: "mtx-dialog-container", host: { classAttribute: "mtx-dialog-container" }, exportAs: ["mtxDialogContainer"], ngImport: i0, template: "@if (data.title) {\n <h1 class=\"mtx-dialog-title\">\n <span>{{data.title | toObservable | async}}</span>\n @if (data.showCloseIcon) {\n <button mat-icon-button (click)=\"_onClose()\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </h1>\n}\n@if (data.description) {\n <div class=\"mtx-dialog-content\">\n <p>{{data.description | toObservable | async}}</p>\n </div>\n}\n<div class=\"mtx-dialog-actions\">\n @for (btn of data.buttons; track btn) {\n @switch (btn.type) {\n @case ('raised') {\n @if (btn.focusInitial) {\n <button mat-raised-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-raised-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('stroked') {\n @if (btn.focusInitial) {\n <button mat-stroked-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-stroked-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('flat') {\n @if (btn.focusInitial) {\n <button mat-flat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-flat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @default {\n @if (btn.focusInitial) {\n <button mat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n }\n }\n</div>\n", styles: [".mtx-dialog-title{display:flex;justify-content:space-between;align-items:center;padding:8px 24px;margin:0;line-height:48px;font-weight:500;font-size:20px}.mtx-dialog-title .mat-mdc-button-base{margin-right:-16px}[dir=rtl] .mtx-dialog-title .mat-mdc-button-base{margin-right:0;margin-left:-16px}.mtx-dialog-content{display:block;max-height:65vh;padding:0 24px;overflow:auto;-webkit-overflow-scrolling:touch}.mtx-dialog-content p{margin-top:0}.mtx-dialog-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;padding:8px}.mtx-dialog-actions .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mtx-dialog-actions .mat-mdc-button-base{margin-left:0;margin-right:8px}\n"], dependencies: [{ kind: "pipe", type: AsyncPipe, name: "async" }, { kind: "component", type: MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "pipe", type: MtxToObservablePipe, name: "toObservable" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
26
25
  }
27
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialogContainer, decorators: [{
26
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialogContainer, decorators: [{
28
27
  type: Component,
29
28
  args: [{ selector: 'mtx-dialog-container', exportAs: 'mtxDialogContainer', host: {
30
29
  class: 'mtx-dialog-container',
31
- }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [
32
- AsyncPipe,
33
- MatButton,
34
- MatIconButton,
35
- MatFabButton,
36
- MatMiniFabButton,
37
- MatIcon,
38
- MtxToObservablePipe,
39
- ], template: "@if (data.title) {\n <h1 class=\"mtx-dialog-title\">\n <span>{{data.title | toObservable | async}}</span>\n @if (data.showCloseIcon) {\n <button mat-icon-button (click)=\"_onClose()\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </h1>\n}\n@if (data.description) {\n <div class=\"mtx-dialog-content\">\n <p>{{data.description | toObservable | async}}</p>\n </div>\n}\n<div class=\"mtx-dialog-actions\">\n @for (btn of data.buttons; track btn) {\n @switch (btn.type) {\n @case ('raised') {\n @if (btn.focusInitial) {\n <button mat-raised-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-raised-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('stroked') {\n @if (btn.focusInitial) {\n <button mat-stroked-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-stroked-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('flat') {\n @if (btn.focusInitial) {\n <button mat-flat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-flat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @default {\n @if (btn.focusInitial) {\n <button mat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n }\n }\n</div>\n", styles: [".mtx-dialog-title{display:flex;justify-content:space-between;align-items:center;padding:8px 24px;margin:0;line-height:48px;font-weight:500;font-size:20px}.mtx-dialog-title .mat-mdc-button-base{margin-right:-16px}[dir=rtl] .mtx-dialog-title .mat-mdc-button-base{margin-right:0;margin-left:-16px}.mtx-dialog-content{display:block;max-height:65vh;padding:0 24px;overflow:auto;-webkit-overflow-scrolling:touch}.mtx-dialog-content p{margin-top:0}.mtx-dialog-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;padding:8px}.mtx-dialog-actions .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mtx-dialog-actions .mat-mdc-button-base{margin-left:0;margin-right:8px}\n"] }]
40
- }], ctorParameters: () => [{ type: i1.MatDialogRef }, { type: undefined, decorators: [{
41
- type: Inject,
42
- args: [MAT_DIALOG_DATA]
43
- }] }] });
30
+ }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, imports: [AsyncPipe, MatButton, MatIconButton, MatIcon, MtxToObservablePipe], template: "@if (data.title) {\n <h1 class=\"mtx-dialog-title\">\n <span>{{data.title | toObservable | async}}</span>\n @if (data.showCloseIcon) {\n <button mat-icon-button (click)=\"_onClose()\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </h1>\n}\n@if (data.description) {\n <div class=\"mtx-dialog-content\">\n <p>{{data.description | toObservable | async}}</p>\n </div>\n}\n<div class=\"mtx-dialog-actions\">\n @for (btn of data.buttons; track btn) {\n @switch (btn.type) {\n @case ('raised') {\n @if (btn.focusInitial) {\n <button mat-raised-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-raised-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('stroked') {\n @if (btn.focusInitial) {\n <button mat-stroked-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-stroked-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('flat') {\n @if (btn.focusInitial) {\n <button mat-flat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-flat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @default {\n @if (btn.focusInitial) {\n <button mat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n }\n }\n</div>\n", styles: [".mtx-dialog-title{display:flex;justify-content:space-between;align-items:center;padding:8px 24px;margin:0;line-height:48px;font-weight:500;font-size:20px}.mtx-dialog-title .mat-mdc-button-base{margin-right:-16px}[dir=rtl] .mtx-dialog-title .mat-mdc-button-base{margin-right:0;margin-left:-16px}.mtx-dialog-content{display:block;max-height:65vh;padding:0 24px;overflow:auto;-webkit-overflow-scrolling:touch}.mtx-dialog-content p{margin-top:0}.mtx-dialog-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;padding:8px}.mtx-dialog-actions .mat-mdc-button-base{margin-left:8px}[dir=rtl] .mtx-dialog-actions .mat-mdc-button-base{margin-left:0;margin-right:8px}\n"] }]
31
+ }] });
44
32
 
45
33
  const defaults = {
46
34
  title: '',
47
35
  description: '',
48
36
  buttons: [
49
37
  {
50
- color: 'warn',
51
- text: 'OK',
52
- focusInitial: true,
38
+ text: 'Cancel',
53
39
  onClick: () => { },
54
40
  },
55
41
  {
56
- text: 'CLOSE',
42
+ color: 'warn',
43
+ text: 'OK',
44
+ focusInitial: true,
57
45
  onClick: () => { },
58
46
  },
59
47
  ],
@@ -62,8 +50,8 @@ const defaults = {
62
50
  width: '300px',
63
51
  };
64
52
  class MtxDialog {
65
- constructor(dialog) {
66
- this.dialog = dialog;
53
+ constructor() {
54
+ this.dialog = inject(MatDialog);
67
55
  }
68
56
  originalOpen(componentOrTemplateRef = MtxDialogContainer, config) {
69
57
  return this.dialog.open(componentOrTemplateRef, config);
@@ -93,42 +81,43 @@ class MtxDialog {
93
81
  title,
94
82
  description,
95
83
  buttons: [
84
+ {
85
+ text: 'Cancel',
86
+ onClick: () => onClose(),
87
+ },
96
88
  {
97
89
  color: 'warn',
98
90
  text: 'OK',
91
+ focusInitial: true,
99
92
  onClick: () => onOk(),
100
93
  },
101
- {
102
- text: 'CLOSE',
103
- onClick: () => onClose(),
104
- },
105
94
  ],
106
95
  });
107
96
  }
108
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialog, deps: [{ token: i1.MatDialog }], target: i0.ɵɵFactoryTarget.Injectable }); }
109
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialog, providedIn: 'root' }); }
97
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialog, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
98
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialog, providedIn: 'root' }); }
110
99
  }
111
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialog, decorators: [{
100
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialog, decorators: [{
112
101
  type: Injectable,
113
102
  args: [{ providedIn: 'root' }]
114
- }], ctorParameters: () => [{ type: i1.MatDialog }] });
103
+ }] });
115
104
 
116
105
  class MtxDialogModule {
117
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialogModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
118
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: MtxDialogModule, imports: [CommonModule,
106
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialogModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
107
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.0.4", ngImport: i0, type: MtxDialogModule, imports: [CommonModule,
119
108
  MatDialogModule,
120
109
  MatButtonModule,
121
110
  MatIconModule,
122
111
  MtxPipesModule,
123
112
  MtxDialogContainer], exports: [MtxDialogContainer] }); }
124
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialogModule, providers: [MtxDialog], imports: [CommonModule,
113
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialogModule, providers: [MtxDialog], imports: [CommonModule,
125
114
  MatDialogModule,
126
115
  MatButtonModule,
127
116
  MatIconModule,
128
117
  MtxPipesModule,
129
118
  MtxDialogContainer] }); }
130
119
  }
131
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDialogModule, decorators: [{
120
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDialogModule, decorators: [{
132
121
  type: NgModule,
133
122
  args: [{
134
123
  imports: [
@@ -1 +1 @@
1
- {"version":3,"file":"mtxDialog.mjs","sources":["../../../projects/extensions/dialog/dialog-container.ts","../../../projects/extensions/dialog/dialog-container.html","../../../projects/extensions/dialog/dialog.ts","../../../projects/extensions/dialog/dialog-module.ts","../../../projects/extensions/dialog/mtxDialog.ts"],"sourcesContent":["import { AsyncPipe } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, Inject, ViewEncapsulation } from '@angular/core';\nimport { MatButton, MatFabButton, MatIconButton, MatMiniFabButton } from '@angular/material/button';\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\nimport { MatIcon } from '@angular/material/icon';\n\nimport { MtxToObservablePipe } from '@ng-matero/extensions/core';\nimport { MtxDialogData } from './dialog-config';\n\n@Component({\n selector: 'mtx-dialog-container',\n exportAs: 'mtxDialogContainer',\n templateUrl: './dialog-container.html',\n styleUrl: './dialog-container.scss',\n host: {\n class: 'mtx-dialog-container',\n },\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: true,\n imports: [\n AsyncPipe,\n MatButton,\n MatIconButton,\n MatFabButton,\n MatMiniFabButton,\n MatIcon,\n MtxToObservablePipe,\n ],\n})\nexport class MtxDialogContainer {\n constructor(\n public dialogRef: MatDialogRef<MtxDialogContainer>,\n @Inject(MAT_DIALOG_DATA) public data: MtxDialogData\n ) {}\n\n _onClick(fn: () => void) {\n if (fn) {\n fn.call(this);\n }\n this._onClose();\n }\n\n _onClose() {\n this.dialogRef.close();\n }\n}\n","@if (data.title) {\n <h1 class=\"mtx-dialog-title\">\n <span>{{data.title | toObservable | async}}</span>\n @if (data.showCloseIcon) {\n <button mat-icon-button (click)=\"_onClose()\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </h1>\n}\n@if (data.description) {\n <div class=\"mtx-dialog-content\">\n <p>{{data.description | toObservable | async}}</p>\n </div>\n}\n<div class=\"mtx-dialog-actions\">\n @for (btn of data.buttons; track btn) {\n @switch (btn.type) {\n @case ('raised') {\n @if (btn.focusInitial) {\n <button mat-raised-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-raised-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('stroked') {\n @if (btn.focusInitial) {\n <button mat-stroked-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-stroked-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('flat') {\n @if (btn.focusInitial) {\n <button mat-flat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-flat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @default {\n @if (btn.focusInitial) {\n <button mat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n }\n }\n</div>\n","import { Injectable, TemplateRef } from '@angular/core';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { MatDialog } from '@angular/material/dialog';\nimport { Observable } from 'rxjs';\n\nimport { MtxDialogContainer } from './dialog-container';\nimport { MtxDialogData } from './dialog-config';\n\nconst defaults: MtxDialogData = {\n title: '',\n description: '',\n buttons: [\n {\n color: 'warn',\n text: 'OK',\n focusInitial: true,\n onClick: () => {},\n },\n {\n text: 'CLOSE',\n onClick: () => {},\n },\n ],\n showCloseIcon: false,\n disableClose: true,\n width: '300px',\n};\n\n@Injectable({ providedIn: 'root' })\nexport class MtxDialog {\n constructor(public dialog: MatDialog) {}\n\n originalOpen(\n componentOrTemplateRef: ComponentType<any> | TemplateRef<any> = MtxDialogContainer,\n config: any\n ) {\n return this.dialog.open(componentOrTemplateRef, config);\n }\n\n open(\n config: MtxDialogData,\n componentOrTemplateRef: ComponentType<any> | TemplateRef<any> = MtxDialogContainer\n ) {\n const data = Object.assign({}, defaults, config);\n return this.dialog.open(componentOrTemplateRef, {\n ...data,\n data,\n });\n }\n\n alert(\n title: string | Observable<string>,\n description: string | Observable<string> = '',\n onOk = () => {}\n ) {\n this.open({\n title,\n description,\n buttons: [\n {\n color: 'warn',\n text: 'OK',\n onClick: () => onOk(),\n },\n ],\n });\n }\n\n confirm(\n title: string | Observable<string>,\n description: string | Observable<string> = '',\n onOk = () => {},\n onClose = () => {}\n ) {\n this.open({\n title,\n description,\n buttons: [\n {\n color: 'warn',\n text: 'OK',\n onClick: () => onOk(),\n },\n {\n text: 'CLOSE',\n onClick: () => onClose(),\n },\n ],\n });\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { MtxPipesModule } from '@ng-matero/extensions/core';\nimport { MtxDialogContainer } from './dialog-container';\nimport { MtxDialog } from './dialog';\n\n@NgModule({\n imports: [\n CommonModule,\n MatDialogModule,\n MatButtonModule,\n MatIconModule,\n MtxPipesModule,\n MtxDialogContainer,\n ],\n exports: [MtxDialogContainer],\n providers: [MtxDialog],\n})\nexport class MtxDialogModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;MA8Ba,kBAAkB,CAAA;IAC7B,WACS,CAAA,SAA2C,EAClB,IAAmB,EAAA;QAD5C,IAAS,CAAA,SAAA,GAAT,SAAS,CAAkC;QAClB,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAe;KACjD;AAEJ,IAAA,QAAQ,CAAC,EAAc,EAAA;QACrB,IAAI,EAAE,EAAE;AACN,YAAA,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;SACf;QACD,IAAI,CAAC,QAAQ,EAAE,CAAC;KACjB;IAED,QAAQ,GAAA;AACN,QAAA,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE,CAAC;KACxB;AAfU,uBAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,8CAGnB,eAAe,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA,EAAA;qHAHd,kBAAkB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,sBAAA,EAAA,IAAA,EAAA,EAAA,cAAA,EAAA,sBAAA,EAAA,EAAA,QAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EC9B/B,qgFAyEA,EAAA,MAAA,EAAA,CAAA,grBAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,MAAA,EAAA,IAAA,EDpDI,SAAS,EAAA,IAAA,EAAA,OAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAC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ACd,YAAA,kBAAkB,aAEV,kBAAkB,CAAA,EAAA,CAAA,CAAA,EAAA;AAGjB,uBAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,EAFf,SAAA,EAAA,CAAC,SAAS,CAAC,YARpB,YAAY;YACZ,eAAe;YACf,eAAe;YACf,aAAa;YACb,cAAc;YACd,kBAAkB,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAKT,eAAe,EAAA,UAAA,EAAA,CAAA;kBAZ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,eAAe;wBACf,eAAe;wBACf,aAAa;wBACb,cAAc;wBACd,kBAAkB;AACnB,qBAAA;oBACD,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,SAAS,EAAE,CAAC,SAAS,CAAC;AACvB,iBAAA,CAAA;;;ACrBD;;AAEG;;;;"}
1
+ {"version":3,"file":"mtxDialog.mjs","sources":["../../../projects/extensions/dialog/dialog-container.ts","../../../projects/extensions/dialog/dialog-container.html","../../../projects/extensions/dialog/dialog.ts","../../../projects/extensions/dialog/dialog-module.ts","../../../projects/extensions/dialog/mtxDialog.ts"],"sourcesContent":["import { AsyncPipe } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, ViewEncapsulation, inject } from '@angular/core';\nimport { MatButton, MatIconButton } from '@angular/material/button';\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\nimport { MatIcon } from '@angular/material/icon';\n\nimport { MtxToObservablePipe } from '@ng-matero/extensions/core';\nimport { MtxDialogData } from './dialog-config';\n\n@Component({\n selector: 'mtx-dialog-container',\n exportAs: 'mtxDialogContainer',\n templateUrl: './dialog-container.html',\n styleUrl: './dialog-container.scss',\n host: {\n class: 'mtx-dialog-container',\n },\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [AsyncPipe, MatButton, MatIconButton, MatIcon, MtxToObservablePipe],\n})\nexport class MtxDialogContainer {\n dialogRef = inject<MatDialogRef<MtxDialogContainer>>(MatDialogRef);\n data = inject<MtxDialogData>(MAT_DIALOG_DATA);\n\n _onClick(fn: () => void) {\n if (fn) {\n fn.call(this);\n }\n this._onClose();\n }\n\n _onClose() {\n this.dialogRef.close();\n }\n}\n","@if (data.title) {\n <h1 class=\"mtx-dialog-title\">\n <span>{{data.title | toObservable | async}}</span>\n @if (data.showCloseIcon) {\n <button mat-icon-button (click)=\"_onClose()\">\n <mat-icon>close</mat-icon>\n </button>\n }\n </h1>\n}\n@if (data.description) {\n <div class=\"mtx-dialog-content\">\n <p>{{data.description | toObservable | async}}</p>\n </div>\n}\n<div class=\"mtx-dialog-actions\">\n @for (btn of data.buttons; track btn) {\n @switch (btn.type) {\n @case ('raised') {\n @if (btn.focusInitial) {\n <button mat-raised-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-raised-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('stroked') {\n @if (btn.focusInitial) {\n <button mat-stroked-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-stroked-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @case ('flat') {\n @if (btn.focusInitial) {\n <button mat-flat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-flat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n @default {\n @if (btn.focusInitial) {\n <button mat-button cdkFocusInitial\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n } @else {\n <button mat-button\n [color]=\"btn.color\" [class]=\"btn.class\" (click)=\"_onClick(btn.onClick!)\">\n {{btn.text | toObservable | async}}\n </button>\n }\n }\n }\n }\n</div>\n","import { Injectable, TemplateRef, inject } from '@angular/core';\nimport { ComponentType } from '@angular/cdk/portal';\nimport { MatDialog } from '@angular/material/dialog';\nimport { Observable } from 'rxjs';\n\nimport { MtxDialogContainer } from './dialog-container';\nimport { MtxDialogData } from './dialog-config';\n\nconst defaults: MtxDialogData = {\n title: '',\n description: '',\n buttons: [\n {\n text: 'Cancel',\n onClick: () => {},\n },\n {\n color: 'warn',\n text: 'OK',\n focusInitial: true,\n onClick: () => {},\n },\n ],\n showCloseIcon: false,\n disableClose: true,\n width: '300px',\n};\n\n@Injectable({ providedIn: 'root' })\nexport class MtxDialog {\n dialog = inject(MatDialog);\n\n originalOpen(\n componentOrTemplateRef: ComponentType<any> | TemplateRef<any> = MtxDialogContainer,\n config: any\n ) {\n return this.dialog.open(componentOrTemplateRef, config);\n }\n\n open(\n config: MtxDialogData,\n componentOrTemplateRef: ComponentType<any> | TemplateRef<any> = MtxDialogContainer\n ) {\n const data = Object.assign({}, defaults, config);\n return this.dialog.open(componentOrTemplateRef, {\n ...data,\n data,\n });\n }\n\n alert(\n title: string | Observable<string>,\n description: string | Observable<string> = '',\n onOk = () => {}\n ) {\n this.open({\n title,\n description,\n buttons: [\n {\n color: 'warn',\n text: 'OK',\n onClick: () => onOk(),\n },\n ],\n });\n }\n\n confirm(\n title: string | Observable<string>,\n description: string | Observable<string> = '',\n onOk = () => {},\n onClose = () => {}\n ) {\n this.open({\n title,\n description,\n buttons: [\n {\n text: 'Cancel',\n onClick: () => onClose(),\n },\n {\n color: 'warn',\n text: 'OK',\n focusInitial: true,\n onClick: () => onOk(),\n },\n ],\n });\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatDialogModule } from '@angular/material/dialog';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatIconModule } from '@angular/material/icon';\n\nimport { MtxPipesModule } from '@ng-matero/extensions/core';\nimport { MtxDialogContainer } from './dialog-container';\nimport { MtxDialog } from './dialog';\n\n@NgModule({\n imports: [\n CommonModule,\n MatDialogModule,\n MatButtonModule,\n MatIconModule,\n MtxPipesModule,\n MtxDialogContainer,\n ],\n exports: [MtxDialogContainer],\n providers: [MtxDialog],\n})\nexport class MtxDialogModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;MAqBa,kBAAkB,CAAA;AAZ/B,IAAA,WAAA,GAAA;AAaE,QAAA,IAAA,CAAA,SAAS,GAAG,MAAM,CAAmC,YAAY,CAAC;AAClE,QAAA,IAAA,CAAA,IAAI,GAAG,MAAM,CAAgB,eAAe,CAAC;AAY9C;AAVC,IAAA,QAAQ,CAAC,EAAc,EAAA;QACrB,IAAI,EAAE,EAAE;AACN,YAAA,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC;;QAEf,IAAI,CAAC,QAAQ,EAAE;;IAGjB,QAAQ,GAAA;AACN,QAAA,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE;;iIAZb,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;qHAAlB,kBAAkB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,sBAAA,EAAA,IAAA,EAAA,EAAA,cAAA,EAAA,sBAAA,EAAA,EAAA,QAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,QAAA,EAAA,EA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YACf,eAAe;YACf,aAAa;YACb,cAAc;AACd,YAAA,kBAAkB,aAEV,kBAAkB,CAAA,EAAA,CAAA,CAAA;AAGjB,uBAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,EAFf,SAAA,EAAA,CAAC,SAAS,CAAC,YARpB,YAAY;YACZ,eAAe;YACf,eAAe;YACf,aAAa;YACb,cAAc;YACd,kBAAkB,CAAA,EAAA,CAAA,CAAA;;2FAKT,eAAe,EAAA,UAAA,EAAA,CAAA;kBAZ3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,eAAe;wBACf,eAAe;wBACf,aAAa;wBACb,cAAc;wBACd,kBAAkB;AACnB,qBAAA;oBACD,OAAO,EAAE,CAAC,kBAAkB,CAAC;oBAC7B,SAAS,EAAE,CAAC,SAAS,CAAC;AACvB,iBAAA;;;ACrBD;;AAEG;;;;"}
@@ -1,15 +1,13 @@
1
1
  import { CdkDialogContainer, Dialog, DialogConfig, DialogModule } from '@angular/cdk/dialog';
2
2
  import { CdkPortalOutlet, PortalModule } from '@angular/cdk/portal';
3
3
  import * as i0 from '@angular/core';
4
- import { EventEmitter, Component, ChangeDetectionStrategy, ViewEncapsulation, Optional, Inject, ViewChild, InjectionToken, Injectable, SkipSelf, NgModule } from '@angular/core';
4
+ import { EventEmitter, Component, ChangeDetectionStrategy, ViewEncapsulation, ViewChild, InjectionToken, inject, Injectable, NgModule } from '@angular/core';
5
5
  import { MatCommonModule } from '@angular/material/core';
6
6
  import { coerceCssPixelValue } from '@angular/cdk/coercion';
7
+ import { Overlay } from '@angular/cdk/overlay';
7
8
  import { Subject, merge, defer } from 'rxjs';
8
9
  import { filter, take, startWith } from 'rxjs/operators';
9
- import { DOCUMENT } from '@angular/common';
10
10
  import { trigger, state, style, transition, animate } from '@angular/animations';
11
- import * as i1 from '@angular/cdk/a11y';
12
- import * as i3 from '@angular/cdk/overlay';
13
11
  import { ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';
14
12
 
15
13
  /**
@@ -69,11 +67,8 @@ const mtxDrawerAnimations = {
69
67
  * @docs-private
70
68
  */
71
69
  class MtxDrawerContainer extends CdkDialogContainer {
72
- get _drawerPosition() {
73
- return `mtx-drawer-${this._config.position}`;
74
- }
75
- constructor(elementRef, focusTrapFactory, document, config, checker, ngZone, overlayRef, focusMonitor) {
76
- super(elementRef, focusTrapFactory, document, config, checker, ngZone, overlayRef, focusMonitor);
70
+ constructor() {
71
+ super(...arguments);
77
72
  /** The state of the drawer animations. */
78
73
  this._animationState = 'void';
79
74
  /** Emits whenever the state of the animation changes. */
@@ -81,6 +76,9 @@ class MtxDrawerContainer extends CdkDialogContainer {
81
76
  /** Whether the component has been destroyed. */
82
77
  this._destroyed = false;
83
78
  }
79
+ get _drawerPosition() {
80
+ return `mtx-drawer-${this._config.position}`;
81
+ }
84
82
  _contentAttached() {
85
83
  // Delegate to the original dialog-container initialization (i.e. saving the
86
84
  // previous element, setting up the focus trap and moving focus to the container).
@@ -116,10 +114,10 @@ class MtxDrawerContainer extends CdkDialogContainer {
116
114
  this._animationStateChanged.emit(event);
117
115
  }
118
116
  _captureInitialFocus() { }
119
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawerContainer, deps: [{ token: i0.ElementRef }, { token: i1.FocusTrapFactory }, { token: DOCUMENT, optional: true }, { token: MtxDrawerConfig }, { token: i1.InteractivityChecker }, { token: i0.NgZone }, { token: i3.OverlayRef }, { token: i1.FocusMonitor }], target: i0.ɵɵFactoryTarget.Component }); }
120
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.0", type: MtxDrawerContainer, isStandalone: true, selector: "mtx-drawer-container", host: { attributes: { "tabindex": "-1" }, listeners: { "@state.start": "_onAnimationStart($event)", "@state.done": "_onAnimationDone($event)" }, properties: { "class": "_drawerPosition", "id": "_config.id", "attr.role": "_config.role", "attr.aria-modal": "_config.isModal", "attr.aria-label": "_config.ariaLabel", "@state": "_animationState" }, classAttribute: "mtx-drawer-container" }, viewQueries: [{ propertyName: "_portalOutlet", first: true, predicate: CdkPortalOutlet, descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ng-template cdkPortalOutlet></ng-template>\n", styles: [".mtx-drawer-container{display:block;width:100%;padding:8px 16px;overflow:auto;outline:0;box-sizing:border-box;background-color:var(--mtx-drawer-container-background-color, var(--mat-app-surface));color:var(--mtx-drawer-container-text-color, var(--mat-app-on-surface-variant));box-shadow:var(--mtx-drawer-container-elevation-shadow)}.cdk-high-contrast-active .mtx-drawer-container{outline:1px solid}.mtx-drawer-right{transform:translate(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}.mtx-drawer-left{transform:translate(-100%);border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}.mtx-drawer-bottom{transform:translateY(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}.mtx-drawer-top{transform:translateY(-100%);border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}\n"], dependencies: [{ kind: "directive", type: CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], animations: [mtxDrawerAnimations.drawerState], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
117
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawerContainer, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
118
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.4", type: MtxDrawerContainer, isStandalone: true, selector: "mtx-drawer-container", host: { attributes: { "tabindex": "-1" }, listeners: { "@state.start": "_onAnimationStart($event)", "@state.done": "_onAnimationDone($event)" }, properties: { "class": "_drawerPosition", "id": "_config.id", "attr.role": "_config.role", "attr.aria-modal": "_config.isModal", "attr.aria-label": "_config.ariaLabel", "@state": "_animationState" }, classAttribute: "mtx-drawer-container" }, viewQueries: [{ propertyName: "_portalOutlet", first: true, predicate: CdkPortalOutlet, descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ng-template cdkPortalOutlet></ng-template>\n", styles: [".mtx-drawer-container{display:block;width:100%;padding:8px 16px;overflow:auto;outline:0;box-sizing:border-box;background-color:var(--mtx-drawer-container-background-color, var(--mat-sys-surface));color:var(--mtx-drawer-container-text-color, var(--mat-sys-on-surface-variant));box-shadow:var(--mtx-drawer-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, .2), 0px 2px 2px 0px rgba(0, 0, 0, .14), 0px 1px 5px 0px rgba(0, 0, 0, .12))}@media (forced-colors: active){.mtx-drawer-container{outline:1px solid}}.mtx-drawer-right{transform:translate(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}.mtx-drawer-left{transform:translate(-100%);border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}.mtx-drawer-bottom{transform:translateY(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}.mtx-drawer-top{transform:translateY(-100%);border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}\n"], dependencies: [{ kind: "directive", type: CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], animations: [mtxDrawerAnimations.drawerState], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
121
119
  }
122
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawerContainer, decorators: [{
120
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawerContainer, decorators: [{
123
121
  type: Component,
124
122
  args: [{ selector: 'mtx-drawer-container', changeDetection: ChangeDetectionStrategy.Default, encapsulation: ViewEncapsulation.None, animations: [mtxDrawerAnimations.drawerState], host: {
125
123
  'class': 'mtx-drawer-container',
@@ -132,13 +130,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImpor
132
130
  '[@state]': '_animationState',
133
131
  '(@state.start)': '_onAnimationStart($event)',
134
132
  '(@state.done)': '_onAnimationDone($event)',
135
- }, standalone: true, imports: [CdkPortalOutlet], template: "<ng-template cdkPortalOutlet></ng-template>\n", styles: [".mtx-drawer-container{display:block;width:100%;padding:8px 16px;overflow:auto;outline:0;box-sizing:border-box;background-color:var(--mtx-drawer-container-background-color, var(--mat-app-surface));color:var(--mtx-drawer-container-text-color, var(--mat-app-on-surface-variant));box-shadow:var(--mtx-drawer-container-elevation-shadow)}.cdk-high-contrast-active .mtx-drawer-container{outline:1px solid}.mtx-drawer-right{transform:translate(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}.mtx-drawer-left{transform:translate(-100%);border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}.mtx-drawer-bottom{transform:translateY(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}.mtx-drawer-top{transform:translateY(-100%);border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-app-corner-large))}\n"] }]
136
- }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1.FocusTrapFactory }, { type: undefined, decorators: [{
137
- type: Optional
138
- }, {
139
- type: Inject,
140
- args: [DOCUMENT]
141
- }] }, { type: MtxDrawerConfig }, { type: i1.InteractivityChecker }, { type: i0.NgZone }, { type: i3.OverlayRef }, { type: i1.FocusMonitor }], propDecorators: { _portalOutlet: [{
133
+ }, imports: [CdkPortalOutlet], template: "<ng-template cdkPortalOutlet></ng-template>\n", styles: [".mtx-drawer-container{display:block;width:100%;padding:8px 16px;overflow:auto;outline:0;box-sizing:border-box;background-color:var(--mtx-drawer-container-background-color, var(--mat-sys-surface));color:var(--mtx-drawer-container-text-color, var(--mat-sys-on-surface-variant));box-shadow:var(--mtx-drawer-container-elevation-shadow, 0px 3px 1px -2px rgba(0, 0, 0, .2), 0px 2px 2px 0px rgba(0, 0, 0, .14), 0px 1px 5px 0px rgba(0, 0, 0, .12))}@media (forced-colors: active){.mtx-drawer-container{outline:1px solid}}.mtx-drawer-right{transform:translate(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}.mtx-drawer-left{transform:translate(-100%);border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}.mtx-drawer-bottom{transform:translateY(100%);border-top-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-top-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}.mtx-drawer-top{transform:translateY(-100%);border-bottom-left-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large));border-bottom-right-radius:var(--mtx-drawer-container-shape, var(--mat-sys-corner-large))}\n"] }]
134
+ }], propDecorators: { _portalOutlet: [{
142
135
  type: ViewChild,
143
136
  args: [CdkPortalOutlet, { static: true }]
144
137
  }] } });
@@ -249,6 +242,22 @@ let uniqueId = 0;
249
242
  * Service to trigger Material Design bottom sheets.
250
243
  */
251
244
  class MtxDrawer {
245
+ constructor() {
246
+ this._overlay = inject(Overlay);
247
+ this._parentDrawer = inject(MtxDrawer, { optional: true, skipSelf: true });
248
+ this._defaultOptions = inject(MTX_DRAWER_DEFAULT_OPTIONS, { optional: true });
249
+ this._openDrawersAtThisLevel = [];
250
+ this._afterAllDismissedAtThisLevel = new Subject();
251
+ this._afterOpenedAtThisLevel = new Subject();
252
+ this._dialog = inject(Dialog);
253
+ /**
254
+ * Stream that emits when all open drawer have finished closing.
255
+ * Will emit on subscribe if there are no open drawers to begin with.
256
+ */
257
+ this.afterAllDismissed = defer(() => this.openDrawers.length
258
+ ? this._getAfterAllDismissed()
259
+ : this._getAfterAllDismissed().pipe(startWith(undefined)));
260
+ }
252
261
  /** Keeps track of the currently-open dialogs. */
253
262
  get openDrawers() {
254
263
  return this._parentDrawer ? this._parentDrawer.openDrawers : this._openDrawersAtThisLevel;
@@ -261,22 +270,6 @@ class MtxDrawer {
261
270
  const parent = this._parentDrawer;
262
271
  return parent ? parent._getAfterAllDismissed() : this._afterAllDismissedAtThisLevel;
263
272
  }
264
- constructor(_overlay, injector, _parentDrawer, _defaultOptions) {
265
- this._overlay = _overlay;
266
- this._parentDrawer = _parentDrawer;
267
- this._defaultOptions = _defaultOptions;
268
- this._openDrawersAtThisLevel = [];
269
- this._afterAllDismissedAtThisLevel = new Subject();
270
- this._afterOpenedAtThisLevel = new Subject();
271
- /**
272
- * Stream that emits when all open drawer have finished closing.
273
- * Will emit on subscribe if there are no open drawers to begin with.
274
- */
275
- this.afterAllDismissed = defer(() => this.openDrawers.length
276
- ? this._getAfterAllDismissed()
277
- : this._getAfterAllDismissed().pipe(startWith(undefined)));
278
- this._dialog = injector.get(Dialog);
279
- }
280
273
  open(componentOrTemplateRef, config) {
281
274
  let drawerRef;
282
275
  const _config = { ...(this._defaultOptions || new MtxDrawerConfig()), ...config };
@@ -355,29 +348,20 @@ class MtxDrawer {
355
348
  drawers[i].dismiss();
356
349
  }
357
350
  }
358
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawer, deps: [{ token: i3.Overlay }, { token: i0.Injector }, { token: MtxDrawer, optional: true, skipSelf: true }, { token: MTX_DRAWER_DEFAULT_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
359
- /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawer, providedIn: 'root' }); }
351
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawer, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
352
+ /** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawer, providedIn: 'root' }); }
360
353
  }
361
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawer, decorators: [{
354
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawer, decorators: [{
362
355
  type: Injectable,
363
356
  args: [{ providedIn: 'root' }]
364
- }], ctorParameters: () => [{ type: i3.Overlay }, { type: i0.Injector }, { type: MtxDrawer, decorators: [{
365
- type: Optional
366
- }, {
367
- type: SkipSelf
368
- }] }, { type: MtxDrawerConfig, decorators: [{
369
- type: Optional
370
- }, {
371
- type: Inject,
372
- args: [MTX_DRAWER_DEFAULT_OPTIONS]
373
- }] }] });
357
+ }] });
374
358
 
375
359
  class MtxDrawerModule {
376
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
377
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawerModule, imports: [DialogModule, PortalModule, MatCommonModule, MtxDrawerContainer], exports: [MtxDrawerContainer, MatCommonModule] }); }
378
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawerModule, providers: [MtxDrawer], imports: [DialogModule, PortalModule, MatCommonModule, MatCommonModule] }); }
360
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
361
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawerModule, imports: [DialogModule, PortalModule, MatCommonModule, MtxDrawerContainer], exports: [MtxDrawerContainer, MatCommonModule] }); }
362
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawerModule, providers: [MtxDrawer], imports: [DialogModule, PortalModule, MatCommonModule, MatCommonModule] }); }
379
363
  }
380
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.0", ngImport: i0, type: MtxDrawerModule, decorators: [{
364
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: MtxDrawerModule, decorators: [{
381
365
  type: NgModule,
382
366
  args: [{
383
367
  imports: [DialogModule, PortalModule, MatCommonModule, MtxDrawerContainer],
@@ -1 +1 @@
1
- {"version":3,"file":"mtxDrawer.mjs","sources":["../../../projects/extensions/drawer/drawer-config.ts","../../../projects/extensions/drawer/drawer-animations.ts","../../../projects/extensions/drawer/drawer-container.ts","../../../projects/extensions/drawer/drawer-container.html","../../../projects/extensions/drawer/drawer-ref.ts","../../../projects/extensions/drawer/drawer.ts","../../../projects/extensions/drawer/drawer-module.ts","../../../projects/extensions/drawer/mtxDrawer.ts"],"sourcesContent":["import { Direction } from '@angular/cdk/bidi';\nimport { ScrollStrategy } from '@angular/cdk/overlay';\nimport { ViewContainerRef } from '@angular/core';\n\n/** Options for where to set focus to automatically on dialog open. */\nexport type AutoFocusTarget = 'dialog' | 'first-tabbable' | 'first-heading';\n\n/** Possible overrides for a drawer's position. */\nexport type DrawerPosition = 'top' | 'bottom' | 'left' | 'right';\n\n/**\n * Configuration used when opening a drawer.\n */\nexport class MtxDrawerConfig<D = any> {\n /** The view container to place the overlay for the drawer into. */\n viewContainerRef?: ViewContainerRef;\n\n /** ID for the drawer. If omitted, a unique one will be generated. */\n id?: string;\n\n /** Extra CSS classes to be added to the drawer container. */\n panelClass?: string | string[];\n\n /** Text layout direction for the drawer. */\n direction?: Direction;\n\n /** Data being injected into the child component. */\n data?: D | null = null;\n\n /** Whether the drawer has a backdrop. */\n hasBackdrop?: boolean = true;\n\n /** Custom class for the backdrop. */\n backdropClass?: string;\n\n /** Whether the user can use escape or clicking outside to close the drawer. */\n disableClose?: boolean = false;\n\n /** Aria label to assign to the drawer element. */\n ariaLabel?: string | null = null;\n\n /**\n * Whether the drawer should close when the user goes backwards/forwards in history.\n * Note that this usually doesn't include clicking on links (unless the user is using\n * the `HashLocationStrategy`).\n */\n closeOnNavigation?: boolean = true;\n\n /**\n * Where the drawer should focus on open.\n * @breaking-change 14.0.0 Remove boolean option from autoFocus. Use string or\n * AutoFocusTarget instead.\n */\n autoFocus?: AutoFocusTarget | string | boolean = 'first-tabbable';\n\n /**\n * Whether the drawer should restore focus to the\n * previously-focused element, after it's closed.\n */\n restoreFocus?: boolean = true;\n\n /** Scroll strategy to be used for the drawer. */\n scrollStrategy?: ScrollStrategy;\n\n /** Position of the drawer. */\n position?: DrawerPosition = 'right';\n\n /** Width of the drawer. */\n width?: string;\n\n /** Height of the drawer. */\n height?: string;\n\n /** Min-width of the drawer. If a number is provided, assumes pixel units. */\n minWidth?: number | string;\n\n /** Min-height of the drawer. If a number is provided, assumes pixel units. */\n minHeight?: number | string;\n\n /** Max-width of the drawer. If a number is provided, assumes pixel units. */\n maxWidth?: number | string;\n\n /** Max-height of the drawer. If a number is provided, assumes pixel units. */\n maxHeight?: number | string;\n}\n","import {\n animate,\n state,\n style,\n transition,\n trigger,\n AnimationTriggerMetadata,\n} from '@angular/animations';\n\n/** Animations used by the drawer. */\nexport const mtxDrawerAnimations: {\n readonly drawerState: AnimationTriggerMetadata;\n} = {\n /** Animation that shows and hides a drawer. */\n drawerState: trigger('state', [\n state(\n 'void, hidden',\n style({\n 'box-shadow': 'none',\n 'visibility': 'hidden',\n })\n ),\n state(\n 'visible',\n style({\n transform: 'none',\n visibility: 'visible',\n })\n ),\n transition(\n 'visible => void, visible => hidden',\n animate('400ms cubic-bezier(0.25, 0.8, 0.25, 1)')\n ),\n transition('void => visible', animate('150ms cubic-bezier(0, 0, 0.2, 1)')),\n ]),\n};\n","import { AnimationEvent } from '@angular/animations';\nimport { FocusMonitor, FocusTrapFactory, InteractivityChecker } from '@angular/cdk/a11y';\nimport { CdkDialogContainer } from '@angular/cdk/dialog';\nimport { OverlayRef } from '@angular/cdk/overlay';\nimport { CdkPortalOutlet } from '@angular/cdk/portal';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n Inject,\n NgZone,\n OnDestroy,\n Optional,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { mtxDrawerAnimations } from './drawer-animations';\nimport { MtxDrawerConfig } from './drawer-config';\n\n/**\n * Internal component that wraps user-provided drawer content.\n * @docs-private\n */\n@Component({\n selector: 'mtx-drawer-container',\n templateUrl: 'drawer-container.html',\n styleUrl: 'drawer-container.scss',\n // In Ivy embedded views will be change detected from their declaration place, rather than where\n // they were stamped out. This means that we can't have the drawer container be OnPush,\n // because it might cause the sheets that were opened from a template not to be out of date.\n changeDetection: ChangeDetectionStrategy.Default,\n encapsulation: ViewEncapsulation.None,\n animations: [mtxDrawerAnimations.drawerState],\n host: {\n 'class': 'mtx-drawer-container',\n '[class]': '_drawerPosition',\n 'tabindex': '-1',\n '[id]': '_config.id',\n '[attr.role]': '_config.role',\n '[attr.aria-modal]': '_config.isModal',\n '[attr.aria-label]': '_config.ariaLabel',\n '[@state]': '_animationState',\n '(@state.start)': '_onAnimationStart($event)',\n '(@state.done)': '_onAnimationDone($event)',\n },\n standalone: true,\n imports: [CdkPortalOutlet],\n})\nexport class MtxDrawerContainer extends CdkDialogContainer<MtxDrawerConfig> implements OnDestroy {\n /** The portal outlet inside of this container into which the content will be loaded. */\n @ViewChild(CdkPortalOutlet, { static: true }) _portalOutlet!: CdkPortalOutlet;\n\n /** The state of the drawer animations. */\n _animationState: 'void' | 'visible' | 'hidden' = 'void';\n\n /** Emits whenever the state of the animation changes. */\n _animationStateChanged = new EventEmitter<AnimationEvent>();\n\n /** Whether the component has been destroyed. */\n private _destroyed = false;\n\n get _drawerPosition() {\n return `mtx-drawer-${this._config.position}`;\n }\n\n constructor(\n elementRef: ElementRef,\n focusTrapFactory: FocusTrapFactory,\n @Optional() @Inject(DOCUMENT) document: any,\n config: MtxDrawerConfig,\n checker: InteractivityChecker,\n ngZone: NgZone,\n overlayRef: OverlayRef,\n focusMonitor?: FocusMonitor\n ) {\n super(\n elementRef,\n focusTrapFactory,\n document,\n config,\n checker,\n ngZone,\n overlayRef,\n focusMonitor\n );\n }\n\n protected override _contentAttached(): void {\n // Delegate to the original dialog-container initialization (i.e. saving the\n // previous element, setting up the focus trap and moving focus to the container).\n super._contentAttached();\n\n this.enter();\n }\n\n /** Begin animation of bottom sheet entrance into view. */\n enter(): void {\n if (!this._destroyed) {\n this._animationState = 'visible';\n this._changeDetectorRef.markForCheck();\n this._changeDetectorRef.detectChanges();\n }\n }\n\n /** Begin animation of the bottom sheet exiting from view. */\n exit(): void {\n if (!this._destroyed) {\n this._animationState = 'hidden';\n this._changeDetectorRef.markForCheck();\n }\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n\n this._destroyed = true;\n }\n\n _onAnimationDone(event: AnimationEvent) {\n if (event.toState === 'visible') {\n this._trapFocus();\n }\n\n this._animationStateChanged.emit(event);\n }\n\n _onAnimationStart(event: AnimationEvent) {\n this._animationStateChanged.emit(event);\n }\n\n protected override _captureInitialFocus(): void {}\n}\n","<ng-template cdkPortalOutlet></ng-template>\n","import { DialogRef } from '@angular/cdk/dialog';\nimport { ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';\nimport { merge, Observable, Subject } from 'rxjs';\nimport { filter, take } from 'rxjs/operators';\nimport { MtxDrawerConfig } from './drawer-config';\nimport { MtxDrawerContainer } from './drawer-container';\nimport { ComponentRef } from '@angular/core';\n\n/**\n * Reference to a drawer dispatched from the drawer service.\n */\nexport class MtxDrawerRef<T = any, R = any> {\n /** Instance of the component making up the content of the drawer. */\n get instance(): T {\n return this._ref.componentInstance!;\n }\n\n /**\n * `ComponentRef` of the component opened into the drawer. Will be\n * null when the drawer is opened using a `TemplateRef`.\n */\n get componentRef(): ComponentRef<T> | null {\n return this._ref.componentRef;\n }\n\n /**\n * Instance of the component into which the drawer content is projected.\n * @docs-private\n */\n containerInstance: MtxDrawerContainer;\n\n /** Whether the user is allowed to close the drawer. */\n disableClose: boolean | undefined;\n\n /** Unique ID for the drawer. */\n id: string;\n\n /** Subject for notifying the user that the drawer has been dismissed. */\n private readonly _afterDismissed = new Subject<R | undefined>();\n\n /** Subject for notifying the user that the drawer has opened and appeared. */\n private readonly _afterOpened = new Subject<void>();\n\n /** Result to be passed down to the `afterDismissed` stream. */\n private _result: R | undefined;\n\n /** Handle to the timeout that's running as a fallback in case the exit animation doesn't fire. */\n private _closeFallbackTimeout: any;\n\n constructor(\n private _ref: DialogRef<R, T>,\n config: MtxDrawerConfig,\n containerInstance: MtxDrawerContainer\n ) {\n this.containerInstance = containerInstance;\n this.disableClose = config.disableClose;\n this.id = _ref.id;\n\n // Emit when opening animation completes\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'visible'),\n take(1)\n )\n .subscribe(() => {\n this._afterOpened.next();\n this._afterOpened.complete();\n });\n\n // Dispose overlay when closing animation is complete\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'hidden'),\n take(1)\n )\n .subscribe(() => {\n clearTimeout(this._closeFallbackTimeout);\n this._ref.close(this._result);\n });\n\n _ref.overlayRef.detachments().subscribe(() => {\n this._ref.close(this._result);\n });\n\n merge(\n this.backdropClick(),\n this.keydownEvents().pipe(filter(event => event.keyCode === ESCAPE))\n ).subscribe(event => {\n if (\n !this.disableClose &&\n (event.type !== 'keydown' || !hasModifierKey(event as KeyboardEvent))\n ) {\n event.preventDefault();\n this.dismiss();\n }\n });\n }\n\n /**\n * Dismisses the drawer.\n * @param result Data to be passed back to the drawer opener.\n */\n dismiss(result?: R): void {\n if (this.containerInstance && !this._afterDismissed.closed) {\n // Transition the backdrop in parallel to the drawer.\n this.containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'start'),\n take(1)\n )\n .subscribe(event => {\n // The logic that disposes of the overlay depends on the exit animation completing, however\n // it isn't guaranteed if the parent view is destroyed while it's running. Add a fallback\n // timeout which will clean everything up if the animation hasn't fired within the specified\n // amount of time plus 100ms. We don't need to run this outside the NgZone, because for the\n // vast majority of cases the timeout will have been cleared before it has fired.\n this._closeFallbackTimeout = setTimeout(() => {\n this._ref.close(this._result);\n }, event.totalTime + 100);\n\n this._ref.overlayRef.detachBackdrop();\n });\n\n this._result = result;\n this.containerInstance.exit();\n this.containerInstance = null!;\n }\n }\n\n /** Gets an observable that is notified when the drawer is finished closing. */\n afterDismissed(): Observable<R | undefined> {\n return this._ref.closed;\n }\n\n /** Gets an observable that is notified when the drawer has opened and appeared. */\n afterOpened(): Observable<void> {\n return this._afterOpened;\n }\n\n /**\n * Gets an observable that emits when the overlay's backdrop has been clicked.\n */\n backdropClick(): Observable<MouseEvent> {\n return this._ref.backdropClick;\n }\n\n /**\n * Gets an observable that emits when keydown events are targeted on the overlay.\n */\n keydownEvents(): Observable<KeyboardEvent> {\n return this._ref.keydownEvents;\n }\n}\n","import { coerceCssPixelValue } from '@angular/cdk/coercion';\nimport { Dialog, DialogConfig } from '@angular/cdk/dialog';\nimport { Overlay } from '@angular/cdk/overlay';\nimport { ComponentType } from '@angular/cdk/portal';\nimport {\n Inject,\n Injectable,\n InjectionToken,\n Injector,\n OnDestroy,\n Optional,\n SkipSelf,\n TemplateRef,\n} from '@angular/core';\nimport { defer, Observable, Subject } from 'rxjs';\nimport { startWith } from 'rxjs/operators';\nimport { MtxDrawerConfig } from './drawer-config';\nimport { MtxDrawerContainer } from './drawer-container';\nimport { MtxDrawerRef } from './drawer-ref';\n\n/** Injection token that can be used to access the data that was passed in to a drawer. */\nexport const MTX_DRAWER_DATA = new InjectionToken<any>('MtxDrawerData');\n\n/** Injection token that can be used to specify default drawer options. */\nexport const MTX_DRAWER_DEFAULT_OPTIONS = new InjectionToken<MtxDrawerConfig>(\n 'mtx-drawer-default-options'\n);\n\n// Counter for unique drawer ids.\nlet uniqueId = 0;\n\n/**\n * Service to trigger Material Design bottom sheets.\n */\n@Injectable({ providedIn: 'root' })\nexport class MtxDrawer implements OnDestroy {\n private readonly _openDrawersAtThisLevel: MtxDrawerRef<any>[] = [];\n private readonly _afterAllDismissedAtThisLevel = new Subject<void>();\n private readonly _afterOpenedAtThisLevel = new Subject<MtxDrawerRef<any>>();\n private _dialog: Dialog;\n\n /** Keeps track of the currently-open dialogs. */\n get openDrawers(): MtxDrawerRef<any>[] {\n return this._parentDrawer ? this._parentDrawer.openDrawers : this._openDrawersAtThisLevel;\n }\n\n /** Stream that emits when a drawer has been opened. */\n get afterOpened(): Subject<MtxDrawerRef<any>> {\n return this._parentDrawer ? this._parentDrawer.afterOpened : this._afterOpenedAtThisLevel;\n }\n\n private _getAfterAllDismissed(): Subject<void> {\n const parent = this._parentDrawer;\n return parent ? parent._getAfterAllDismissed() : this._afterAllDismissedAtThisLevel;\n }\n\n /**\n * Stream that emits when all open drawer have finished closing.\n * Will emit on subscribe if there are no open drawers to begin with.\n */\n readonly afterAllDismissed: Observable<void> = defer(() =>\n this.openDrawers.length\n ? this._getAfterAllDismissed()\n : this._getAfterAllDismissed().pipe(startWith(undefined))\n ) as Observable<any>;\n\n constructor(\n private _overlay: Overlay,\n injector: Injector,\n @Optional() @SkipSelf() private _parentDrawer: MtxDrawer,\n @Optional()\n @Inject(MTX_DRAWER_DEFAULT_OPTIONS)\n private _defaultOptions?: MtxDrawerConfig\n ) {\n this._dialog = injector.get(Dialog);\n }\n\n /**\n * Opens a drawer containing the given component.\n * @param component Type of the component to load into the drawer.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened drawer.\n */\n open<T, D = any, R = any>(\n component: ComponentType<T>,\n config?: MtxDrawerConfig<D>\n ): MtxDrawerRef<T, R>;\n\n /**\n * Opens a drawer containing the given template.\n * @param template TemplateRef to instantiate as the drawer content.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened drawer.\n */\n open<T, D = any, R = any>(\n template: TemplateRef<T>,\n config?: MtxDrawerConfig<D>\n ): MtxDrawerRef<T, R>;\n\n open<T, D = any, R = any>(\n componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n config?: MtxDrawerConfig<D>\n ): MtxDrawerRef<T, R> {\n let drawerRef!: MtxDrawerRef<T, R>;\n\n const _config = { ...(this._defaultOptions || new MtxDrawerConfig()), ...config };\n _config.id = _config.id || `mtx-drawer-${uniqueId++}`;\n\n _config.width =\n _config.position === 'left' || _config.position === 'right'\n ? coerceCssPixelValue(_config.width)\n : '100vw';\n\n _config.height =\n _config.position === 'top' || _config.position === 'bottom'\n ? coerceCssPixelValue(_config.height)\n : '100vh';\n\n this._dialog.open<R, D, T>(componentOrTemplateRef, {\n ..._config,\n // Disable closing since we need to sync it up to the animation ourselves.\n disableClose: true,\n // Disable closing on detachments so that we can sync up the animation.\n closeOnOverlayDetachments: false,\n container: {\n type: MtxDrawerContainer,\n providers: () => [\n // Provide our config as the CDK config as well since it has the same interface as the\n // CDK one, but it contains the actual values passed in by the user for things like\n // `disableClose` which we disable for the CDK dialog since we handle it ourselves.\n { provide: MtxDrawerConfig, useValue: _config },\n { provide: DialogConfig, useValue: _config },\n ],\n },\n scrollStrategy: _config.scrollStrategy || this._overlay.scrollStrategies.block(),\n positionStrategy: this._overlay.position().global()[_config.position!]('0'),\n templateContext: () => ({ drawerRef }),\n providers: (cdkRef, _cdkConfig, container) => {\n drawerRef = new MtxDrawerRef(cdkRef, _config, container as MtxDrawerContainer);\n return [\n { provide: MtxDrawerRef, useValue: drawerRef },\n { provide: MTX_DRAWER_DATA, useValue: _config.data },\n ];\n },\n });\n\n this.openDrawers.push(drawerRef);\n this.afterOpened.next(drawerRef);\n\n drawerRef.afterDismissed().subscribe(() => {\n const index = this.openDrawers.indexOf(drawerRef);\n\n if (index > -1) {\n this.openDrawers.splice(index, 1);\n\n if (!this.openDrawers.length) {\n this._getAfterAllDismissed().next();\n }\n }\n });\n\n return drawerRef;\n }\n\n /**\n * Dismisses all of the currently-open drawers.\n */\n dismissAll(): void {\n this._dismissDrawers(this.openDrawers);\n }\n\n /**\n * Finds an open drawer by its id.\n * @param id ID to use when looking up the drawer.\n */\n getDrawerById(id: string): MtxDrawerRef<any> | undefined {\n return this.openDrawers.find(drawer => drawer.id === id);\n }\n\n ngOnDestroy() {\n // Only dismiss the drawers at this level on destroy\n // since the parent service may still be active.\n this._dismissDrawers(this._openDrawersAtThisLevel);\n this._afterAllDismissedAtThisLevel.complete();\n this._afterOpenedAtThisLevel.complete();\n }\n\n private _dismissDrawers(drawers: MtxDrawerRef<any>[]) {\n let i = drawers.length;\n\n while (i--) {\n drawers[i].dismiss();\n }\n }\n}\n","import { DialogModule } from '@angular/cdk/dialog';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { NgModule } from '@angular/core';\nimport { MatCommonModule } from '@angular/material/core';\nimport { MtxDrawer } from './drawer';\nimport { MtxDrawerContainer } from './drawer-container';\n\n@NgModule({\n imports: [DialogModule, PortalModule, MatCommonModule, MtxDrawerContainer],\n exports: [MtxDrawerContainer, MatCommonModule],\n providers: [MtxDrawer],\n})\nexport class MtxDrawerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i2.MtxDrawerConfig"],"mappings":";;;;;;;;;;;;;;AAUA;;AAEG;MACU,eAAe,CAAA;AAA5B,IAAA,WAAA,GAAA;;QAcE,IAAI,CAAA,IAAA,GAAc,IAAI,CAAC;;QAGvB,IAAW,CAAA,WAAA,GAAa,IAAI,CAAC;;QAM7B,IAAY,CAAA,YAAA,GAAa,KAAK,CAAC;;QAG/B,IAAS,CAAA,SAAA,GAAmB,IAAI,CAAC;AAEjC;;;;AAIG;QACH,IAAiB,CAAA,iBAAA,GAAa,IAAI,CAAC;AAEnC;;;;AAIG;QACH,IAAS,CAAA,SAAA,GAAwC,gBAAgB,CAAC;AAElE;;;AAGG;QACH,IAAY,CAAA,YAAA,GAAa,IAAI,CAAC;;QAM9B,IAAQ,CAAA,QAAA,GAAoB,OAAO,CAAC;KAmBrC;AAAA;;AC3ED;AACa,MAAA,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A,IAAA,EAAA,SAAS,cADI,MAAM,EAAA,CAAA,CAAA,EAAA;;2FACnB,SAAS,EAAA,UAAA,EAAA,CAAA;kBADrB,UAAU;mBAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAA;;0BAmC7B,QAAQ;;0BAAI,QAAQ;;0BACpB,QAAQ;;0BACR,MAAM;2BAAC,0BAA0B,CAAA;;;MC3DzB,eAAe,CAAA;iIAAf,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA,EAAA;kIAAf,eAAe,EAAA,OAAA,EAAA,CAJhB,YAAY,EAAE,YAAY,EAAE,eAAe,EAAE,kBAAkB,CAAA,EAAA,OAAA,EAAA,CAC/D,kBAAkB,EAAE,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;kIAGlC,eAAe,EAAA,SAAA,EAFf,CAAC,SAAS,CAAC,EAAA,OAAA,EAAA,CAFZ,YAAY,EAAE,YAAY,EAAE,eAAe,EACvB,eAAe,CAAA,EAAA,CAAA,CAAA,EAAA;;2FAGlC,eAAe,EAAA,UAAA,EAAA,CAAA;kBAL3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,YAAY,EAAE,YAAY,EAAE,eAAe,EAAE,kBAAkB,CAAC;AAC1E,oBAAA,OAAO,EAAE,CAAC,kBAAkB,EAAE,eAAe,CAAC;oBAC9C,SAAS,EAAE,CAAC,SAAS,CAAC;AACvB,iBAAA,CAAA;;;ACXD;;AAEG;;;;"}
1
+ {"version":3,"file":"mtxDrawer.mjs","sources":["../../../projects/extensions/drawer/drawer-config.ts","../../../projects/extensions/drawer/drawer-animations.ts","../../../projects/extensions/drawer/drawer-container.ts","../../../projects/extensions/drawer/drawer-container.html","../../../projects/extensions/drawer/drawer-ref.ts","../../../projects/extensions/drawer/drawer.ts","../../../projects/extensions/drawer/drawer-module.ts","../../../projects/extensions/drawer/mtxDrawer.ts"],"sourcesContent":["import { Direction } from '@angular/cdk/bidi';\nimport { ScrollStrategy } from '@angular/cdk/overlay';\nimport { ViewContainerRef } from '@angular/core';\n\n/** Options for where to set focus to automatically on dialog open. */\nexport type AutoFocusTarget = 'dialog' | 'first-tabbable' | 'first-heading';\n\n/** Possible overrides for a drawer's position. */\nexport type DrawerPosition = 'top' | 'bottom' | 'left' | 'right';\n\n/**\n * Configuration used when opening a drawer.\n */\nexport class MtxDrawerConfig<D = any> {\n /** The view container to place the overlay for the drawer into. */\n viewContainerRef?: ViewContainerRef;\n\n /** ID for the drawer. If omitted, a unique one will be generated. */\n id?: string;\n\n /** Extra CSS classes to be added to the drawer container. */\n panelClass?: string | string[];\n\n /** Text layout direction for the drawer. */\n direction?: Direction;\n\n /** Data being injected into the child component. */\n data?: D | null = null;\n\n /** Whether the drawer has a backdrop. */\n hasBackdrop?: boolean = true;\n\n /** Custom class for the backdrop. */\n backdropClass?: string;\n\n /** Whether the user can use escape or clicking outside to close the drawer. */\n disableClose?: boolean = false;\n\n /** Aria label to assign to the drawer element. */\n ariaLabel?: string | null = null;\n\n /**\n * Whether the drawer should close when the user goes backwards/forwards in history.\n * Note that this usually doesn't include clicking on links (unless the user is using\n * the `HashLocationStrategy`).\n */\n closeOnNavigation?: boolean = true;\n\n /**\n * Where the drawer should focus on open.\n * @breaking-change 14.0.0 Remove boolean option from autoFocus. Use string or\n * AutoFocusTarget instead.\n */\n autoFocus?: AutoFocusTarget | string | boolean = 'first-tabbable';\n\n /**\n * Whether the drawer should restore focus to the\n * previously-focused element, after it's closed.\n */\n restoreFocus?: boolean = true;\n\n /** Scroll strategy to be used for the drawer. */\n scrollStrategy?: ScrollStrategy;\n\n /** Position of the drawer. */\n position?: DrawerPosition = 'right';\n\n /** Width of the drawer. */\n width?: string;\n\n /** Height of the drawer. */\n height?: string;\n\n /** Min-width of the drawer. If a number is provided, assumes pixel units. */\n minWidth?: number | string;\n\n /** Min-height of the drawer. If a number is provided, assumes pixel units. */\n minHeight?: number | string;\n\n /** Max-width of the drawer. If a number is provided, assumes pixel units. */\n maxWidth?: number | string;\n\n /** Max-height of the drawer. If a number is provided, assumes pixel units. */\n maxHeight?: number | string;\n}\n","import {\n animate,\n state,\n style,\n transition,\n trigger,\n AnimationTriggerMetadata,\n} from '@angular/animations';\n\n/** Animations used by the drawer. */\nexport const mtxDrawerAnimations: {\n readonly drawerState: AnimationTriggerMetadata;\n} = {\n /** Animation that shows and hides a drawer. */\n drawerState: trigger('state', [\n state(\n 'void, hidden',\n style({\n 'box-shadow': 'none',\n 'visibility': 'hidden',\n })\n ),\n state(\n 'visible',\n style({\n transform: 'none',\n visibility: 'visible',\n })\n ),\n transition(\n 'visible => void, visible => hidden',\n animate('400ms cubic-bezier(0.25, 0.8, 0.25, 1)')\n ),\n transition('void => visible', animate('150ms cubic-bezier(0, 0, 0.2, 1)')),\n ]),\n};\n","import { AnimationEvent } from '@angular/animations';\nimport { CdkDialogContainer } from '@angular/cdk/dialog';\nimport { CdkPortalOutlet } from '@angular/cdk/portal';\nimport {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n OnDestroy,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport { mtxDrawerAnimations } from './drawer-animations';\nimport { MtxDrawerConfig } from './drawer-config';\n\n/**\n * Internal component that wraps user-provided drawer content.\n * @docs-private\n */\n@Component({\n selector: 'mtx-drawer-container',\n templateUrl: 'drawer-container.html',\n styleUrl: 'drawer-container.scss',\n // In Ivy embedded views will be change detected from their declaration place, rather than where\n // they were stamped out. This means that we can't have the drawer container be OnPush,\n // because it might cause the sheets that were opened from a template not to be out of date.\n changeDetection: ChangeDetectionStrategy.Default,\n encapsulation: ViewEncapsulation.None,\n animations: [mtxDrawerAnimations.drawerState],\n host: {\n 'class': 'mtx-drawer-container',\n '[class]': '_drawerPosition',\n 'tabindex': '-1',\n '[id]': '_config.id',\n '[attr.role]': '_config.role',\n '[attr.aria-modal]': '_config.isModal',\n '[attr.aria-label]': '_config.ariaLabel',\n '[@state]': '_animationState',\n '(@state.start)': '_onAnimationStart($event)',\n '(@state.done)': '_onAnimationDone($event)',\n },\n imports: [CdkPortalOutlet],\n})\nexport class MtxDrawerContainer extends CdkDialogContainer<MtxDrawerConfig> implements OnDestroy {\n /** The portal outlet inside of this container into which the content will be loaded. */\n @ViewChild(CdkPortalOutlet, { static: true }) _portalOutlet!: CdkPortalOutlet;\n\n /** The state of the drawer animations. */\n _animationState: 'void' | 'visible' | 'hidden' = 'void';\n\n /** Emits whenever the state of the animation changes. */\n _animationStateChanged = new EventEmitter<AnimationEvent>();\n\n /** Whether the component has been destroyed. */\n private _destroyed = false;\n\n get _drawerPosition() {\n return `mtx-drawer-${this._config.position}`;\n }\n\n protected override _contentAttached(): void {\n // Delegate to the original dialog-container initialization (i.e. saving the\n // previous element, setting up the focus trap and moving focus to the container).\n super._contentAttached();\n\n this.enter();\n }\n\n /** Begin animation of bottom sheet entrance into view. */\n enter(): void {\n if (!this._destroyed) {\n this._animationState = 'visible';\n this._changeDetectorRef.markForCheck();\n this._changeDetectorRef.detectChanges();\n }\n }\n\n /** Begin animation of the bottom sheet exiting from view. */\n exit(): void {\n if (!this._destroyed) {\n this._animationState = 'hidden';\n this._changeDetectorRef.markForCheck();\n }\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n\n this._destroyed = true;\n }\n\n _onAnimationDone(event: AnimationEvent) {\n if (event.toState === 'visible') {\n this._trapFocus();\n }\n\n this._animationStateChanged.emit(event);\n }\n\n _onAnimationStart(event: AnimationEvent) {\n this._animationStateChanged.emit(event);\n }\n\n protected override _captureInitialFocus(): void {}\n}\n","<ng-template cdkPortalOutlet></ng-template>\n","import { DialogRef } from '@angular/cdk/dialog';\nimport { ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';\nimport { merge, Observable, Subject } from 'rxjs';\nimport { filter, take } from 'rxjs/operators';\nimport { MtxDrawerConfig } from './drawer-config';\nimport { MtxDrawerContainer } from './drawer-container';\nimport { ComponentRef } from '@angular/core';\n\n/**\n * Reference to a drawer dispatched from the drawer service.\n */\nexport class MtxDrawerRef<T = any, R = any> {\n /** Instance of the component making up the content of the drawer. */\n get instance(): T {\n return this._ref.componentInstance!;\n }\n\n /**\n * `ComponentRef` of the component opened into the drawer. Will be\n * null when the drawer is opened using a `TemplateRef`.\n */\n get componentRef(): ComponentRef<T> | null {\n return this._ref.componentRef;\n }\n\n /**\n * Instance of the component into which the drawer content is projected.\n * @docs-private\n */\n containerInstance: MtxDrawerContainer;\n\n /** Whether the user is allowed to close the drawer. */\n disableClose: boolean | undefined;\n\n /** Unique ID for the drawer. */\n id: string;\n\n /** Subject for notifying the user that the drawer has been dismissed. */\n private readonly _afterDismissed = new Subject<R | undefined>();\n\n /** Subject for notifying the user that the drawer has opened and appeared. */\n private readonly _afterOpened = new Subject<void>();\n\n /** Result to be passed down to the `afterDismissed` stream. */\n private _result: R | undefined;\n\n /** Handle to the timeout that's running as a fallback in case the exit animation doesn't fire. */\n private _closeFallbackTimeout: any;\n\n constructor(\n private _ref: DialogRef<R, T>,\n config: MtxDrawerConfig,\n containerInstance: MtxDrawerContainer\n ) {\n this.containerInstance = containerInstance;\n this.disableClose = config.disableClose;\n this.id = _ref.id;\n\n // Emit when opening animation completes\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'visible'),\n take(1)\n )\n .subscribe(() => {\n this._afterOpened.next();\n this._afterOpened.complete();\n });\n\n // Dispose overlay when closing animation is complete\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'hidden'),\n take(1)\n )\n .subscribe(() => {\n clearTimeout(this._closeFallbackTimeout);\n this._ref.close(this._result);\n });\n\n _ref.overlayRef.detachments().subscribe(() => {\n this._ref.close(this._result);\n });\n\n merge(\n this.backdropClick(),\n this.keydownEvents().pipe(filter(event => event.keyCode === ESCAPE))\n ).subscribe(event => {\n if (\n !this.disableClose &&\n (event.type !== 'keydown' || !hasModifierKey(event as KeyboardEvent))\n ) {\n event.preventDefault();\n this.dismiss();\n }\n });\n }\n\n /**\n * Dismisses the drawer.\n * @param result Data to be passed back to the drawer opener.\n */\n dismiss(result?: R): void {\n if (this.containerInstance && !this._afterDismissed.closed) {\n // Transition the backdrop in parallel to the drawer.\n this.containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'start'),\n take(1)\n )\n .subscribe(event => {\n // The logic that disposes of the overlay depends on the exit animation completing, however\n // it isn't guaranteed if the parent view is destroyed while it's running. Add a fallback\n // timeout which will clean everything up if the animation hasn't fired within the specified\n // amount of time plus 100ms. We don't need to run this outside the NgZone, because for the\n // vast majority of cases the timeout will have been cleared before it has fired.\n this._closeFallbackTimeout = setTimeout(() => {\n this._ref.close(this._result);\n }, event.totalTime + 100);\n\n this._ref.overlayRef.detachBackdrop();\n });\n\n this._result = result;\n this.containerInstance.exit();\n this.containerInstance = null!;\n }\n }\n\n /** Gets an observable that is notified when the drawer is finished closing. */\n afterDismissed(): Observable<R | undefined> {\n return this._ref.closed;\n }\n\n /** Gets an observable that is notified when the drawer has opened and appeared. */\n afterOpened(): Observable<void> {\n return this._afterOpened;\n }\n\n /**\n * Gets an observable that emits when the overlay's backdrop has been clicked.\n */\n backdropClick(): Observable<MouseEvent> {\n return this._ref.backdropClick;\n }\n\n /**\n * Gets an observable that emits when keydown events are targeted on the overlay.\n */\n keydownEvents(): Observable<KeyboardEvent> {\n return this._ref.keydownEvents;\n }\n}\n","import { coerceCssPixelValue } from '@angular/cdk/coercion';\nimport { Dialog, DialogConfig } from '@angular/cdk/dialog';\nimport { Overlay } from '@angular/cdk/overlay';\nimport { ComponentType } from '@angular/cdk/portal';\nimport {\n Injectable,\n InjectionToken,\n Injector,\n OnDestroy,\n TemplateRef,\n inject,\n} from '@angular/core';\nimport { defer, Observable, Subject } from 'rxjs';\nimport { startWith } from 'rxjs/operators';\nimport { MtxDrawerConfig } from './drawer-config';\nimport { MtxDrawerContainer } from './drawer-container';\nimport { MtxDrawerRef } from './drawer-ref';\n\n/** Injection token that can be used to access the data that was passed in to a drawer. */\nexport const MTX_DRAWER_DATA = new InjectionToken<any>('MtxDrawerData');\n\n/** Injection token that can be used to specify default drawer options. */\nexport const MTX_DRAWER_DEFAULT_OPTIONS = new InjectionToken<MtxDrawerConfig>(\n 'mtx-drawer-default-options'\n);\n\n// Counter for unique drawer ids.\nlet uniqueId = 0;\n\n/**\n * Service to trigger Material Design bottom sheets.\n */\n@Injectable({ providedIn: 'root' })\nexport class MtxDrawer implements OnDestroy {\n private _overlay = inject(Overlay);\n private _parentDrawer = inject(MtxDrawer, { optional: true, skipSelf: true });\n private _defaultOptions = inject<MtxDrawerConfig>(MTX_DRAWER_DEFAULT_OPTIONS, { optional: true });\n\n private readonly _openDrawersAtThisLevel: MtxDrawerRef<any>[] = [];\n private readonly _afterAllDismissedAtThisLevel = new Subject<void>();\n private readonly _afterOpenedAtThisLevel = new Subject<MtxDrawerRef<any>>();\n private _dialog = inject(Dialog);\n\n /** Keeps track of the currently-open dialogs. */\n get openDrawers(): MtxDrawerRef<any>[] {\n return this._parentDrawer ? this._parentDrawer.openDrawers : this._openDrawersAtThisLevel;\n }\n\n /** Stream that emits when a drawer has been opened. */\n get afterOpened(): Subject<MtxDrawerRef<any>> {\n return this._parentDrawer ? this._parentDrawer.afterOpened : this._afterOpenedAtThisLevel;\n }\n\n private _getAfterAllDismissed(): Subject<void> {\n const parent = this._parentDrawer;\n return parent ? parent._getAfterAllDismissed() : this._afterAllDismissedAtThisLevel;\n }\n\n /**\n * Stream that emits when all open drawer have finished closing.\n * Will emit on subscribe if there are no open drawers to begin with.\n */\n readonly afterAllDismissed: Observable<void> = defer(() =>\n this.openDrawers.length\n ? this._getAfterAllDismissed()\n : this._getAfterAllDismissed().pipe(startWith(undefined))\n ) as Observable<any>;\n\n /**\n * Opens a drawer containing the given component.\n * @param component Type of the component to load into the drawer.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened drawer.\n */\n open<T, D = any, R = any>(\n component: ComponentType<T>,\n config?: MtxDrawerConfig<D>\n ): MtxDrawerRef<T, R>;\n\n /**\n * Opens a drawer containing the given template.\n * @param template TemplateRef to instantiate as the drawer content.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened drawer.\n */\n open<T, D = any, R = any>(\n template: TemplateRef<T>,\n config?: MtxDrawerConfig<D>\n ): MtxDrawerRef<T, R>;\n\n open<T, D = any, R = any>(\n componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n config?: MtxDrawerConfig<D>\n ): MtxDrawerRef<T, R> {\n let drawerRef!: MtxDrawerRef<T, R>;\n\n const _config = { ...(this._defaultOptions || new MtxDrawerConfig()), ...config };\n _config.id = _config.id || `mtx-drawer-${uniqueId++}`;\n\n _config.width =\n _config.position === 'left' || _config.position === 'right'\n ? coerceCssPixelValue(_config.width)\n : '100vw';\n\n _config.height =\n _config.position === 'top' || _config.position === 'bottom'\n ? coerceCssPixelValue(_config.height)\n : '100vh';\n\n this._dialog.open<R, D, T>(componentOrTemplateRef, {\n ..._config,\n // Disable closing since we need to sync it up to the animation ourselves.\n disableClose: true,\n // Disable closing on detachments so that we can sync up the animation.\n closeOnOverlayDetachments: false,\n container: {\n type: MtxDrawerContainer,\n providers: () => [\n // Provide our config as the CDK config as well since it has the same interface as the\n // CDK one, but it contains the actual values passed in by the user for things like\n // `disableClose` which we disable for the CDK dialog since we handle it ourselves.\n { provide: MtxDrawerConfig, useValue: _config },\n { provide: DialogConfig, useValue: _config },\n ],\n },\n scrollStrategy: _config.scrollStrategy || this._overlay.scrollStrategies.block(),\n positionStrategy: this._overlay.position().global()[_config.position!]('0'),\n templateContext: () => ({ drawerRef }),\n providers: (cdkRef, _cdkConfig, container) => {\n drawerRef = new MtxDrawerRef(cdkRef, _config, container as MtxDrawerContainer);\n return [\n { provide: MtxDrawerRef, useValue: drawerRef },\n { provide: MTX_DRAWER_DATA, useValue: _config.data },\n ];\n },\n });\n\n this.openDrawers.push(drawerRef);\n this.afterOpened.next(drawerRef);\n\n drawerRef.afterDismissed().subscribe(() => {\n const index = this.openDrawers.indexOf(drawerRef);\n\n if (index > -1) {\n this.openDrawers.splice(index, 1);\n\n if (!this.openDrawers.length) {\n this._getAfterAllDismissed().next();\n }\n }\n });\n\n return drawerRef;\n }\n\n /**\n * Dismisses all of the currently-open drawers.\n */\n dismissAll(): void {\n this._dismissDrawers(this.openDrawers);\n }\n\n /**\n * Finds an open drawer by its id.\n * @param id ID to use when looking up the drawer.\n */\n getDrawerById(id: string): MtxDrawerRef<any> | undefined {\n return this.openDrawers.find(drawer => drawer.id === id);\n }\n\n ngOnDestroy() {\n // Only dismiss the drawers at this level on destroy\n // since the parent service may still be active.\n this._dismissDrawers(this._openDrawersAtThisLevel);\n this._afterAllDismissedAtThisLevel.complete();\n this._afterOpenedAtThisLevel.complete();\n }\n\n private _dismissDrawers(drawers: MtxDrawerRef<any>[]) {\n let i = drawers.length;\n\n while (i--) {\n drawers[i].dismiss();\n }\n }\n}\n","import { DialogModule } from '@angular/cdk/dialog';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { NgModule } from '@angular/core';\nimport { MatCommonModule } from '@angular/material/core';\nimport { MtxDrawer } from './drawer';\nimport { MtxDrawerContainer } from './drawer-container';\n\n@NgModule({\n imports: [DialogModule, PortalModule, MatCommonModule, MtxDrawerContainer],\n exports: [MtxDrawerContainer, MatCommonModule],\n providers: [MtxDrawer],\n})\nexport class MtxDrawerModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAUA;;AAEG;MACU,eAAe,CAAA;AAA5B,IAAA,WAAA,GAAA;;QAcE,IAAI,CAAA,IAAA,GAAc,IAAI;;QAGtB,IAAW,CAAA,WAAA,GAAa,IAAI;;QAM5B,IAAY,CAAA,YAAA,GAAa,KAAK;;QAG9B,IAAS,CAAA,SAAA,GAAmB,IAAI;AAEhC;;;;AAIG;QACH,IAAiB,CAAA,iBAAA,GAAa,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