@angular/material 19.0.0-next.4 → 19.0.0-next.6

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 (196) hide show
  1. package/_index.scss +1 -1
  2. package/autocomplete/index.d.ts +5 -15
  3. package/badge/index.d.ts +3 -7
  4. package/bottom-sheet/index.d.ts +5 -15
  5. package/button/index.d.ts +20 -24
  6. package/button-toggle/index.d.ts +5 -8
  7. package/card/index.d.ts +2 -2
  8. package/checkbox/index.d.ts +4 -6
  9. package/chips/index.d.ts +13 -24
  10. package/core/_core.scss +6 -0
  11. package/core/index.d.ts +14 -19
  12. package/datepicker/index.d.ts +44 -70
  13. package/dialog/index.d.ts +10 -34
  14. package/dialog/testing/index.d.ts +1 -1
  15. package/expansion/index.d.ts +9 -13
  16. package/fesm2022/autocomplete/testing.mjs.map +1 -1
  17. package/fesm2022/autocomplete.mjs +32 -62
  18. package/fesm2022/autocomplete.mjs.map +1 -1
  19. package/fesm2022/badge/testing.mjs.map +1 -1
  20. package/fesm2022/badge.mjs +12 -19
  21. package/fesm2022/badge.mjs.map +1 -1
  22. package/fesm2022/bottom-sheet/testing.mjs.map +1 -1
  23. package/fesm2022/bottom-sheet.mjs +17 -32
  24. package/fesm2022/bottom-sheet.mjs.map +1 -1
  25. package/fesm2022/button/testing.mjs.map +1 -1
  26. package/fesm2022/button-toggle/testing.mjs.map +1 -1
  27. package/fesm2022/button-toggle.mjs +18 -34
  28. package/fesm2022/button-toggle.mjs.map +1 -1
  29. package/fesm2022/button.mjs +44 -113
  30. package/fesm2022/button.mjs.map +1 -1
  31. package/fesm2022/card/testing.mjs.map +1 -1
  32. package/fesm2022/card.mjs +5 -9
  33. package/fesm2022/card.mjs.map +1 -1
  34. package/fesm2022/checkbox/testing.mjs.map +1 -1
  35. package/fesm2022/checkbox.mjs +14 -24
  36. package/fesm2022/checkbox.mjs.map +1 -1
  37. package/fesm2022/chips/testing.mjs.map +1 -1
  38. package/fesm2022/chips.mjs +61 -112
  39. package/fesm2022/chips.mjs.map +1 -1
  40. package/fesm2022/core/testing.mjs.map +1 -1
  41. package/fesm2022/core.mjs +31 -66
  42. package/fesm2022/core.mjs.map +1 -1
  43. package/fesm2022/datepicker/testing.mjs.map +1 -1
  44. package/fesm2022/datepicker.mjs +132 -268
  45. package/fesm2022/datepicker.mjs.map +1 -1
  46. package/fesm2022/dialog/testing.mjs +3 -3
  47. package/fesm2022/dialog/testing.mjs.map +1 -1
  48. package/fesm2022/dialog.mjs +27 -85
  49. package/fesm2022/dialog.mjs.map +1 -1
  50. package/fesm2022/divider/testing.mjs.map +1 -1
  51. package/fesm2022/divider.mjs.map +1 -1
  52. package/fesm2022/expansion/testing.mjs.map +1 -1
  53. package/fesm2022/expansion.mjs +32 -67
  54. package/fesm2022/expansion.mjs.map +1 -1
  55. package/fesm2022/form-field/testing/control.mjs.map +1 -1
  56. package/fesm2022/form-field/testing.mjs.map +1 -1
  57. package/fesm2022/form-field.mjs +42 -62
  58. package/fesm2022/form-field.mjs.map +1 -1
  59. package/fesm2022/grid-list/testing.mjs.map +1 -1
  60. package/fesm2022/grid-list.mjs +16 -23
  61. package/fesm2022/grid-list.mjs.map +1 -1
  62. package/fesm2022/icon/testing.mjs.map +1 -1
  63. package/fesm2022/icon.mjs +11 -20
  64. package/fesm2022/icon.mjs.map +1 -1
  65. package/fesm2022/input/testing.mjs.map +1 -1
  66. package/fesm2022/input.mjs +23 -47
  67. package/fesm2022/input.mjs.map +1 -1
  68. package/fesm2022/list/testing.mjs.map +1 -1
  69. package/fesm2022/list.mjs +59 -98
  70. package/fesm2022/list.mjs.map +1 -1
  71. package/fesm2022/material.mjs.map +1 -1
  72. package/fesm2022/menu/testing.mjs.map +1 -1
  73. package/fesm2022/menu.mjs +51 -99
  74. package/fesm2022/menu.mjs.map +1 -1
  75. package/fesm2022/paginator/testing.mjs.map +1 -1
  76. package/fesm2022/paginator.mjs.map +1 -1
  77. package/fesm2022/progress-bar/testing.mjs.map +1 -1
  78. package/fesm2022/progress-bar.mjs +12 -19
  79. package/fesm2022/progress-bar.mjs.map +1 -1
  80. package/fesm2022/progress-spinner/testing.mjs.map +1 -1
  81. package/fesm2022/progress-spinner.mjs +8 -14
  82. package/fesm2022/progress-spinner.mjs.map +1 -1
  83. package/fesm2022/radio/testing.mjs.map +1 -1
  84. package/fesm2022/radio.mjs +21 -34
  85. package/fesm2022/radio.mjs.map +1 -1
  86. package/fesm2022/select/testing.mjs.map +1 -1
  87. package/fesm2022/select.mjs +26 -58
  88. package/fesm2022/select.mjs.map +1 -1
  89. package/fesm2022/sidenav/testing.mjs.map +1 -1
  90. package/fesm2022/sidenav.mjs +50 -70
  91. package/fesm2022/sidenav.mjs.map +1 -1
  92. package/fesm2022/slide-toggle/testing.mjs.map +1 -1
  93. package/fesm2022/slide-toggle.mjs +13 -21
  94. package/fesm2022/slide-toggle.mjs.map +1 -1
  95. package/fesm2022/slider/testing.mjs.map +1 -1
  96. package/fesm2022/slider.mjs +49 -57
  97. package/fesm2022/slider.mjs.map +1 -1
  98. package/fesm2022/snack-bar/testing.mjs.map +1 -1
  99. package/fesm2022/snack-bar.mjs +30 -43
  100. package/fesm2022/snack-bar.mjs.map +1 -1
  101. package/fesm2022/sort/testing.mjs.map +1 -1
  102. package/fesm2022/sort.mjs +18 -37
  103. package/fesm2022/sort.mjs.map +1 -1
  104. package/fesm2022/stepper/testing.mjs.map +1 -1
  105. package/fesm2022/stepper.mjs +30 -42
  106. package/fesm2022/stepper.mjs.map +1 -1
  107. package/fesm2022/table/testing.mjs.map +1 -1
  108. package/fesm2022/table.mjs.map +1 -1
  109. package/fesm2022/tabs/testing.mjs.map +1 -1
  110. package/fesm2022/tabs.mjs +87 -142
  111. package/fesm2022/tabs.mjs.map +1 -1
  112. package/fesm2022/toolbar/testing.mjs.map +1 -1
  113. package/fesm2022/toolbar.mjs +8 -12
  114. package/fesm2022/toolbar.mjs.map +1 -1
  115. package/fesm2022/tooltip/testing.mjs.map +1 -1
  116. package/fesm2022/tooltip.mjs +45 -59
  117. package/fesm2022/tooltip.mjs.map +1 -1
  118. package/fesm2022/tree/testing.mjs.map +1 -1
  119. package/fesm2022/tree.mjs +13 -40
  120. package/fesm2022/tree.mjs.map +1 -1
  121. package/form-field/index.d.ts +10 -24
  122. package/grid-list/index.d.ts +6 -8
  123. package/icon/index.d.ts +2 -2
  124. package/input/index.d.ts +3 -7
  125. package/list/index.d.ts +10 -14
  126. package/menu/index.d.ts +15 -49
  127. package/package.json +2 -2
  128. package/progress-bar/index.d.ts +3 -5
  129. package/progress-spinner/index.d.ts +2 -2
  130. package/radio/index.d.ts +5 -8
  131. package/schematics/ng-add/fonts/material-fonts.d.ts +1 -1
  132. package/schematics/ng-add/fonts/material-fonts.js +2 -2
  133. package/schematics/ng-add/fonts/material-fonts.mjs +2 -2
  134. package/schematics/ng-add/index.d.ts +1 -1
  135. package/schematics/ng-add/index.js +3 -3
  136. package/schematics/ng-add/index.mjs +3 -3
  137. package/schematics/ng-add/package-config.d.ts +1 -1
  138. package/schematics/ng-add/package-config.js +2 -2
  139. package/schematics/ng-add/package-config.mjs +2 -2
  140. package/schematics/ng-add/schema.d.ts +1 -1
  141. package/schematics/ng-add/schema.js +2 -2
  142. package/schematics/ng-add/schema.mjs +2 -2
  143. package/schematics/ng-add/setup-project.d.ts +1 -1
  144. package/schematics/ng-add/setup-project.js +3 -3
  145. package/schematics/ng-add/setup-project.mjs +3 -3
  146. package/schematics/ng-add/theming/create-custom-theme.d.ts +1 -1
  147. package/schematics/ng-add/theming/create-custom-theme.js +2 -2
  148. package/schematics/ng-add/theming/create-custom-theme.mjs +2 -2
  149. package/schematics/ng-add/theming/theming.d.ts +1 -1
  150. package/schematics/ng-add/theming/theming.js +2 -2
  151. package/schematics/ng-add/theming/theming.mjs +2 -2
  152. package/schematics/ng-generate/address-form/index.d.ts +1 -1
  153. package/schematics/ng-generate/address-form/index.js +2 -2
  154. package/schematics/ng-generate/address-form/index.mjs +2 -2
  155. package/schematics/ng-generate/address-form/schema.d.ts +1 -1
  156. package/schematics/ng-generate/address-form/schema.js +2 -2
  157. package/schematics/ng-generate/address-form/schema.mjs +2 -2
  158. package/schematics/ng-generate/dashboard/index.d.ts +1 -1
  159. package/schematics/ng-generate/dashboard/index.js +2 -2
  160. package/schematics/ng-generate/dashboard/index.mjs +2 -2
  161. package/schematics/ng-generate/dashboard/schema.d.ts +1 -1
  162. package/schematics/ng-generate/dashboard/schema.js +2 -2
  163. package/schematics/ng-generate/dashboard/schema.mjs +2 -2
  164. package/schematics/ng-generate/m3-theme/index_bundled.js +1 -1
  165. package/schematics/ng-generate/m3-theme/index_bundled.js.map +1 -1
  166. package/schematics/ng-generate/navigation/index.d.ts +1 -1
  167. package/schematics/ng-generate/navigation/index.js +2 -2
  168. package/schematics/ng-generate/navigation/index.mjs +2 -2
  169. package/schematics/ng-generate/navigation/schema.d.ts +1 -1
  170. package/schematics/ng-generate/navigation/schema.js +2 -2
  171. package/schematics/ng-generate/navigation/schema.mjs +2 -2
  172. package/schematics/ng-generate/table/index.d.ts +1 -1
  173. package/schematics/ng-generate/table/index.js +2 -2
  174. package/schematics/ng-generate/table/index.mjs +2 -2
  175. package/schematics/ng-generate/table/schema.d.ts +1 -1
  176. package/schematics/ng-generate/table/schema.js +2 -2
  177. package/schematics/ng-generate/table/schema.mjs +2 -2
  178. package/schematics/ng-generate/tree/index.d.ts +1 -1
  179. package/schematics/ng-generate/tree/index.js +2 -2
  180. package/schematics/ng-generate/tree/index.mjs +2 -2
  181. package/schematics/ng-generate/tree/schema.d.ts +1 -1
  182. package/schematics/ng-generate/tree/schema.js +2 -2
  183. package/schematics/ng-generate/tree/schema.mjs +2 -2
  184. package/schematics/ng-update/index_bundled.js +6518 -2
  185. package/schematics/ng-update/index_bundled.js.map +4 -4
  186. package/select/index.d.ts +4 -14
  187. package/sidenav/index.d.ts +7 -17
  188. package/slide-toggle/index.d.ts +2 -2
  189. package/slider/index.d.ts +8 -8
  190. package/snack-bar/index.d.ts +6 -22
  191. package/sort/index.d.ts +4 -20
  192. package/stepper/index.d.ts +6 -13
  193. package/tabs/index.d.ts +21 -32
  194. package/toolbar/index.d.ts +3 -4
  195. package/tooltip/index.d.ts +5 -12
  196. package/tree/index.d.ts +5 -18
@@ -90,8 +90,8 @@ let MatTestDialogOpener = class MatTestDialogOpener {
90
90
  MatTestDialogOpener_1.config = config;
91
91
  return MatTestDialogOpener_1;
92
92
  }
93
- constructor(dialog) {
94
- this.dialog = dialog;
93
+ constructor() {
94
+ this.dialog = inject(MatDialog);
95
95
  this._ngZone = inject(NgZone);
96
96
  if (!MatTestDialogOpener_1.component) {
97
97
  throw new Error(`MatTestDialogOpener does not have a component provided.`);
@@ -115,7 +115,7 @@ MatTestDialogOpener = MatTestDialogOpener_1 = __decorate([
115
115
  encapsulation: ViewEncapsulation.None,
116
116
  standalone: true,
117
117
  }),
118
- __metadata("design:paramtypes", [MatDialog])
118
+ __metadata("design:paramtypes", [])
119
119
  ], MatTestDialogOpener);
120
120
  let MatTestDialogOpenerModule = class MatTestDialogOpenerModule {
121
121
  };
@@ -1 +1 @@
1
- {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/dialog/testing/dialog-harness.ts","../../../../../../../src/material/dialog/testing/dialog-opener.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {\n ComponentHarnessConstructor,\n ContentContainerComponentHarness,\n HarnessPredicate,\n TestKey,\n} from '@angular/cdk/testing';\nimport {DialogHarnessFilters} from './dialog-harness-filters';\nimport {DialogRole} from '@angular/material/dialog';\n\n/** Selectors for different sections of the mat-dialog that can contain user content. */\nexport enum MatDialogSection {\n TITLE = '.mat-mdc-dialog-title',\n CONTENT = '.mat-mdc-dialog-content',\n ACTIONS = '.mat-mdc-dialog-actions',\n}\n\n/** Harness for interacting with a standard `MatDialog` in tests. */\nexport class MatDialogHarness\n // @breaking-change 14.0.0 change generic type to MatDialogSection.\n extends ContentContainerComponentHarness<MatDialogSection | string>\n{\n /** The selector for the host element of a `MatDialog` instance. */\n static hostSelector = '.mat-mdc-dialog-container';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a dialog with specific attributes.\n * @param options Options for filtering which dialog instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with<T extends MatDialogHarness>(\n this: ComponentHarnessConstructor<T>,\n options: DialogHarnessFilters = {},\n ): HarnessPredicate<T> {\n return new HarnessPredicate(this, options);\n }\n\n protected _title = this.locatorForOptional(MatDialogSection.TITLE);\n protected _content = this.locatorForOptional(MatDialogSection.CONTENT);\n protected _actions = this.locatorForOptional(MatDialogSection.ACTIONS);\n\n /** Gets the id of the dialog. */\n async getId(): Promise<string | null> {\n const id = await (await this.host()).getAttribute('id');\n // In case no id has been specified, the \"id\" property always returns\n // an empty string. To make this method more explicit, we return null.\n return id !== '' ? id : null;\n }\n\n /** Gets the role of the dialog. */\n async getRole(): Promise<DialogRole | null> {\n return (await this.host()).getAttribute('role') as Promise<DialogRole | null>;\n }\n\n /** Gets the value of the dialog's \"aria-label\" attribute. */\n async getAriaLabel(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-label');\n }\n\n /** Gets the value of the dialog's \"aria-labelledby\" attribute. */\n async getAriaLabelledby(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-labelledby');\n }\n\n /** Gets the value of the dialog's \"aria-describedby\" attribute. */\n async getAriaDescribedby(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-describedby');\n }\n\n /**\n * Closes the dialog by pressing escape.\n *\n * Note: this method does nothing if `disableClose` has been set to `true` for the dialog.\n */\n async close(): Promise<void> {\n await (await this.host()).sendKeys(TestKey.ESCAPE);\n }\n\n /** Gets te dialog's text. */\n async getText() {\n return (await this.host()).text();\n }\n\n /** Gets the dialog's title text. This only works if the dialog is using mat-dialog-title. */\n async getTitleText() {\n return (await this._title())?.text() ?? '';\n }\n\n /** Gets the dialog's content text. This only works if the dialog is using mat-dialog-content. */\n async getContentText() {\n return (await this._content())?.text() ?? '';\n }\n\n /** Gets the dialog's actions text. This only works if the dialog is using mat-dialog-actions. */\n async getActionsText() {\n return (await this._actions())?.text() ?? '';\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ComponentType} from '@angular/cdk/overlay';\nimport {\n ChangeDetectionStrategy,\n Component,\n NgModule,\n NgZone,\n OnDestroy,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport {MatDialog, MatDialogConfig, MatDialogModule, MatDialogRef} from '@angular/material/dialog';\nimport {NoopAnimationsModule} from '@angular/platform-browser/animations';\nimport {Subscription} from 'rxjs';\n\n/** Test component that immediately opens a dialog when bootstrapped. */\n@Component({\n selector: 'mat-test-dialog-opener',\n template: '',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n standalone: true,\n})\nexport class MatTestDialogOpener<T = unknown, R = unknown> implements OnDestroy {\n /** Component that should be opened with the MatDialog `open` method. */\n protected static component: ComponentType<unknown> | undefined;\n\n /** Config that should be provided to the MatDialog `open` method. */\n protected static config: MatDialogConfig | undefined;\n\n /** MatDialogRef returned from the MatDialog `open` method. */\n dialogRef: MatDialogRef<T, R>;\n\n /** Data passed to the `MatDialog` close method. */\n closedResult: R | undefined;\n\n private readonly _afterClosedSubscription: Subscription;\n\n private readonly _ngZone = inject(NgZone);\n\n /** Static method that prepares this class to open the provided component. */\n static withComponent<T = unknown, R = unknown>(\n component: ComponentType<T>,\n config?: MatDialogConfig,\n ) {\n MatTestDialogOpener.component = component;\n MatTestDialogOpener.config = config;\n return MatTestDialogOpener as ComponentType<MatTestDialogOpener<T, R>>;\n }\n\n constructor(public dialog: MatDialog) {\n if (!MatTestDialogOpener.component) {\n throw new Error(`MatTestDialogOpener does not have a component provided.`);\n }\n\n this.dialogRef = this._ngZone.run(() =>\n this.dialog.open<T, R>(\n MatTestDialogOpener.component as ComponentType<T>,\n MatTestDialogOpener.config || {},\n ),\n );\n this._afterClosedSubscription = this.dialogRef.afterClosed().subscribe(result => {\n this.closedResult = result;\n });\n }\n\n ngOnDestroy() {\n this._afterClosedSubscription.unsubscribe();\n MatTestDialogOpener.component = undefined;\n MatTestDialogOpener.config = undefined;\n }\n}\n\n@NgModule({\n imports: [MatDialogModule, NoopAnimationsModule, MatTestDialogOpener],\n})\nexport class MatTestDialogOpenerModule {}\n"],"names":[],"mappings":";;;;;;AAiBA;IACY,iBAIX;AAJD,CAAA,UAAY,gBAAgB,EAAA;AAC1B,IAAA,gBAAA,CAAA,OAAA,CAAA,GAAA,uBAA+B,CAAA;AAC/B,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,yBAAmC,CAAA;AACnC,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,yBAAmC,CAAA;AACrC,CAAC,EAJW,gBAAgB,KAAhB,gBAAgB,GAI3B,EAAA,CAAA,CAAA,CAAA;AAED;MACa,gBAAgB;AAC3B;AACA,SAAQ,gCAA2D,CAAA;AAFrE,IAAA,WAAA,GAAA;;QAmBY,IAAM,CAAA,MAAA,GAAG,IAAI,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;QACzD,IAAQ,CAAA,QAAA,GAAG,IAAI,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC;QAC7D,IAAQ,CAAA,QAAA,GAAG,IAAI,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC;KA0DxE;;aA1EQ,IAAY,CAAA,YAAA,GAAG,2BAAH,CAA+B,EAAA;AAElD;;;;AAIG;AACH,IAAA,OAAO,IAAI,CAET,OAAA,GAAgC,EAAE,EAAA;AAElC,QAAA,OAAO,IAAI,gBAAgB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;KAC5C;;AAOD,IAAA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F;AAhDY,mBAAmB,GAAA,qBAAA,GAAA,UAAA,CAAA;AAP/B,IAAA,SAAS,CAAC;AACT,QAAA,QAAQ,EAAE,wBAAwB;AAClC,QAAA,QAAQ,EAAE,EAAE;QACZ,eAAe,EAAE,uBAAuB,CAAC,MAAM;QAC/C,aAAa,EAAE,iBAAiB,CAAC,IAAI;AACrC,QAAA,UAAU,EAAE,IAAI;KACjB,CAAC;qCA4B2B,SAAS,CAAA,CAAA;AA3BzB,CAAA,EAAA,mBAAmB,CAgD/B,CAAA;AAKY,IAAA,yBAAyB,GAA/B,MAAM,yBAAyB,CAAA;EAAG;AAA5B,yBAAyB,GAAA,UAAA,CAAA;AAHrC,IAAA,QAAQ,CAAC;AACR,QAAA,OAAO,EAAE,CAAC,eAAe,EAAE,oBAAoB,EAAE,mBAAmB,CAAC;KACtE,CAAC;AACW,CAAA,EAAA,yBAAyB,CAAG;;;;"}
1
+ {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/dialog/testing/dialog-harness.ts","../../../../../../../src/material/dialog/testing/dialog-opener.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n ComponentHarnessConstructor,\n ContentContainerComponentHarness,\n HarnessPredicate,\n TestKey,\n} from '@angular/cdk/testing';\nimport {DialogHarnessFilters} from './dialog-harness-filters';\nimport {DialogRole} from '@angular/material/dialog';\n\n/** Selectors for different sections of the mat-dialog that can contain user content. */\nexport enum MatDialogSection {\n TITLE = '.mat-mdc-dialog-title',\n CONTENT = '.mat-mdc-dialog-content',\n ACTIONS = '.mat-mdc-dialog-actions',\n}\n\n/** Harness for interacting with a standard `MatDialog` in tests. */\nexport class MatDialogHarness\n // @breaking-change 14.0.0 change generic type to MatDialogSection.\n extends ContentContainerComponentHarness<MatDialogSection | string>\n{\n /** The selector for the host element of a `MatDialog` instance. */\n static hostSelector = '.mat-mdc-dialog-container';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a dialog with specific attributes.\n * @param options Options for filtering which dialog instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with<T extends MatDialogHarness>(\n this: ComponentHarnessConstructor<T>,\n options: DialogHarnessFilters = {},\n ): HarnessPredicate<T> {\n return new HarnessPredicate(this, options);\n }\n\n protected _title = this.locatorForOptional(MatDialogSection.TITLE);\n protected _content = this.locatorForOptional(MatDialogSection.CONTENT);\n protected _actions = this.locatorForOptional(MatDialogSection.ACTIONS);\n\n /** Gets the id of the dialog. */\n async getId(): Promise<string | null> {\n const id = await (await this.host()).getAttribute('id');\n // In case no id has been specified, the \"id\" property always returns\n // an empty string. To make this method more explicit, we return null.\n return id !== '' ? id : null;\n }\n\n /** Gets the role of the dialog. */\n async getRole(): Promise<DialogRole | null> {\n return (await this.host()).getAttribute('role') as Promise<DialogRole | null>;\n }\n\n /** Gets the value of the dialog's \"aria-label\" attribute. */\n async getAriaLabel(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-label');\n }\n\n /** Gets the value of the dialog's \"aria-labelledby\" attribute. */\n async getAriaLabelledby(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-labelledby');\n }\n\n /** Gets the value of the dialog's \"aria-describedby\" attribute. */\n async getAriaDescribedby(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-describedby');\n }\n\n /**\n * Closes the dialog by pressing escape.\n *\n * Note: this method does nothing if `disableClose` has been set to `true` for the dialog.\n */\n async close(): Promise<void> {\n await (await this.host()).sendKeys(TestKey.ESCAPE);\n }\n\n /** Gets te dialog's text. */\n async getText() {\n return (await this.host()).text();\n }\n\n /** Gets the dialog's title text. This only works if the dialog is using mat-dialog-title. */\n async getTitleText() {\n return (await this._title())?.text() ?? '';\n }\n\n /** Gets the dialog's content text. This only works if the dialog is using mat-dialog-content. */\n async getContentText() {\n return (await this._content())?.text() ?? '';\n }\n\n /** Gets the dialog's actions text. This only works if the dialog is using mat-dialog-actions. */\n async getActionsText() {\n return (await this._actions())?.text() ?? '';\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {ComponentType} from '@angular/cdk/overlay';\nimport {\n ChangeDetectionStrategy,\n Component,\n NgModule,\n NgZone,\n OnDestroy,\n ViewEncapsulation,\n inject,\n} from '@angular/core';\nimport {MatDialog, MatDialogConfig, MatDialogModule, MatDialogRef} from '@angular/material/dialog';\nimport {NoopAnimationsModule} from '@angular/platform-browser/animations';\nimport {Subscription} from 'rxjs';\n\n/** Test component that immediately opens a dialog when bootstrapped. */\n@Component({\n selector: 'mat-test-dialog-opener',\n template: '',\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n standalone: true,\n})\nexport class MatTestDialogOpener<T = unknown, R = unknown> implements OnDestroy {\n dialog = inject(MatDialog);\n\n /** Component that should be opened with the MatDialog `open` method. */\n protected static component: ComponentType<unknown> | undefined;\n\n /** Config that should be provided to the MatDialog `open` method. */\n protected static config: MatDialogConfig | undefined;\n\n /** MatDialogRef returned from the MatDialog `open` method. */\n dialogRef: MatDialogRef<T, R>;\n\n /** Data passed to the `MatDialog` close method. */\n closedResult: R | undefined;\n\n private readonly _afterClosedSubscription: Subscription;\n\n private readonly _ngZone = inject(NgZone);\n\n /** Static method that prepares this class to open the provided component. */\n static withComponent<T = unknown, R = unknown>(\n component: ComponentType<T>,\n config?: MatDialogConfig,\n ) {\n MatTestDialogOpener.component = component;\n MatTestDialogOpener.config = config;\n return MatTestDialogOpener as ComponentType<MatTestDialogOpener<T, R>>;\n }\n\n constructor(...args: unknown[]);\n\n constructor() {\n if (!MatTestDialogOpener.component) {\n throw new Error(`MatTestDialogOpener does not have a component provided.`);\n }\n\n this.dialogRef = this._ngZone.run(() =>\n this.dialog.open<T, R>(\n MatTestDialogOpener.component as ComponentType<T>,\n MatTestDialogOpener.config || {},\n ),\n );\n this._afterClosedSubscription = this.dialogRef.afterClosed().subscribe(result => {\n this.closedResult = result;\n });\n }\n\n ngOnDestroy() {\n this._afterClosedSubscription.unsubscribe();\n MatTestDialogOpener.component = undefined;\n MatTestDialogOpener.config = undefined;\n }\n}\n\n@NgModule({\n imports: [MatDialogModule, NoopAnimationsModule, MatTestDialogOpener],\n})\nexport class MatTestDialogOpenerModule {}\n"],"names":[],"mappings":";;;;;;AAiBA;IACY,iBAIX;AAJD,CAAA,UAAY,gBAAgB,EAAA;AAC1B,IAAA,gBAAA,CAAA,OAAA,CAAA,GAAA,uBAA+B,CAAA;AAC/B,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,yBAAmC,CAAA;AACnC,IAAA,gBAAA,CAAA,SAAA,CAAA,GAAA,yBAAmC,CAAA;AACrC,CAAC,EAJW,gBAAgB,KAAhB,gBAAgB,GAI3B,EAAA,CAAA,CAAA,CAAA;AAED;MACa,gBAAgB;AAC3B;AACA,SAAQ,gCAA2D,CAAA;AAFrE,IAAA,WAAA,GAAA;;QAmBY,IAAM,CAAA,MAAA,GAAG,IAAI,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;QACzD,IAAQ,CAAA,QAAA,GAAG,IAAI,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC;QAC7D,IAAQ,CAAA,QAAA,GAAG,IAAI,CAAC,kBAAkB,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC;KA0DxE;;aA1EQ,IAAY,CAAA,YAAA,GAAG,2BAAH,CAA+B,EAAA;AAElD;;;;AAIG;AACH,IAAA,OAAO,IAAI,CAET,OAAA,GAAgC,EAAE,EAAA;AAElC,QAAA,OAAO,IAAI,gBAAgB,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;KAC5C;;AAOD,IAAA,MAAM,KAAK,GAAA;AACT,QAAA,MAAM,EAAE,GAAG,MAAM,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EA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QAAQ,EAAE,wBAAwB;AAClC,QAAA,QAAQ,EAAE,EAAE;QACZ,eAAe,EAAE,uBAAuB,CAAC,MAAM;QAC/C,aAAa,EAAE,iBAAiB,CAAC,IAAI;AACrC,QAAA,UAAU,EAAE,IAAI;KACjB,CAAC;;AACW,CAAA,EAAA,mBAAmB,CAoD/B,CAAA;AAKY,IAAA,yBAAyB,GAA/B,MAAM,yBAAyB,CAAA;EAAG;AAA5B,yBAAyB,GAAA,UAAA,CAAA;AAHrC,IAAA,QAAQ,CAAC;AACR,QAAA,OAAO,EAAE,CAAC,eAAe,EAAE,oBAAoB,EAAE,mBAAmB,CAAC;KACtE,CAAC;AACW,CAAA,EAAA,yBAAyB,CAAG;;;;"}
@@ -1,17 +1,13 @@
1
- import * as i1$1 from '@angular/cdk/overlay';
2
1
  import { Overlay, OverlayModule } from '@angular/cdk/overlay';
3
- import * as i2 from '@angular/common';
4
- import { DOCUMENT } from '@angular/common';
5
2
  import * as i0 from '@angular/core';
6
- import { inject, ANIMATION_MODULE_TYPE, EventEmitter, Component, ViewEncapsulation, ChangeDetectionStrategy, Optional, Inject, InjectionToken, Injectable, SkipSelf, Directive, Input, NgModule } from '@angular/core';
7
- import * as i1 from '@angular/cdk/a11y';
3
+ import { inject, ANIMATION_MODULE_TYPE, EventEmitter, Component, ViewEncapsulation, ChangeDetectionStrategy, InjectionToken, Injectable, ElementRef, Directive, Input, NgModule } from '@angular/core';
8
4
  import { CdkDialogContainer, Dialog, DialogConfig, DialogModule } from '@angular/cdk/dialog';
9
5
  import { coerceNumberProperty } from '@angular/cdk/coercion';
10
6
  import { CdkPortalOutlet, PortalModule } from '@angular/cdk/portal';
11
7
  import { Subject, merge, defer } from 'rxjs';
12
8
  import { filter, take, startWith } from 'rxjs/operators';
13
9
  import { ESCAPE, hasModifierKey } from '@angular/cdk/keycodes';
14
- import * as i3 from '@angular/cdk/scrolling';
10
+ import * as i1 from '@angular/cdk/scrolling';
15
11
  import { CdkScrollable } from '@angular/cdk/scrolling';
16
12
  import { MatCommonModule } from '@angular/material/core';
17
13
  import { trigger, state, style, transition, group, animate, query, animateChild } from '@angular/animations';
@@ -79,8 +75,8 @@ const OPEN_ANIMATION_DURATION = 150;
79
75
  /** Duration of the closing animation in milliseconds. */
80
76
  const CLOSE_ANIMATION_DURATION = 75;
81
77
  class MatDialogContainer extends CdkDialogContainer {
82
- constructor(elementRef, focusTrapFactory, _document, dialogConfig, interactivityChecker, ngZone, overlayRef, _unusedAnimationMode, focusMonitor) {
83
- super(elementRef, focusTrapFactory, _document, dialogConfig, interactivityChecker, ngZone, overlayRef, focusMonitor);
78
+ constructor() {
79
+ super(...arguments);
84
80
  this._animationMode = inject(ANIMATION_MODULE_TYPE, { optional: true });
85
81
  /** Emits when an animation state changes. */
86
82
  this._animationStateChanged = new EventEmitter();
@@ -248,7 +244,7 @@ class MatDialogContainer extends CdkDialogContainer {
248
244
  ref.location.nativeElement.classList.add('mat-mdc-dialog-component-host');
249
245
  return ref;
250
246
  }
251
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogContainer, deps: [{ token: i0.ElementRef }, { token: i1.FocusTrapFactory }, { token: DOCUMENT, optional: true }, { token: MatDialogConfig }, { token: i1.InteractivityChecker }, { token: i0.NgZone }, { token: i1$1.OverlayRef }, { token: ANIMATION_MODULE_TYPE, optional: true }, { token: i1.FocusMonitor }], target: i0.ɵɵFactoryTarget.Component }); }
247
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogContainer, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
252
248
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.0-next.3", type: MatDialogContainer, isStandalone: true, selector: "mat-dialog-container", host: { attributes: { "tabindex": "-1" }, properties: { "attr.aria-modal": "_config.ariaModal", "id": "_config.id", "attr.role": "_config.role", "attr.aria-labelledby": "_config.ariaLabel ? null : _ariaLabelledByQueue[0]", "attr.aria-label": "_config.ariaLabel", "attr.aria-describedby": "_config.ariaDescribedBy || null", "class._mat-animation-noopable": "!_animationsEnabled", "class.mat-mdc-dialog-container-with-actions": "_actionSectionCount > 0" }, classAttribute: "mat-mdc-dialog-container mdc-dialog" }, usesInheritance: true, ngImport: i0, template: "<div class=\"mat-mdc-dialog-inner-container mdc-dialog__container\">\n <div class=\"mat-mdc-dialog-surface mdc-dialog__surface\">\n <ng-template cdkPortalOutlet />\n </div>\n</div>\n", styles: [".mat-mdc-dialog-container{width:100%;height:100%;display:block;box-sizing:border-box;max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;outline:0}.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-max-width, 560px);min-width:var(--mat-dialog-container-min-width, 280px)}@media(max-width: 599px){.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-small-max-width, calc(100vw - 32px))}}.mat-mdc-dialog-inner-container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;opacity:0;transition:opacity linear var(--mat-dialog-transition-duration, 0ms);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mdc-dialog--closing .mat-mdc-dialog-inner-container{transition:opacity 75ms linear;transform:none}.mdc-dialog--open .mat-mdc-dialog-inner-container{opacity:1}._mat-animation-noopable .mat-mdc-dialog-inner-container{transition:none}.mat-mdc-dialog-surface{display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;width:100%;height:100%;position:relative;overflow-y:auto;outline:0;transform:scale(0.8);transition:transform var(--mat-dialog-transition-duration, 0ms) cubic-bezier(0, 0, 0.2, 1);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;box-shadow:var(--mat-dialog-container-elevation-shadow, none);border-radius:var(--mdc-dialog-container-shape, var(--mat-app-corner-extra-large, 4px));background-color:var(--mdc-dialog-container-color, var(--mat-app-surface, white))}[dir=rtl] .mat-mdc-dialog-surface{text-align:right}.mdc-dialog--open .mat-mdc-dialog-surface,.mdc-dialog--closing .mat-mdc-dialog-surface{transform:none}._mat-animation-noopable .mat-mdc-dialog-surface{transition:none}.mat-mdc-dialog-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:\"\";pointer-events:none}.mat-mdc-dialog-title{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:var(--mat-dialog-headline-padding, 6px 24px 13px)}.mat-mdc-dialog-title::before{display:inline-block;width:0;height:40px;content:\"\";vertical-align:0}[dir=rtl] .mat-mdc-dialog-title{text-align:right}.mat-mdc-dialog-container .mat-mdc-dialog-title{color:var(--mdc-dialog-subhead-color, var(--mat-app-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mdc-dialog-subhead-font, var(--mat-app-headline-small-font, inherit));line-height:var(--mdc-dialog-subhead-line-height, var(--mat-app-headline-small-line-height, 1.5rem));font-size:var(--mdc-dialog-subhead-size, var(--mat-app-headline-small-size, 1rem));font-weight:var(--mdc-dialog-subhead-weight, var(--mat-app-headline-small-weight, 400));letter-spacing:var(--mdc-dialog-subhead-tracking, var(--mat-app-headline-small-tracking, 0.03125em))}.mat-mdc-dialog-content{display:block;flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;max-height:65vh}.mat-mdc-dialog-content>:first-child{margin-top:0}.mat-mdc-dialog-content>:last-child{margin-bottom:0}.mat-mdc-dialog-container .mat-mdc-dialog-content{color:var(--mdc-dialog-supporting-text-color, var(--mat-app-on-surface-variant, rgba(0, 0, 0, 0.6)));font-family:var(--mdc-dialog-supporting-text-font, var(--mat-app-body-medium-font, inherit));line-height:var(--mdc-dialog-supporting-text-line-height, var(--mat-app-body-medium-line-height, 1.5rem));font-size:var(--mdc-dialog-supporting-text-size, var(--mat-app-body-medium-size, 1rem));font-weight:var(--mdc-dialog-supporting-text-weight, var(--mat-app-body-medium-weight, 400));letter-spacing:var(--mdc-dialog-supporting-text-tracking, var(--mat-app-body-medium-tracking, 0.03125em))}.mat-mdc-dialog-container .mat-mdc-dialog-content{padding:var(--mat-dialog-content-padding, 20px 24px)}.mat-mdc-dialog-container-with-actions .mat-mdc-dialog-content{padding:var(--mat-dialog-with-actions-content-padding, 20px 24px 0)}.mat-mdc-dialog-container .mat-mdc-dialog-title+.mat-mdc-dialog-content{padding-top:0}.mat-mdc-dialog-actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0);padding:var(--mat-dialog-actions-padding, 16px 24px);justify-content:var(--mat-dialog-actions-alignment, flex-end)}@media(forced-colors: active){.mat-mdc-dialog-actions{border-top-color:CanvasText}}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-start,.mat-mdc-dialog-actions[align=start]{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}.mat-mdc-dialog-component-host{display:contents}"], dependencies: [{ kind: "directive", type: CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None }); }
253
249
  }
254
250
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogContainer, decorators: [{
@@ -265,17 +261,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3",
265
261
  '[class._mat-animation-noopable]': '!_animationsEnabled',
266
262
  '[class.mat-mdc-dialog-container-with-actions]': '_actionSectionCount > 0',
267
263
  }, template: "<div class=\"mat-mdc-dialog-inner-container mdc-dialog__container\">\n <div class=\"mat-mdc-dialog-surface mdc-dialog__surface\">\n <ng-template cdkPortalOutlet />\n </div>\n</div>\n", styles: [".mat-mdc-dialog-container{width:100%;height:100%;display:block;box-sizing:border-box;max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;outline:0}.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-max-width, 560px);min-width:var(--mat-dialog-container-min-width, 280px)}@media(max-width: 599px){.cdk-overlay-pane.mat-mdc-dialog-panel{max-width:var(--mat-dialog-container-small-max-width, calc(100vw - 32px))}}.mat-mdc-dialog-inner-container{display:flex;flex-direction:row;align-items:center;justify-content:space-around;box-sizing:border-box;height:100%;opacity:0;transition:opacity linear var(--mat-dialog-transition-duration, 0ms);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit}.mdc-dialog--closing .mat-mdc-dialog-inner-container{transition:opacity 75ms linear;transform:none}.mdc-dialog--open .mat-mdc-dialog-inner-container{opacity:1}._mat-animation-noopable .mat-mdc-dialog-inner-container{transition:none}.mat-mdc-dialog-surface{display:flex;flex-direction:column;flex-grow:0;flex-shrink:0;box-sizing:border-box;width:100%;height:100%;position:relative;overflow-y:auto;outline:0;transform:scale(0.8);transition:transform var(--mat-dialog-transition-duration, 0ms) cubic-bezier(0, 0, 0.2, 1);max-height:inherit;min-height:inherit;min-width:inherit;max-width:inherit;box-shadow:var(--mat-dialog-container-elevation-shadow, none);border-radius:var(--mdc-dialog-container-shape, var(--mat-app-corner-extra-large, 4px));background-color:var(--mdc-dialog-container-color, var(--mat-app-surface, white))}[dir=rtl] .mat-mdc-dialog-surface{text-align:right}.mdc-dialog--open .mat-mdc-dialog-surface,.mdc-dialog--closing .mat-mdc-dialog-surface{transform:none}._mat-animation-noopable .mat-mdc-dialog-surface{transition:none}.mat-mdc-dialog-surface::before{position:absolute;box-sizing:border-box;width:100%;height:100%;top:0;left:0;border:2px solid rgba(0,0,0,0);border-radius:inherit;content:\"\";pointer-events:none}.mat-mdc-dialog-title{display:block;position:relative;flex-shrink:0;box-sizing:border-box;margin:0 0 1px;padding:var(--mat-dialog-headline-padding, 6px 24px 13px)}.mat-mdc-dialog-title::before{display:inline-block;width:0;height:40px;content:\"\";vertical-align:0}[dir=rtl] .mat-mdc-dialog-title{text-align:right}.mat-mdc-dialog-container .mat-mdc-dialog-title{color:var(--mdc-dialog-subhead-color, var(--mat-app-on-surface, rgba(0, 0, 0, 0.87)));font-family:var(--mdc-dialog-subhead-font, var(--mat-app-headline-small-font, inherit));line-height:var(--mdc-dialog-subhead-line-height, var(--mat-app-headline-small-line-height, 1.5rem));font-size:var(--mdc-dialog-subhead-size, var(--mat-app-headline-small-size, 1rem));font-weight:var(--mdc-dialog-subhead-weight, var(--mat-app-headline-small-weight, 400));letter-spacing:var(--mdc-dialog-subhead-tracking, var(--mat-app-headline-small-tracking, 0.03125em))}.mat-mdc-dialog-content{display:block;flex-grow:1;box-sizing:border-box;margin:0;overflow:auto;max-height:65vh}.mat-mdc-dialog-content>:first-child{margin-top:0}.mat-mdc-dialog-content>:last-child{margin-bottom:0}.mat-mdc-dialog-container .mat-mdc-dialog-content{color:var(--mdc-dialog-supporting-text-color, var(--mat-app-on-surface-variant, rgba(0, 0, 0, 0.6)));font-family:var(--mdc-dialog-supporting-text-font, var(--mat-app-body-medium-font, inherit));line-height:var(--mdc-dialog-supporting-text-line-height, var(--mat-app-body-medium-line-height, 1.5rem));font-size:var(--mdc-dialog-supporting-text-size, var(--mat-app-body-medium-size, 1rem));font-weight:var(--mdc-dialog-supporting-text-weight, var(--mat-app-body-medium-weight, 400));letter-spacing:var(--mdc-dialog-supporting-text-tracking, var(--mat-app-body-medium-tracking, 0.03125em))}.mat-mdc-dialog-container .mat-mdc-dialog-content{padding:var(--mat-dialog-content-padding, 20px 24px)}.mat-mdc-dialog-container-with-actions .mat-mdc-dialog-content{padding:var(--mat-dialog-with-actions-content-padding, 20px 24px 0)}.mat-mdc-dialog-container .mat-mdc-dialog-title+.mat-mdc-dialog-content{padding-top:0}.mat-mdc-dialog-actions{display:flex;position:relative;flex-shrink:0;flex-wrap:wrap;align-items:center;justify-content:flex-end;box-sizing:border-box;min-height:52px;margin:0;padding:8px;border-top:1px solid rgba(0,0,0,0);padding:var(--mat-dialog-actions-padding, 16px 24px);justify-content:var(--mat-dialog-actions-alignment, flex-end)}@media(forced-colors: active){.mat-mdc-dialog-actions{border-top-color:CanvasText}}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-start,.mat-mdc-dialog-actions[align=start]{justify-content:start}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-center,.mat-mdc-dialog-actions[align=center]{justify-content:center}.mat-mdc-dialog-actions.mat-mdc-dialog-actions-align-end,.mat-mdc-dialog-actions[align=end]{justify-content:flex-end}.mat-mdc-dialog-actions .mat-button-base+.mat-button-base,.mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:8px}[dir=rtl] .mat-mdc-dialog-actions .mat-button-base+.mat-button-base,[dir=rtl] .mat-mdc-dialog-actions .mat-mdc-button-base+.mat-mdc-button-base{margin-left:0;margin-right:8px}.mat-mdc-dialog-component-host{display:contents}"] }]
268
- }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i1.FocusTrapFactory }, { type: undefined, decorators: [{
269
- type: Optional
270
- }, {
271
- type: Inject,
272
- args: [DOCUMENT]
273
- }] }, { type: MatDialogConfig }, { type: i1.InteractivityChecker }, { type: i0.NgZone }, { type: i1$1.OverlayRef }, { type: undefined, decorators: [{
274
- type: Optional
275
- }, {
276
- type: Inject,
277
- args: [ANIMATION_MODULE_TYPE]
278
- }] }, { type: i1.FocusMonitor }] });
264
+ }] });
279
265
  const TRANSITION_DURATION_PROPERTY = '--mat-dialog-transition-duration';
280
266
  // TODO(mmalerba): Remove this function after animation durations are required
281
267
  // to be numbers.
@@ -517,26 +503,12 @@ class MatDialog {
517
503
  const parent = this._parentDialog;
518
504
  return parent ? parent._getAfterAllClosed() : this._afterAllClosedAtThisLevel;
519
505
  }
520
- constructor(_overlay, injector,
521
- /**
522
- * @deprecated `_location` parameter to be removed.
523
- * @breaking-change 10.0.0
524
- */
525
- location, _defaultOptions, _scrollStrategy, _parentDialog,
526
- /**
527
- * @deprecated No longer used. To be removed.
528
- * @breaking-change 15.0.0
529
- */
530
- _overlayContainer,
531
- /**
532
- * @deprecated No longer used. To be removed.
533
- * @breaking-change 14.0.0
534
- */
535
- _animationMode) {
536
- this._overlay = _overlay;
537
- this._defaultOptions = _defaultOptions;
538
- this._scrollStrategy = _scrollStrategy;
539
- this._parentDialog = _parentDialog;
506
+ constructor() {
507
+ this._overlay = inject(Overlay);
508
+ this._defaultOptions = inject(MAT_DIALOG_DEFAULT_OPTIONS, { optional: true });
509
+ this._scrollStrategy = inject(MAT_DIALOG_SCROLL_STRATEGY);
510
+ this._parentDialog = inject(MatDialog, { optional: true, skipSelf: true });
511
+ this._dialog = inject(Dialog);
540
512
  this._openDialogsAtThisLevel = [];
541
513
  this._afterAllClosedAtThisLevel = new Subject();
542
514
  this._afterOpenedAtThisLevel = new Subject();
@@ -548,7 +520,6 @@ class MatDialog {
548
520
  this.afterAllClosed = defer(() => this.openDialogs.length
549
521
  ? this._getAfterAllClosed()
550
522
  : this._getAfterAllClosed().pipe(startWith(undefined)));
551
- this._dialog = injector.get(Dialog);
552
523
  this._dialogRefConstructor = MatDialogRef;
553
524
  this._dialogContainerType = MatDialogContainer;
554
525
  this._dialogDataToken = MAT_DIALOG_DATA;
@@ -634,32 +605,13 @@ class MatDialog {
634
605
  dialogs[i].close();
635
606
  }
636
607
  }
637
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialog, deps: [{ token: i1$1.Overlay }, { token: i0.Injector }, { token: i2.Location, optional: true }, { token: MAT_DIALOG_DEFAULT_OPTIONS, optional: true }, { token: MAT_DIALOG_SCROLL_STRATEGY }, { token: MatDialog, optional: true, skipSelf: true }, { token: i1$1.OverlayContainer }, { token: ANIMATION_MODULE_TYPE, optional: true }], target: i0.ɵɵFactoryTarget.Injectable }); }
608
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialog, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
638
609
  static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialog, providedIn: 'root' }); }
639
610
  }
640
611
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialog, decorators: [{
641
612
  type: Injectable,
642
613
  args: [{ providedIn: 'root' }]
643
- }], ctorParameters: () => [{ type: i1$1.Overlay }, { type: i0.Injector }, { type: i2.Location, decorators: [{
644
- type: Optional
645
- }] }, { type: MatDialogConfig, decorators: [{
646
- type: Optional
647
- }, {
648
- type: Inject,
649
- args: [MAT_DIALOG_DEFAULT_OPTIONS]
650
- }] }, { type: undefined, decorators: [{
651
- type: Inject,
652
- args: [MAT_DIALOG_SCROLL_STRATEGY]
653
- }] }, { type: MatDialog, decorators: [{
654
- type: Optional
655
- }, {
656
- type: SkipSelf
657
- }] }, { type: i1$1.OverlayContainer }, { type: undefined, decorators: [{
658
- type: Optional
659
- }, {
660
- type: Inject,
661
- args: [ANIMATION_MODULE_TYPE]
662
- }] }] });
614
+ }], ctorParameters: () => [] });
663
615
 
664
616
  /** Counter used to generate unique IDs for dialog elements. */
665
617
  let dialogElementUid = 0;
@@ -667,13 +619,10 @@ let dialogElementUid = 0;
667
619
  * Button that will close the current dialog.
668
620
  */
669
621
  class MatDialogClose {
670
- constructor(
671
- // The dialog title directive is always used in combination with a `MatDialogRef`.
672
- // tslint:disable-next-line: lightweight-tokens
673
- dialogRef, _elementRef, _dialog) {
674
- this.dialogRef = dialogRef;
675
- this._elementRef = _elementRef;
676
- this._dialog = _dialog;
622
+ constructor() {
623
+ this.dialogRef = inject(MatDialogRef, { optional: true });
624
+ this._elementRef = inject(ElementRef);
625
+ this._dialog = inject(MatDialog);
677
626
  /** Default to "button" to prevents accidental form submits. */
678
627
  this.type = 'button';
679
628
  }
@@ -700,7 +649,7 @@ class MatDialogClose {
700
649
  // the FocusMonitor won't detect any origin change, and will always output `program`.
701
650
  _closeDialogVia(this.dialogRef, event.screenX === 0 && event.screenY === 0 ? 'keyboard' : 'mouse', this.dialogResult);
702
651
  }
703
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogClose, deps: [{ token: MatDialogRef, optional: true }, { token: i0.ElementRef }, { token: MatDialog }], target: i0.ɵɵFactoryTarget.Directive }); }
652
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogClose, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
704
653
  static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.0.0-next.3", type: MatDialogClose, isStandalone: true, selector: "[mat-dialog-close], [matDialogClose]", inputs: { ariaLabel: ["aria-label", "ariaLabel"], type: "type", dialogResult: ["mat-dialog-close", "dialogResult"], _matDialogClose: ["matDialogClose", "_matDialogClose"] }, host: { listeners: { "click": "_onButtonClick($event)" }, properties: { "attr.aria-label": "ariaLabel || null", "attr.type": "type" } }, exportAs: ["matDialogClose"], usesOnChanges: true, ngImport: i0 }); }
705
654
  }
706
655
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogClose, decorators: [{
@@ -715,9 +664,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3",
715
664
  '[attr.type]': 'type',
716
665
  },
717
666
  }]
718
- }], ctorParameters: () => [{ type: MatDialogRef, decorators: [{
719
- type: Optional
720
- }] }, { type: i0.ElementRef }, { type: MatDialog }], propDecorators: { ariaLabel: [{
667
+ }], ctorParameters: () => [], propDecorators: { ariaLabel: [{
721
668
  type: Input,
722
669
  args: ['aria-label']
723
670
  }], type: [{
@@ -730,13 +677,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3",
730
677
  args: ['matDialogClose']
731
678
  }] } });
732
679
  class MatDialogLayoutSection {
733
- constructor(
734
- // The dialog title directive is always used in combination with a `MatDialogRef`.
735
- // tslint:disable-next-line: lightweight-tokens
736
- _dialogRef, _elementRef, _dialog) {
737
- this._dialogRef = _dialogRef;
738
- this._elementRef = _elementRef;
739
- this._dialog = _dialog;
680
+ constructor() {
681
+ this._dialogRef = inject(MatDialogRef, { optional: true });
682
+ this._elementRef = inject(ElementRef);
683
+ this._dialog = inject(MatDialog);
740
684
  }
741
685
  ngOnInit() {
742
686
  if (!this._dialogRef) {
@@ -758,15 +702,13 @@ class MatDialogLayoutSection {
758
702
  });
759
703
  }
760
704
  }
761
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogLayoutSection, deps: [{ token: MatDialogRef, optional: true }, { token: i0.ElementRef }, { token: MatDialog }], target: i0.ɵɵFactoryTarget.Directive }); }
705
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogLayoutSection, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
762
706
  static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.0.0-next.3", type: MatDialogLayoutSection, isStandalone: true, ngImport: i0 }); }
763
707
  }
764
708
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogLayoutSection, decorators: [{
765
709
  type: Directive,
766
710
  args: [{ standalone: true }]
767
- }], ctorParameters: () => [{ type: MatDialogRef, decorators: [{
768
- type: Optional
769
- }] }, { type: i0.ElementRef }, { type: MatDialog }] });
711
+ }], ctorParameters: () => [] });
770
712
  /**
771
713
  * Title of a dialog element. Stays fixed to the top of the dialog when scrolling.
772
714
  */
@@ -805,7 +747,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3",
805
747
  */
806
748
  class MatDialogContent {
807
749
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogContent, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
808
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.0.0-next.3", type: MatDialogContent, isStandalone: true, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]", host: { classAttribute: "mat-mdc-dialog-content mdc-dialog__content" }, hostDirectives: [{ directive: i3.CdkScrollable }], ngImport: i0 }); }
750
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.0.0-next.3", type: MatDialogContent, isStandalone: true, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]", host: { classAttribute: "mat-mdc-dialog-content mdc-dialog__content" }, hostDirectives: [{ directive: i1.CdkScrollable }], ngImport: i0 }); }
809
751
  }
810
752
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.0-next.3", ngImport: i0, type: MatDialogContent, decorators: [{
811
753
  type: Directive,