@angular/cdk 13.1.0 → 13.2.0-next.1

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 (191) hide show
  1. package/LICENSE +1 -1
  2. package/a11y/focus-trap/focus-trap.d.ts +2 -4
  3. package/accordion/accordion-item.d.ts +2 -4
  4. package/accordion/accordion.d.ts +1 -2
  5. package/drag-drop/directives/drag-handle.d.ts +1 -2
  6. package/drag-drop/directives/drag-preview.d.ts +1 -2
  7. package/drag-drop/directives/drag.d.ts +1 -2
  8. package/drag-drop/directives/drop-list-group.d.ts +1 -2
  9. package/drag-drop/directives/drop-list.d.ts +4 -8
  10. package/esm2020/a11y/a11y-module.mjs +5 -5
  11. package/esm2020/a11y/aria-describer/aria-describer.mjs +4 -4
  12. package/esm2020/a11y/focus-monitor/focus-monitor.mjs +8 -8
  13. package/esm2020/a11y/focus-trap/configurable-focus-trap-factory.mjs +4 -4
  14. package/esm2020/a11y/focus-trap/focus-trap-manager.mjs +4 -4
  15. package/esm2020/a11y/focus-trap/focus-trap.mjs +7 -7
  16. package/esm2020/a11y/high-contrast-mode/high-contrast-mode-detector.mjs +4 -4
  17. package/esm2020/a11y/input-modality/input-modality-detector.mjs +4 -4
  18. package/esm2020/a11y/interactivity-checker/interactivity-checker.mjs +4 -4
  19. package/esm2020/a11y/live-announcer/live-announcer.mjs +7 -7
  20. package/esm2020/accordion/accordion-item.mjs +4 -4
  21. package/esm2020/accordion/accordion-module.mjs +5 -5
  22. package/esm2020/accordion/accordion.mjs +4 -4
  23. package/esm2020/bidi/bidi-module.mjs +5 -5
  24. package/esm2020/bidi/dir.mjs +4 -4
  25. package/esm2020/bidi/directionality.mjs +4 -4
  26. package/esm2020/clipboard/clipboard-module.mjs +5 -5
  27. package/esm2020/clipboard/clipboard.mjs +4 -4
  28. package/esm2020/clipboard/copy-to-clipboard.mjs +4 -4
  29. package/esm2020/collections/unique-selection-dispatcher.mjs +4 -4
  30. package/esm2020/drag-drop/directives/drag-handle.mjs +4 -4
  31. package/esm2020/drag-drop/directives/drag-placeholder.mjs +4 -4
  32. package/esm2020/drag-drop/directives/drag-preview.mjs +4 -4
  33. package/esm2020/drag-drop/directives/drag.mjs +4 -4
  34. package/esm2020/drag-drop/directives/drop-list-group.mjs +4 -4
  35. package/esm2020/drag-drop/directives/drop-list.mjs +4 -4
  36. package/esm2020/drag-drop/drag-drop-module.mjs +5 -5
  37. package/esm2020/drag-drop/drag-drop-registry.mjs +4 -4
  38. package/esm2020/drag-drop/drag-drop.mjs +4 -4
  39. package/esm2020/layout/breakpoints-observer.mjs +4 -4
  40. package/esm2020/layout/layout-module.mjs +5 -5
  41. package/esm2020/layout/media-matcher.mjs +4 -4
  42. package/esm2020/observers/observe-content.mjs +14 -14
  43. package/esm2020/overlay/dispatchers/base-overlay-dispatcher.mjs +4 -4
  44. package/esm2020/overlay/dispatchers/overlay-keyboard-dispatcher.mjs +4 -4
  45. package/esm2020/overlay/dispatchers/overlay-outside-click-dispatcher.mjs +4 -4
  46. package/esm2020/overlay/fullscreen-overlay-container.mjs +4 -4
  47. package/esm2020/overlay/overlay-container.mjs +4 -4
  48. package/esm2020/overlay/overlay-directives.mjs +7 -7
  49. package/esm2020/overlay/overlay-module.mjs +5 -5
  50. package/esm2020/overlay/overlay.mjs +4 -4
  51. package/esm2020/overlay/position/flexible-connected-position-strategy.mjs +23 -15
  52. package/esm2020/overlay/position/overlay-position-builder.mjs +4 -4
  53. package/esm2020/overlay/scroll/scroll-strategy-options.mjs +4 -4
  54. package/esm2020/platform/platform-module.mjs +5 -5
  55. package/esm2020/platform/platform.mjs +4 -4
  56. package/esm2020/portal/portal-directives.mjs +18 -18
  57. package/esm2020/scrolling/fixed-size-virtual-scroll.mjs +4 -4
  58. package/esm2020/scrolling/scroll-dispatcher.mjs +4 -4
  59. package/esm2020/scrolling/scrollable.mjs +4 -4
  60. package/esm2020/scrolling/scrolling-module.mjs +9 -9
  61. package/esm2020/scrolling/viewport-ruler.mjs +4 -4
  62. package/esm2020/scrolling/virtual-for-of.mjs +4 -4
  63. package/esm2020/scrolling/virtual-scroll-viewport.mjs +4 -4
  64. package/esm2020/stepper/step-header.mjs +4 -4
  65. package/esm2020/stepper/step-label.mjs +4 -4
  66. package/esm2020/stepper/stepper-button.mjs +7 -7
  67. package/esm2020/stepper/stepper-module.mjs +5 -5
  68. package/esm2020/stepper/stepper.mjs +9 -9
  69. package/esm2020/table/can-stick.mjs +1 -1
  70. package/esm2020/table/cell.mjs +23 -28
  71. package/esm2020/table/coalesced-style-scheduler.mjs +4 -4
  72. package/esm2020/table/row.mjs +35 -28
  73. package/esm2020/table/table-module.mjs +5 -5
  74. package/esm2020/table/table.mjs +40 -23
  75. package/esm2020/table/text-column.mjs +4 -4
  76. package/esm2020/testing/harness-environment.mjs +9 -2
  77. package/esm2020/testing/selenium-webdriver/selenium-web-driver-harness-environment.mjs +3 -2
  78. package/esm2020/testing/testbed/testbed-harness-environment.mjs +3 -2
  79. package/esm2020/text-field/autofill.mjs +7 -7
  80. package/esm2020/text-field/autosize.mjs +10 -5
  81. package/esm2020/text-field/text-field-module.mjs +5 -5
  82. package/esm2020/tree/nested-node.mjs +4 -4
  83. package/esm2020/tree/node.mjs +4 -4
  84. package/esm2020/tree/outlet.mjs +4 -4
  85. package/esm2020/tree/padding.mjs +4 -4
  86. package/esm2020/tree/toggle.mjs +4 -4
  87. package/esm2020/tree/tree-module.mjs +5 -5
  88. package/esm2020/tree/tree.mjs +7 -7
  89. package/esm2020/version.mjs +1 -1
  90. package/fesm2015/a11y.mjs +41 -41
  91. package/fesm2015/a11y.mjs.map +1 -1
  92. package/fesm2015/accordion.mjs +10 -10
  93. package/fesm2015/accordion.mjs.map +1 -1
  94. package/fesm2015/bidi.mjs +10 -10
  95. package/fesm2015/bidi.mjs.map +1 -1
  96. package/fesm2015/cdk.mjs +1 -1
  97. package/fesm2015/cdk.mjs.map +1 -1
  98. package/fesm2015/clipboard.mjs +10 -10
  99. package/fesm2015/clipboard.mjs.map +1 -1
  100. package/fesm2015/collections.mjs +3 -3
  101. package/fesm2015/collections.mjs.map +1 -1
  102. package/fesm2015/drag-drop.mjs +28 -28
  103. package/fesm2015/drag-drop.mjs.map +1 -1
  104. package/fesm2015/layout.mjs +10 -10
  105. package/fesm2015/layout.mjs.map +1 -1
  106. package/fesm2015/observers.mjs +13 -13
  107. package/fesm2015/observers.mjs.map +1 -1
  108. package/fesm2015/overlay.mjs +56 -48
  109. package/fesm2015/overlay.mjs.map +1 -1
  110. package/fesm2015/platform.mjs +7 -7
  111. package/fesm2015/platform.mjs.map +1 -1
  112. package/fesm2015/portal.mjs +17 -17
  113. package/fesm2015/portal.mjs.map +1 -1
  114. package/fesm2015/scrolling.mjs +26 -26
  115. package/fesm2015/scrolling.mjs.map +1 -1
  116. package/fesm2015/stepper.mjs +24 -24
  117. package/fesm2015/stepper.mjs.map +1 -1
  118. package/fesm2015/table.mjs +104 -85
  119. package/fesm2015/table.mjs.map +1 -1
  120. package/fesm2015/testing/selenium-webdriver.mjs +2 -1
  121. package/fesm2015/testing/selenium-webdriver.mjs.map +1 -1
  122. package/fesm2015/testing/testbed.mjs +2 -1
  123. package/fesm2015/testing/testbed.mjs.map +1 -1
  124. package/fesm2015/testing.mjs +8 -1
  125. package/fesm2015/testing.mjs.map +1 -1
  126. package/fesm2015/text-field.mjs +19 -14
  127. package/fesm2015/text-field.mjs.map +1 -1
  128. package/fesm2015/tree.mjs +25 -25
  129. package/fesm2015/tree.mjs.map +1 -1
  130. package/fesm2020/a11y.mjs +41 -41
  131. package/fesm2020/a11y.mjs.map +1 -1
  132. package/fesm2020/accordion.mjs +10 -10
  133. package/fesm2020/accordion.mjs.map +1 -1
  134. package/fesm2020/bidi.mjs +10 -10
  135. package/fesm2020/bidi.mjs.map +1 -1
  136. package/fesm2020/cdk.mjs +1 -1
  137. package/fesm2020/cdk.mjs.map +1 -1
  138. package/fesm2020/clipboard.mjs +10 -10
  139. package/fesm2020/clipboard.mjs.map +1 -1
  140. package/fesm2020/collections.mjs +3 -3
  141. package/fesm2020/collections.mjs.map +1 -1
  142. package/fesm2020/drag-drop.mjs +28 -28
  143. package/fesm2020/drag-drop.mjs.map +1 -1
  144. package/fesm2020/layout.mjs +10 -10
  145. package/fesm2020/layout.mjs.map +1 -1
  146. package/fesm2020/observers.mjs +13 -13
  147. package/fesm2020/observers.mjs.map +1 -1
  148. package/fesm2020/overlay.mjs +56 -48
  149. package/fesm2020/overlay.mjs.map +1 -1
  150. package/fesm2020/platform.mjs +7 -7
  151. package/fesm2020/platform.mjs.map +1 -1
  152. package/fesm2020/portal.mjs +17 -17
  153. package/fesm2020/portal.mjs.map +1 -1
  154. package/fesm2020/scrolling.mjs +26 -26
  155. package/fesm2020/scrolling.mjs.map +1 -1
  156. package/fesm2020/stepper.mjs +24 -24
  157. package/fesm2020/stepper.mjs.map +1 -1
  158. package/fesm2020/table.mjs +104 -85
  159. package/fesm2020/table.mjs.map +1 -1
  160. package/fesm2020/testing/selenium-webdriver.mjs +2 -1
  161. package/fesm2020/testing/selenium-webdriver.mjs.map +1 -1
  162. package/fesm2020/testing/testbed.mjs +2 -1
  163. package/fesm2020/testing/testbed.mjs.map +1 -1
  164. package/fesm2020/testing.mjs +8 -1
  165. package/fesm2020/testing.mjs.map +1 -1
  166. package/fesm2020/text-field.mjs +19 -14
  167. package/fesm2020/text-field.mjs.map +1 -1
  168. package/fesm2020/tree.mjs +25 -25
  169. package/fesm2020/tree.mjs.map +1 -1
  170. package/observers/observe-content.d.ts +3 -5
  171. package/overlay/overlay-directives.d.ts +7 -12
  172. package/overlay/position/flexible-connected-position-strategy.d.ts +4 -2
  173. package/package.json +1 -1
  174. package/portal/portal-directives.d.ts +1 -2
  175. package/schematics/ng-add/index.js +1 -1
  176. package/schematics/ng-add/index.mjs +1 -1
  177. package/schematics/ng-update/migrations/tilde-import-v13/tilde-import-migration.js +5 -4
  178. package/schematics/ng-update/migrations/tilde-import-v13/tilde-import-migration.mjs +5 -4
  179. package/scrolling/fixed-size-virtual-scroll.d.ts +3 -6
  180. package/scrolling/virtual-for-of.d.ts +1 -2
  181. package/scrolling/virtual-scroll-viewport.d.ts +1 -2
  182. package/stepper/stepper.d.ts +6 -16
  183. package/table/cell.d.ts +1 -3
  184. package/table/row.d.ts +0 -3
  185. package/table/table.d.ts +15 -7
  186. package/testing/harness-environment.d.ts +3 -1
  187. package/testing/selenium-webdriver/selenium-web-driver-harness-environment.d.ts +2 -0
  188. package/testing/testbed/testbed-harness-environment.d.ts +2 -0
  189. package/text-field/autosize.d.ts +3 -6
  190. package/tree/padding.d.ts +2 -3
  191. package/tree/toggle.d.ts +1 -2
@@ -14,10 +14,10 @@ import * as i1 from '@angular/cdk/platform';
14
14
  */
15
15
  class LayoutModule {
16
16
  }
17
- LayoutModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: LayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
18
- LayoutModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: LayoutModule });
19
- LayoutModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: LayoutModule });
20
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: LayoutModule, decorators: [{
17
+ LayoutModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: LayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
18
+ LayoutModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: LayoutModule });
19
+ LayoutModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: LayoutModule });
20
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: LayoutModule, decorators: [{
21
21
  type: NgModule,
22
22
  args: [{}]
23
23
  }] });
@@ -57,9 +57,9 @@ class MediaMatcher {
57
57
  return this._matchMedia(query);
58
58
  }
59
59
  }
60
- MediaMatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: MediaMatcher, deps: [{ token: i1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
61
- MediaMatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: MediaMatcher, providedIn: 'root' });
62
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: MediaMatcher, decorators: [{
60
+ MediaMatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: MediaMatcher, deps: [{ token: i1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
61
+ MediaMatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: MediaMatcher, providedIn: 'root' });
62
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: MediaMatcher, decorators: [{
63
63
  type: Injectable,
64
64
  args: [{ providedIn: 'root' }]
65
65
  }], ctorParameters: function () { return [{ type: i1.Platform }]; } });
@@ -184,9 +184,9 @@ class BreakpointObserver {
184
184
  return output;
185
185
  }
186
186
  }
187
- BreakpointObserver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: BreakpointObserver, deps: [{ token: MediaMatcher }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
188
- BreakpointObserver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: BreakpointObserver, providedIn: 'root' });
189
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: BreakpointObserver, decorators: [{
187
+ BreakpointObserver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: BreakpointObserver, deps: [{ token: MediaMatcher }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
188
+ BreakpointObserver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: BreakpointObserver, providedIn: 'root' });
189
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: BreakpointObserver, decorators: [{
190
190
  type: Injectable,
191
191
  args: [{ providedIn: 'root' }]
192
192
  }], ctorParameters: function () { return [{ type: MediaMatcher }, { type: i0.NgZone }]; } });
@@ -1 +1 @@
1
- {"version":3,"file":"layout.mjs","sources":["../../../../../../src/cdk/layout/layout-module.ts","../../../../../../src/cdk/layout/media-matcher.ts","../../../../../../src/cdk/layout/breakpoints-observer.ts","../../../../../../src/cdk/layout/breakpoints.ts","../../../../../../src/cdk/layout/public-api.ts","../../../../../../src/cdk/layout/index.ts","../../../../../../src/cdk/layout/layout_public_index.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 */\nimport {NgModule} from '@angular/core';\n\n@NgModule({})\nexport class LayoutModule {}\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 */\nimport {Injectable} from '@angular/core';\nimport {Platform} from '@angular/cdk/platform';\n\n/** Global registry for all dynamically-created, injected media queries. */\nconst mediaQueriesForWebkitCompatibility: Set<string> = new Set<string>();\n\n/** Style tag that holds all of the dynamically-created media queries. */\nlet mediaQueryStyleNode: HTMLStyleElement | undefined;\n\n/** A utility for calling matchMedia queries. */\n@Injectable({providedIn: 'root'})\nexport class MediaMatcher {\n /** The internal matchMedia method to return back a MediaQueryList like object. */\n private _matchMedia: (query: string) => MediaQueryList;\n\n constructor(private _platform: Platform) {\n this._matchMedia =\n this._platform.isBrowser && window.matchMedia\n ? // matchMedia is bound to the window scope intentionally as it is an illegal invocation to\n // call it from a different scope.\n window.matchMedia.bind(window)\n : noopMatchMedia;\n }\n\n /**\n * Evaluates the given media query and returns the native MediaQueryList from which results\n * can be retrieved.\n * Confirms the layout engine will trigger for the selector query provided and returns the\n * MediaQueryList for the query provided.\n */\n matchMedia(query: string): MediaQueryList {\n if (this._platform.WEBKIT || this._platform.BLINK) {\n createEmptyStyleRule(query);\n }\n return this._matchMedia(query);\n }\n}\n\n/**\n * Creates an empty stylesheet that is used to work around browser inconsistencies related to\n * `matchMedia`. At the time of writing, it handles the following cases:\n * 1. On WebKit browsers, a media query has to have at least one rule in order for `matchMedia`\n * to fire. We work around it by declaring a dummy stylesheet with a `@media` declaration.\n * 2. In some cases Blink browsers will stop firing the `matchMedia` listener if none of the rules\n * inside the `@media` match existing elements on the page. We work around it by having one rule\n * targeting the `body`. See https://github.com/angular/components/issues/23546.\n */\nfunction createEmptyStyleRule(query: string) {\n if (mediaQueriesForWebkitCompatibility.has(query)) {\n return;\n }\n\n try {\n if (!mediaQueryStyleNode) {\n mediaQueryStyleNode = document.createElement('style');\n mediaQueryStyleNode.setAttribute('type', 'text/css');\n document.head!.appendChild(mediaQueryStyleNode);\n }\n\n if (mediaQueryStyleNode.sheet) {\n mediaQueryStyleNode.sheet.insertRule(`@media ${query} {body{ }}`, 0);\n mediaQueriesForWebkitCompatibility.add(query);\n }\n } catch (e) {\n console.error(e);\n }\n}\n\n/** No-op matchMedia replacement for non-browser platforms. */\nfunction noopMatchMedia(query: string): MediaQueryList {\n // Use `as any` here to avoid adding additional necessary properties for\n // the noop matcher.\n return {\n matches: query === 'all' || query === '',\n media: query,\n addListener: () => {},\n removeListener: () => {},\n } as any;\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 {coerceArray} from '@angular/cdk/coercion';\nimport {Injectable, NgZone, OnDestroy} from '@angular/core';\nimport {combineLatest, concat, Observable, Observer, Subject} from 'rxjs';\nimport {debounceTime, map, skip, startWith, take, takeUntil} from 'rxjs/operators';\nimport {MediaMatcher} from './media-matcher';\n\n/** The current state of a layout breakpoint. */\nexport interface BreakpointState {\n /** Whether the breakpoint is currently matching. */\n matches: boolean;\n /**\n * A key boolean pair for each query provided to the observe method,\n * with its current matched state.\n */\n breakpoints: {\n [key: string]: boolean;\n };\n}\n\n/** The current state of a layout breakpoint. */\ninterface InternalBreakpointState {\n /** Whether the breakpoint is currently matching. */\n matches: boolean;\n /** The media query being to be matched */\n query: string;\n}\n\ninterface Query {\n observable: Observable<InternalBreakpointState>;\n mql: MediaQueryList;\n}\n\n/** Utility for checking the matching state of @media queries. */\n@Injectable({providedIn: 'root'})\nexport class BreakpointObserver implements OnDestroy {\n /** A map of all media queries currently being listened for. */\n private _queries = new Map<string, Query>();\n /** A subject for all other observables to takeUntil based on. */\n private readonly _destroySubject = new Subject<void>();\n\n constructor(private _mediaMatcher: MediaMatcher, private _zone: NgZone) {}\n\n /** Completes the active subject, signalling to all other observables to complete. */\n ngOnDestroy() {\n this._destroySubject.next();\n this._destroySubject.complete();\n }\n\n /**\n * Whether one or more media queries match the current viewport size.\n * @param value One or more media queries to check.\n * @returns Whether any of the media queries match.\n */\n isMatched(value: string | readonly string[]): boolean {\n const queries = splitQueries(coerceArray(value));\n return queries.some(mediaQuery => this._registerQuery(mediaQuery).mql.matches);\n }\n\n /**\n * Gets an observable of results for the given queries that will emit new results for any changes\n * in matching of the given queries.\n * @param value One or more media queries to check.\n * @returns A stream of matches for the given queries.\n */\n observe(value: string | readonly string[]): Observable<BreakpointState> {\n const queries = splitQueries(coerceArray(value));\n const observables = queries.map(query => this._registerQuery(query).observable);\n\n let stateObservable = combineLatest(observables);\n // Emit the first state immediately, and then debounce the subsequent emissions.\n stateObservable = concat(\n stateObservable.pipe(take(1)),\n stateObservable.pipe(skip(1), debounceTime(0)),\n );\n return stateObservable.pipe(\n map(breakpointStates => {\n const response: BreakpointState = {\n matches: false,\n breakpoints: {},\n };\n breakpointStates.forEach(({matches, query}) => {\n response.matches = response.matches || matches;\n response.breakpoints[query] = matches;\n });\n return response;\n }),\n );\n }\n\n /** Registers a specific query to be listened for. */\n private _registerQuery(query: string): Query {\n // Only set up a new MediaQueryList if it is not already being listened for.\n if (this._queries.has(query)) {\n return this._queries.get(query)!;\n }\n\n const mql = this._mediaMatcher.matchMedia(query);\n\n // Create callback for match changes and add it is as a listener.\n const queryObservable = new Observable((observer: Observer<MediaQueryList>) => {\n // Listener callback methods are wrapped to be placed back in ngZone. Callbacks must be placed\n // back into the zone because matchMedia is only included in Zone.js by loading the\n // webapis-media-query.js file alongside the zone.js file. Additionally, some browsers do not\n // have MediaQueryList inherit from EventTarget, which causes inconsistencies in how Zone.js\n // patches it.\n const handler = (e: any) => this._zone.run(() => observer.next(e));\n mql.addListener(handler);\n\n return () => {\n mql.removeListener(handler);\n };\n }).pipe(\n startWith(mql),\n map(({matches}) => ({query, matches})),\n takeUntil(this._destroySubject),\n );\n\n // Add the MediaQueryList to the set of queries.\n const output = {observable: queryObservable, mql};\n this._queries.set(query, output);\n return output;\n }\n}\n\n/**\n * Split each query string into separate query strings if two queries are provided as comma\n * separated.\n */\nfunction splitQueries(queries: readonly string[]): readonly string[] {\n return queries\n .map(query => query.split(','))\n .reduce((a1, a2) => a1.concat(a2))\n .map(query => query.trim());\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// PascalCase is being used as Breakpoints is used like an enum.\n// tslint:disable-next-line:variable-name\nexport const Breakpoints = {\n XSmall: '(max-width: 599.98px)',\n Small: '(min-width: 600px) and (max-width: 959.98px)',\n Medium: '(min-width: 960px) and (max-width: 1279.98px)',\n Large: '(min-width: 1280px) and (max-width: 1919.98px)',\n XLarge: '(min-width: 1920px)',\n\n Handset:\n '(max-width: 599.98px) and (orientation: portrait), ' +\n '(max-width: 959.98px) and (orientation: landscape)',\n Tablet:\n '(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), ' +\n '(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)',\n Web:\n '(min-width: 840px) and (orientation: portrait), ' +\n '(min-width: 1280px) and (orientation: landscape)',\n\n HandsetPortrait: '(max-width: 599.98px) and (orientation: portrait)',\n TabletPortrait: '(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)',\n WebPortrait: '(min-width: 840px) and (orientation: portrait)',\n\n HandsetLandscape: '(max-width: 959.98px) and (orientation: landscape)',\n TabletLandscape: '(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)',\n WebLandscape: '(min-width: 1280px) and (orientation: landscape)',\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\nexport {LayoutModule} from './layout-module';\nexport {BreakpointObserver, BreakpointState} from './breakpoints-observer';\nexport {Breakpoints} from './breakpoints';\nexport {MediaMatcher} from './media-matcher';\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 */\nexport * from './public-api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;MAUa,YAAY;;gHAAZ,YAAY;iHAAZ,YAAY;iHAAZ,YAAY;kGAAZ,YAAY;kBADxB,QAAQ;mBAAC,EAAE;;;ACTZ;;;;;;;AAUA;AACA,MAAM,kCAAkC,GAAgB,IAAI,GAAG,EAAU,CAAC;AAE1E;AACA,IAA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AAe,EAAE,GAAG,EAAC,CAAC;QAClD,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;QACjC,OAAO,MAAM,CAAC;KACf;;sHAvFU,kBAAkB;0HAAlB,kBAAkB,cADN,MAAM;kGAClB,kBAAkB;kBAD9B,UAAU;mBAAC,EAAC,UAAU,EAAE,MAAM,EAAC;;AA2FhC;;;;AAIA,SAAS,YAAY,CAAC,OAA0B;IAC9C,OAAO,OAAO;SACX,GAAG,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;SAC9B,MAAM,CAAC,CAAC,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;SACjC,GAAG,CAAC,KAAK,IAAI,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;AAChC;;AC7IA;;;;;;;AAOA;AACA;MACa,WAAW,GAAG;IACzB,MAAM,EAAE,uBAAuB;IAC/B,KAAK,EAAE,8CAA8C;IACrD,MAAM,EAAE,+CAA+C;IACvD,KAAK,EAAE,gDAAgD;IACvD,MAAM,EAAE,qBAAqB;IAE7B,OAAO,EACL,qDAAqD;QACrD,oDAAoD;IACtD,MAAM,EACJ,4EAA4E;QAC5E,4EAA4E;IAC9E,GAAG,EACD,kDAAkD;QAClD,kDAAkD;IAEpD,eAAe,EAAE,mDAAmD;IACpE,cAAc,EAAE,0EAA0E;IAC1F,WAAW,EAAE,gDAAgD;IAE7D,gBAAgB,EAAE,oDAAoD;IACtE,eAAe,EAAE,4EAA4E;IAC7F,YAAY,EAAE,kDAAkD;;;AChClE;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
1
+ {"version":3,"file":"layout.mjs","sources":["../../../../../../src/cdk/layout/layout-module.ts","../../../../../../src/cdk/layout/media-matcher.ts","../../../../../../src/cdk/layout/breakpoints-observer.ts","../../../../../../src/cdk/layout/breakpoints.ts","../../../../../../src/cdk/layout/public-api.ts","../../../../../../src/cdk/layout/index.ts","../../../../../../src/cdk/layout/layout_public_index.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 */\nimport {NgModule} from '@angular/core';\n\n@NgModule({})\nexport class LayoutModule {}\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 */\nimport {Injectable} from '@angular/core';\nimport {Platform} from '@angular/cdk/platform';\n\n/** Global registry for all dynamically-created, injected media queries. */\nconst mediaQueriesForWebkitCompatibility: Set<string> = new Set<string>();\n\n/** Style tag that holds all of the dynamically-created media queries. */\nlet mediaQueryStyleNode: HTMLStyleElement | undefined;\n\n/** A utility for calling matchMedia queries. */\n@Injectable({providedIn: 'root'})\nexport class MediaMatcher {\n /** The internal matchMedia method to return back a MediaQueryList like object. */\n private _matchMedia: (query: string) => MediaQueryList;\n\n constructor(private _platform: Platform) {\n this._matchMedia =\n this._platform.isBrowser && window.matchMedia\n ? // matchMedia is bound to the window scope intentionally as it is an illegal invocation to\n // call it from a different scope.\n window.matchMedia.bind(window)\n : noopMatchMedia;\n }\n\n /**\n * Evaluates the given media query and returns the native MediaQueryList from which results\n * can be retrieved.\n * Confirms the layout engine will trigger for the selector query provided and returns the\n * MediaQueryList for the query provided.\n */\n matchMedia(query: string): MediaQueryList {\n if (this._platform.WEBKIT || this._platform.BLINK) {\n createEmptyStyleRule(query);\n }\n return this._matchMedia(query);\n }\n}\n\n/**\n * Creates an empty stylesheet that is used to work around browser inconsistencies related to\n * `matchMedia`. At the time of writing, it handles the following cases:\n * 1. On WebKit browsers, a media query has to have at least one rule in order for `matchMedia`\n * to fire. We work around it by declaring a dummy stylesheet with a `@media` declaration.\n * 2. In some cases Blink browsers will stop firing the `matchMedia` listener if none of the rules\n * inside the `@media` match existing elements on the page. We work around it by having one rule\n * targeting the `body`. See https://github.com/angular/components/issues/23546.\n */\nfunction createEmptyStyleRule(query: string) {\n if (mediaQueriesForWebkitCompatibility.has(query)) {\n return;\n }\n\n try {\n if (!mediaQueryStyleNode) {\n mediaQueryStyleNode = document.createElement('style');\n mediaQueryStyleNode.setAttribute('type', 'text/css');\n document.head!.appendChild(mediaQueryStyleNode);\n }\n\n if (mediaQueryStyleNode.sheet) {\n mediaQueryStyleNode.sheet.insertRule(`@media ${query} {body{ }}`, 0);\n mediaQueriesForWebkitCompatibility.add(query);\n }\n } catch (e) {\n console.error(e);\n }\n}\n\n/** No-op matchMedia replacement for non-browser platforms. */\nfunction noopMatchMedia(query: string): MediaQueryList {\n // Use `as any` here to avoid adding additional necessary properties for\n // the noop matcher.\n return {\n matches: query === 'all' || query === '',\n media: query,\n addListener: () => {},\n removeListener: () => {},\n } as any;\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 {coerceArray} from '@angular/cdk/coercion';\nimport {Injectable, NgZone, OnDestroy} from '@angular/core';\nimport {combineLatest, concat, Observable, Observer, Subject} from 'rxjs';\nimport {debounceTime, map, skip, startWith, take, takeUntil} from 'rxjs/operators';\nimport {MediaMatcher} from './media-matcher';\n\n/** The current state of a layout breakpoint. */\nexport interface BreakpointState {\n /** Whether the breakpoint is currently matching. */\n matches: boolean;\n /**\n * A key boolean pair for each query provided to the observe method,\n * with its current matched state.\n */\n breakpoints: {\n [key: string]: boolean;\n };\n}\n\n/** The current state of a layout breakpoint. */\ninterface InternalBreakpointState {\n /** Whether the breakpoint is currently matching. */\n matches: boolean;\n /** The media query being to be matched */\n query: string;\n}\n\ninterface Query {\n observable: Observable<InternalBreakpointState>;\n mql: MediaQueryList;\n}\n\n/** Utility for checking the matching state of @media queries. */\n@Injectable({providedIn: 'root'})\nexport class BreakpointObserver implements OnDestroy {\n /** A map of all media queries currently being listened for. */\n private _queries = new Map<string, Query>();\n /** A subject for all other observables to takeUntil based on. */\n private readonly _destroySubject = new Subject<void>();\n\n constructor(private _mediaMatcher: MediaMatcher, private _zone: NgZone) {}\n\n /** Completes the active subject, signalling to all other observables to complete. */\n ngOnDestroy() {\n this._destroySubject.next();\n this._destroySubject.complete();\n }\n\n /**\n * Whether one or more media queries match the current viewport size.\n * @param value One or more media queries to check.\n * @returns Whether any of the media queries match.\n */\n isMatched(value: string | readonly string[]): boolean {\n const queries = splitQueries(coerceArray(value));\n return queries.some(mediaQuery => this._registerQuery(mediaQuery).mql.matches);\n }\n\n /**\n * Gets an observable of results for the given queries that will emit new results for any changes\n * in matching of the given queries.\n * @param value One or more media queries to check.\n * @returns A stream of matches for the given queries.\n */\n observe(value: string | readonly string[]): Observable<BreakpointState> {\n const queries = splitQueries(coerceArray(value));\n const observables = queries.map(query => this._registerQuery(query).observable);\n\n let stateObservable = combineLatest(observables);\n // Emit the first state immediately, and then debounce the subsequent emissions.\n stateObservable = concat(\n stateObservable.pipe(take(1)),\n stateObservable.pipe(skip(1), debounceTime(0)),\n );\n return stateObservable.pipe(\n map(breakpointStates => {\n const response: BreakpointState = {\n matches: false,\n breakpoints: {},\n };\n breakpointStates.forEach(({matches, query}) => {\n response.matches = response.matches || matches;\n response.breakpoints[query] = matches;\n });\n return response;\n }),\n );\n }\n\n /** Registers a specific query to be listened for. */\n private _registerQuery(query: string): Query {\n // Only set up a new MediaQueryList if it is not already being listened for.\n if (this._queries.has(query)) {\n return this._queries.get(query)!;\n }\n\n const mql = this._mediaMatcher.matchMedia(query);\n\n // Create callback for match changes and add it is as a listener.\n const queryObservable = new Observable((observer: Observer<MediaQueryList>) => {\n // Listener callback methods are wrapped to be placed back in ngZone. Callbacks must be placed\n // back into the zone because matchMedia is only included in Zone.js by loading the\n // webapis-media-query.js file alongside the zone.js file. Additionally, some browsers do not\n // have MediaQueryList inherit from EventTarget, which causes inconsistencies in how Zone.js\n // patches it.\n const handler = (e: any) => this._zone.run(() => observer.next(e));\n mql.addListener(handler);\n\n return () => {\n mql.removeListener(handler);\n };\n }).pipe(\n startWith(mql),\n map(({matches}) => ({query, matches})),\n takeUntil(this._destroySubject),\n );\n\n // Add the MediaQueryList to the set of queries.\n const output = {observable: queryObservable, mql};\n this._queries.set(query, output);\n return output;\n }\n}\n\n/**\n * Split each query string into separate query strings if two queries are provided as comma\n * separated.\n */\nfunction splitQueries(queries: readonly string[]): readonly string[] {\n return queries\n .map(query => query.split(','))\n .reduce((a1, a2) => a1.concat(a2))\n .map(query => query.trim());\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// PascalCase is being used as Breakpoints is used like an enum.\n// tslint:disable-next-line:variable-name\nexport const Breakpoints = {\n XSmall: '(max-width: 599.98px)',\n Small: '(min-width: 600px) and (max-width: 959.98px)',\n Medium: '(min-width: 960px) and (max-width: 1279.98px)',\n Large: '(min-width: 1280px) and (max-width: 1919.98px)',\n XLarge: '(min-width: 1920px)',\n\n Handset:\n '(max-width: 599.98px) and (orientation: portrait), ' +\n '(max-width: 959.98px) and (orientation: landscape)',\n Tablet:\n '(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait), ' +\n '(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)',\n Web:\n '(min-width: 840px) and (orientation: portrait), ' +\n '(min-width: 1280px) and (orientation: landscape)',\n\n HandsetPortrait: '(max-width: 599.98px) and (orientation: portrait)',\n TabletPortrait: '(min-width: 600px) and (max-width: 839.98px) and (orientation: portrait)',\n WebPortrait: '(min-width: 840px) and (orientation: portrait)',\n\n HandsetLandscape: '(max-width: 959.98px) and (orientation: landscape)',\n TabletLandscape: '(min-width: 960px) and (max-width: 1279.98px) and (orientation: landscape)',\n WebLandscape: '(min-width: 1280px) and (orientation: landscape)',\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\nexport {LayoutModule} from './layout-module';\nexport {BreakpointObserver, BreakpointState} from './breakpoints-observer';\nexport {Breakpoints} from './breakpoints';\nexport {MediaMatcher} from './media-matcher';\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 */\nexport * from './public-api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;MAUa,YAAY;;yGAAZ,YAAY;0GAAZ,YAAY;0GAAZ,YAAY;2FAAZ,YAAY;kBADxB,QAAQ;mBAAC,EAAE;;;ACTZ;;;;;;;AAUA;AACA,MAAM,kCAAkC,GAAgB,IAAI,GAAG,EAAU,CAAC;AAE1E;AACA,IAAI,mBAAiD,CAAC;AAEtD;MAEa,YAAY;IAIvB,YAAoB,SAAmB;QAAnB,cAAS,GAAT,SAAS,CAAU;QACrC,IAAI,CAAC,WAAW;YACd,IAAI,CAAC,SAAS,CAAC,SAAS,IAAI,MAAM,CAAC,UAAU;;;oBAGzC,MAAM,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC;kBAC9B,cAAc,CAAC;KACtB;;;;;;;IAQD,UAAU,CAAC,KAAa;QACtB,IAAI,IAAI,CAAC,SAAS,CAAC,MAAM,IAAI,IAAI,CAAC,SAAS,CAAC,KAAK,EAAE;YACjD,oBAAoB,CAAC,KAAK,CAAC,CAAC;SAC7B;QACD,OAAO,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;KAChC;;yGAxBU,YAAY;6GAAZ,YAAY,cADA,MAAM;2FAClB,YAAY;kBADxB,UAAU;mBAAC,EAAC,UAAU,EAAE,MAAM,EAAC;;AA4BhC;;;;;;;;;AASA,SAAS,oBAAoB,CAAC,KAAa;IACzC,IAAI,kCAAkC,CAAC,GAAG,CAAC,KAAK,CAAC,EAAE;QACjD,OAAO;KACR;IAED,IAAI;QACF,IAAI,C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AO,EACL,qDAAqD;QACrD,oDAAoD;IACtD,MAAM,EACJ,4EAA4E;QAC5E,4EAA4E;IAC9E,GAAG,EACD,kDAAkD;QAClD,kDAAkD;IAEpD,eAAe,EAAE,mDAAmD;IACpE,cAAc,EAAE,0EAA0E;IAC1F,WAAW,EAAE,gDAAgD;IAE7D,gBAAgB,EAAE,oDAAoD;IACtE,eAAe,EAAE,4EAA4E;IAC7F,YAAY,EAAE,kDAAkD;;;AChClE;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
@@ -20,9 +20,9 @@ class MutationObserverFactory {
20
20
  return typeof MutationObserver === 'undefined' ? null : new MutationObserver(callback);
21
21
  }
22
22
  }
23
- MutationObserverFactory.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: MutationObserverFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
24
- MutationObserverFactory.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: MutationObserverFactory, providedIn: 'root' });
25
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: MutationObserverFactory, decorators: [{
23
+ MutationObserverFactory.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: MutationObserverFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
24
+ MutationObserverFactory.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: MutationObserverFactory, providedIn: 'root' });
25
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: MutationObserverFactory, decorators: [{
26
26
  type: Injectable,
27
27
  args: [{ providedIn: 'root' }]
28
28
  }] });
@@ -93,9 +93,9 @@ class ContentObserver {
93
93
  }
94
94
  }
95
95
  }
96
- ContentObserver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ContentObserver, deps: [{ token: MutationObserverFactory }], target: i0.ɵɵFactoryTarget.Injectable });
97
- ContentObserver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ContentObserver, providedIn: 'root' });
98
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ContentObserver, decorators: [{
96
+ ContentObserver.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ContentObserver, deps: [{ token: MutationObserverFactory }], target: i0.ɵɵFactoryTarget.Injectable });
97
+ ContentObserver.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ContentObserver, providedIn: 'root' });
98
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ContentObserver, decorators: [{
99
99
  type: Injectable,
100
100
  args: [{ providedIn: 'root' }]
101
101
  }], ctorParameters: function () { return [{ type: MutationObserverFactory }]; } });
@@ -155,9 +155,9 @@ class CdkObserveContent {
155
155
  this._currentSubscription?.unsubscribe();
156
156
  }
157
157
  }
158
- CdkObserveContent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: CdkObserveContent, deps: [{ token: ContentObserver }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
159
- CdkObserveContent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0-next.3", type: CdkObserveContent, selector: "[cdkObserveContent]", inputs: { disabled: ["cdkObserveContentDisabled", "disabled"], debounce: "debounce" }, outputs: { event: "cdkObserveContent" }, exportAs: ["cdkObserveContent"], ngImport: i0 });
160
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: CdkObserveContent, decorators: [{
158
+ CdkObserveContent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: CdkObserveContent, deps: [{ token: ContentObserver }, { token: i0.ElementRef }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
159
+ CdkObserveContent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0", type: CdkObserveContent, selector: "[cdkObserveContent]", inputs: { disabled: ["cdkObserveContentDisabled", "disabled"], debounce: "debounce" }, outputs: { event: "cdkObserveContent" }, exportAs: ["cdkObserveContent"], ngImport: i0 });
160
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: CdkObserveContent, decorators: [{
161
161
  type: Directive,
162
162
  args: [{
163
163
  selector: '[cdkObserveContent]',
@@ -174,10 +174,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3",
174
174
  }] } });
175
175
  class ObserversModule {
176
176
  }
177
- ObserversModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ObserversModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
178
- ObserversModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ObserversModule, declarations: [CdkObserveContent], exports: [CdkObserveContent] });
179
- ObserversModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ObserversModule, providers: [MutationObserverFactory] });
180
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ObserversModule, decorators: [{
177
+ ObserversModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ObserversModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
178
+ ObserversModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ObserversModule, declarations: [CdkObserveContent], exports: [CdkObserveContent] });
179
+ ObserversModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ObserversModule, providers: [MutationObserverFactory] });
180
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ObserversModule, decorators: [{
181
181
  type: NgModule,
182
182
  args: [{
183
183
  exports: [CdkObserveContent],
@@ -1 +1 @@
1
- {"version":3,"file":"observers.mjs","sources":["../../../../../../src/cdk/observers/observe-content.ts","../../../../../../src/cdk/observers/public-api.ts","../../../../../../src/cdk/observers/index.ts","../../../../../../src/cdk/observers/observers_public_index.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 coerceBooleanProperty,\n coerceNumberProperty,\n coerceElement,\n BooleanInput,\n NumberInput,\n} from '@angular/cdk/coercion';\nimport {\n AfterContentInit,\n Directive,\n ElementRef,\n EventEmitter,\n Injectable,\n Input,\n NgModule,\n NgZone,\n OnDestroy,\n Output,\n} from '@angular/core';\nimport {Observable, Subject, Subscription, Observer} from 'rxjs';\nimport {debounceTime} from 'rxjs/operators';\n\n/**\n * Factory that creates a new MutationObserver and allows us to stub it out in unit tests.\n * @docs-private\n */\n@Injectable({providedIn: 'root'})\nexport class MutationObserverFactory {\n create(callback: MutationCallback): MutationObserver | null {\n return typeof MutationObserver === 'undefined' ? null : new MutationObserver(callback);\n }\n}\n\n/** An injectable service that allows watching elements for changes to their content. */\n@Injectable({providedIn: 'root'})\nexport class ContentObserver implements OnDestroy {\n /** Keeps track of the existing MutationObservers so they can be reused. */\n private _observedElements = new Map<\n Element,\n {\n observer: MutationObserver | null;\n readonly stream: Subject<MutationRecord[]>;\n count: number;\n }\n >();\n\n constructor(private _mutationObserverFactory: MutationObserverFactory) {}\n\n ngOnDestroy() {\n this._observedElements.forEach((_, element) => this._cleanupObserver(element));\n }\n\n /**\n * Observe content changes on an element.\n * @param element The element to observe for content changes.\n */\n observe(element: Element): Observable<MutationRecord[]>;\n\n /**\n * Observe content changes on an element.\n * @param element The element to observe for content changes.\n */\n observe(element: ElementRef<Element>): Observable<MutationRecord[]>;\n\n observe(elementOrRef: Element | ElementRef<Element>): Observable<MutationRecord[]> {\n const element = coerceElement(elementOrRef);\n\n return new Observable((observer: Observer<MutationRecord[]>) => {\n const stream = this._observeElement(element);\n const subscription = stream.subscribe(observer);\n\n return () => {\n subscription.unsubscribe();\n this._unobserveElement(element);\n };\n });\n }\n\n /**\n * Observes the given element by using the existing MutationObserver if available, or creating a\n * new one if not.\n */\n private _observeElement(element: Element): Subject<MutationRecord[]> {\n if (!this._observedElements.has(element)) {\n const stream = new Subject<MutationRecord[]>();\n const observer = this._mutationObserverFactory.create(mutations => stream.next(mutations));\n if (observer) {\n observer.observe(element, {\n characterData: true,\n childList: true,\n subtree: true,\n });\n }\n this._observedElements.set(element, {observer, stream, count: 1});\n } else {\n this._observedElements.get(element)!.count++;\n }\n return this._observedElements.get(element)!.stream;\n }\n\n /**\n * Un-observes the given element and cleans up the underlying MutationObserver if nobody else is\n * observing this element.\n */\n private _unobserveElement(element: Element) {\n if (this._observedElements.has(element)) {\n this._observedElements.get(element)!.count--;\n if (!this._observedElements.get(element)!.count) {\n this._cleanupObserver(element);\n }\n }\n }\n\n /** Clean up the underlying MutationObserver for the specified element. */\n private _cleanupObserver(element: Element) {\n if (this._observedElements.has(element)) {\n const {observer, stream} = this._observedElements.get(element)!;\n if (observer) {\n observer.disconnect();\n }\n stream.complete();\n this._observedElements.delete(element);\n }\n }\n}\n\n/**\n * Directive that triggers a callback whenever the content of\n * its associated element has changed.\n */\n@Directive({\n selector: '[cdkObserveContent]',\n exportAs: 'cdkObserveContent',\n})\nexport class CdkObserveContent implements AfterContentInit, OnDestroy {\n /** Event emitted for each change in the element's content. */\n @Output('cdkObserveContent') readonly event = new EventEmitter<MutationRecord[]>();\n\n /**\n * Whether observing content is disabled. This option can be used\n * to disconnect the underlying MutationObserver until it is needed.\n */\n @Input('cdkObserveContentDisabled')\n get disabled() {\n return this._disabled;\n }\n set disabled(value: any) {\n this._disabled = coerceBooleanProperty(value);\n this._disabled ? this._unsubscribe() : this._subscribe();\n }\n private _disabled = false;\n\n /** Debounce interval for emitting the changes. */\n @Input()\n get debounce(): number {\n return this._debounce;\n }\n set debounce(value: number) {\n this._debounce = coerceNumberProperty(value);\n this._subscribe();\n }\n private _debounce: number;\n\n private _currentSubscription: Subscription | null = null;\n\n constructor(\n private _contentObserver: ContentObserver,\n private _elementRef: ElementRef<HTMLElement>,\n private _ngZone: NgZone,\n ) {}\n\n ngAfterContentInit() {\n if (!this._currentSubscription && !this.disabled) {\n this._subscribe();\n }\n }\n\n ngOnDestroy() {\n this._unsubscribe();\n }\n\n private _subscribe() {\n this._unsubscribe();\n const stream = this._contentObserver.observe(this._elementRef);\n\n // TODO(mmalerba): We shouldn't be emitting on this @Output() outside the zone.\n // Consider brining it back inside the zone next time we're making breaking changes.\n // Bringing it back inside can cause things like infinite change detection loops and changed\n // after checked errors if people's code isn't handling it properly.\n this._ngZone.runOutsideAngular(() => {\n this._currentSubscription = (\n this.debounce ? stream.pipe(debounceTime(this.debounce)) : stream\n ).subscribe(this.event);\n });\n }\n\n private _unsubscribe() {\n this._currentSubscription?.unsubscribe();\n }\n\n static ngAcceptInputType_disabled: BooleanInput;\n static ngAcceptInputType_debounce: NumberInput;\n}\n\n@NgModule({\n exports: [CdkObserveContent],\n declarations: [CdkObserveContent],\n providers: [MutationObserverFactory],\n})\nexport class ObserversModule {}\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\nexport * from './observe-content';\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\nexport * from './public-api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAAA;;;;;;;AA8BA;;;;MAKa,uBAAuB;IAClC,MAAM,CAAC,QAA0B;QAC/B,OAAO,OAAO,gBAAgB,KAAK,WAAW,GAAG,IAAI,GAAG,IAAI,gBAAgB,CAAC,QAAQ,CAAC,CAAC;KACxF;;2HAHU,uBAAuB;+HAAvB,uBAAuB,cADX,MAAM;kGAClB,uBAAuB;kBADnC,UAAU;mBAAC,EAAC,UAAU,EAAE,MAAM,EAAC;;AAOhC;MAEa,eAAe;IAW1B,YAAoB,wBAAiD;QAAjD,6BAAwB,GAAxB,wBAAwB,CAAyB;;QAT7D,sBAAiB,GAAG,IAAI,GAAG,EAOhC,CAAC;KAEqE;IAEzE,WAAW;QACT,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC,CAAC;KAChF;IAcD,OAAO,CAAC,YAA2C;QACjD,MAAM,OAAO,GAAG,aAAa,CAAC,YAAY,CAAC,CAAC;QAE5C,OAAO,IAAI,UAAU,CAAC,CAAC,QAAoC;YACzD,MAAM,MAAM,GAAG,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC,CAAC;YAC7C,MAAM,YAAY,GAAG,MAAM,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;YAEhD,OAAO;gBACL,YAAY,CAAC,WAAW,EAAE,CAAC;gBAC3B,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAC;aACjC,CAAC;SACH,CAAC,CAAC;KACJ;;;;;IAMO,eAAe,CAAC,OAAgB;QACtC,IAAI,CAAC,IAAI,CAAC,iBAAiB,CAAC,GAAG,CAAC,OAAO,CAAC,EA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B,IAAI,CAAC,YAAY,EAAE,CAAC;QACpB,MAAM,MAAM,GAAG,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;;;;;QAM/D,IAAI,CAAC,OAAO,CAAC,iBAAiB,CAAC;YAC7B,IAAI,CAAC,oBAAoB,GAAG,CAC1B,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,GAAG,MAAM,EACjE,SAAS,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;SACzB,CAAC,CAAC;KACJ;IAEO,YAAY;QAClB,IAAI,CAAC,oBAAoB,EAAE,WAAW,EAAE,CAAC;KAC1C;;qHAhEU,iBAAiB,kBAgCA,eAAe;yGAhChC,iBAAiB;kGAAjB,iBAAiB;kBAJ7B,SAAS;mBAAC;oBACT,QAAQ,EAAE,qBAAqB;oBAC/B,QAAQ,EAAE,mBAAmB;iBAC9B;0DAiC6B,eAAe,wEA9BL,KAAK;sBAA1C,MAAM;uBAAC,mBAAmB;gBAOvB,QAAQ;sBADX,KAAK;uBAAC,2BAA2B;gBAY9B,QAAQ;sBADX,KAAK;;MAwDK,eAAe;;mHAAf,eAAe;oHAAf,eAAe,iBA3Ef,iBAAiB,aAAjB,iBAAiB;oHA2EjB,eAAe,aAFf,CAAC,uBAAuB,CAAC;kGAEzB,eAAe;kBAL3B,QAAQ;mBAAC;oBACR,OAAO,EAAE,CAAC,iBAAiB,CAAC;oBAC5B,YAAY,EAAE,CAAC,iBAAiB,CAAC;oBACjC,SAAS,EAAE,CAAC,uBAAuB,CAAC;iBACrC;;;ACxND;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
1
+ {"version":3,"file":"observers.mjs","sources":["../../../../../../src/cdk/observers/observe-content.ts","../../../../../../src/cdk/observers/public-api.ts","../../../../../../src/cdk/observers/index.ts","../../../../../../src/cdk/observers/observers_public_index.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 coerceBooleanProperty,\n coerceNumberProperty,\n coerceElement,\n BooleanInput,\n NumberInput,\n} from '@angular/cdk/coercion';\nimport {\n AfterContentInit,\n Directive,\n ElementRef,\n EventEmitter,\n Injectable,\n Input,\n NgModule,\n NgZone,\n OnDestroy,\n Output,\n} from '@angular/core';\nimport {Observable, Subject, Subscription, Observer} from 'rxjs';\nimport {debounceTime} from 'rxjs/operators';\n\n/**\n * Factory that creates a new MutationObserver and allows us to stub it out in unit tests.\n * @docs-private\n */\n@Injectable({providedIn: 'root'})\nexport class MutationObserverFactory {\n create(callback: MutationCallback): MutationObserver | null {\n return typeof MutationObserver === 'undefined' ? null : new MutationObserver(callback);\n }\n}\n\n/** An injectable service that allows watching elements for changes to their content. */\n@Injectable({providedIn: 'root'})\nexport class ContentObserver implements OnDestroy {\n /** Keeps track of the existing MutationObservers so they can be reused. */\n private _observedElements = new Map<\n Element,\n {\n observer: MutationObserver | null;\n readonly stream: Subject<MutationRecord[]>;\n count: number;\n }\n >();\n\n constructor(private _mutationObserverFactory: MutationObserverFactory) {}\n\n ngOnDestroy() {\n this._observedElements.forEach((_, element) => this._cleanupObserver(element));\n }\n\n /**\n * Observe content changes on an element.\n * @param element The element to observe for content changes.\n */\n observe(element: Element): Observable<MutationRecord[]>;\n\n /**\n * Observe content changes on an element.\n * @param element The element to observe for content changes.\n */\n observe(element: ElementRef<Element>): Observable<MutationRecord[]>;\n\n observe(elementOrRef: Element | ElementRef<Element>): Observable<MutationRecord[]> {\n const element = coerceElement(elementOrRef);\n\n return new Observable((observer: Observer<MutationRecord[]>) => {\n const stream = this._observeElement(element);\n const subscription = stream.subscribe(observer);\n\n return () => {\n subscription.unsubscribe();\n this._unobserveElement(element);\n };\n });\n }\n\n /**\n * Observes the given element by using the existing MutationObserver if available, or creating a\n * new one if not.\n */\n private _observeElement(element: Element): Subject<MutationRecord[]> {\n if (!this._observedElements.has(element)) {\n const stream = new Subject<MutationRecord[]>();\n const observer = this._mutationObserverFactory.create(mutations => stream.next(mutations));\n if (observer) {\n observer.observe(element, {\n characterData: true,\n childList: true,\n subtree: true,\n });\n }\n this._observedElements.set(element, {observer, stream, count: 1});\n } else {\n this._observedElements.get(element)!.count++;\n }\n return this._observedElements.get(element)!.stream;\n }\n\n /**\n * Un-observes the given element and cleans up the underlying MutationObserver if nobody else is\n * observing this element.\n */\n private _unobserveElement(element: Element) {\n if (this._observedElements.has(element)) {\n this._observedElements.get(element)!.count--;\n if (!this._observedElements.get(element)!.count) {\n this._cleanupObserver(element);\n }\n }\n }\n\n /** Clean up the underlying MutationObserver for the specified element. */\n private _cleanupObserver(element: Element) {\n if (this._observedElements.has(element)) {\n const {observer, stream} = this._observedElements.get(element)!;\n if (observer) {\n observer.disconnect();\n }\n stream.complete();\n this._observedElements.delete(element);\n }\n }\n}\n\n/**\n * Directive that triggers a callback whenever the content of\n * its associated element has changed.\n */\n@Directive({\n selector: '[cdkObserveContent]',\n exportAs: 'cdkObserveContent',\n})\nexport class CdkObserveContent implements AfterContentInit, OnDestroy {\n /** Event emitted for each change in the element's content. */\n @Output('cdkObserveContent') readonly event = new EventEmitter<MutationRecord[]>();\n\n /**\n * Whether observing content is disabled. This option can be used\n * to disconnect the underlying MutationObserver until it is needed.\n */\n @Input('cdkObserveContentDisabled')\n get disabled(): boolean {\n return this._disabled;\n }\n set disabled(value: BooleanInput) {\n this._disabled = coerceBooleanProperty(value);\n this._disabled ? this._unsubscribe() : this._subscribe();\n }\n private _disabled = false;\n\n /** Debounce interval for emitting the changes. */\n @Input()\n get debounce(): number {\n return this._debounce;\n }\n set debounce(value: NumberInput) {\n this._debounce = coerceNumberProperty(value);\n this._subscribe();\n }\n private _debounce: number;\n\n private _currentSubscription: Subscription | null = null;\n\n constructor(\n private _contentObserver: ContentObserver,\n private _elementRef: ElementRef<HTMLElement>,\n private _ngZone: NgZone,\n ) {}\n\n ngAfterContentInit() {\n if (!this._currentSubscription && !this.disabled) {\n this._subscribe();\n }\n }\n\n ngOnDestroy() {\n this._unsubscribe();\n }\n\n private _subscribe() {\n this._unsubscribe();\n const stream = this._contentObserver.observe(this._elementRef);\n\n // TODO(mmalerba): We shouldn't be emitting on this @Output() outside the zone.\n // Consider brining it back inside the zone next time we're making breaking changes.\n // Bringing it back inside can cause things like infinite change detection loops and changed\n // after checked errors if people's code isn't handling it properly.\n this._ngZone.runOutsideAngular(() => {\n this._currentSubscription = (\n this.debounce ? stream.pipe(debounceTime(this.debounce)) : stream\n ).subscribe(this.event);\n });\n }\n\n private _unsubscribe() {\n this._currentSubscription?.unsubscribe();\n }\n}\n\n@NgModule({\n exports: [CdkObserveContent],\n declarations: [CdkObserveContent],\n providers: [MutationObserverFactory],\n})\nexport class ObserversModule {}\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\nexport * from './observe-content';\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\nexport * from './public-api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;AAAA;;;;;;;AA8BA;;;;MAKa,uBAAuB;IAClC,MAAM,CAAC,QAA0B;QAC/B,OAAO,OAAO,gBAAgB,KAAK,WAAW,GAAG,IAAI,GAAG,IAAI,gBAAgB,CAAC,QAAQ,CAAC,CAAC;KACxF;;oHAHU,uBAAuB;wHAAvB,uBAAuB,cADX,MAAM;2FAClB,uBAAuB;kBADnC,UAAU;mBAAC,EAAC,UAAU,EAAE,MAAM,EAAC;;AAOhC;MAEa,eAAe;IAW1B,YAAoB,wBAAiD;QAAjD,6BAAwB,GAAxB,wBAAwB,CAAyB;;QAT7D,sBAAiB,GAAG,IAAI,GAAG,EAOhC,C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AqB;oBAC/B,QAAQ,EAAE,mBAAmB;iBAC9B;0DAiC6B,eAAe,wEA9BL,KAAK;sBAA1C,MAAM;uBAAC,mBAAmB;gBAOvB,QAAQ;sBADX,KAAK;uBAAC,2BAA2B;gBAY9B,QAAQ;sBADX,KAAK;;MAqDK,eAAe;;4GAAf,eAAe;6GAAf,eAAe,iBAxEf,iBAAiB,aAAjB,iBAAiB;6GAwEjB,eAAe,aAFf,CAAC,uBAAuB,CAAC;2FAEzB,eAAe;kBAL3B,QAAQ;mBAAC;oBACR,OAAO,EAAE,CAAC,iBAAiB,CAAC;oBAC5B,YAAY,EAAE,CAAC,iBAAiB,CAAC;oBACjC,SAAS,EAAE,CAAC,uBAAuB,CAAC;iBACrC;;;ACrND;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
@@ -319,9 +319,9 @@ class ScrollStrategyOptions {
319
319
  this._document = document;
320
320
  }
321
321
  }
322
- ScrollStrategyOptions.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ScrollStrategyOptions, deps: [{ token: i1.ScrollDispatcher }, { token: i1.ViewportRuler }, { token: i0.NgZone }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
323
- ScrollStrategyOptions.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ScrollStrategyOptions, providedIn: 'root' });
324
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: ScrollStrategyOptions, decorators: [{
322
+ ScrollStrategyOptions.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ScrollStrategyOptions, deps: [{ token: i1.ScrollDispatcher }, { token: i1.ViewportRuler }, { token: i0.NgZone }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
323
+ ScrollStrategyOptions.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ScrollStrategyOptions, providedIn: 'root' });
324
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: ScrollStrategyOptions, decorators: [{
325
325
  type: Injectable,
326
326
  args: [{ providedIn: 'root' }]
327
327
  }], ctorParameters: function () { return [{ type: i1.ScrollDispatcher }, { type: i1.ViewportRuler }, { type: i0.NgZone }, { type: undefined, decorators: [{
@@ -508,9 +508,9 @@ class BaseOverlayDispatcher {
508
508
  }
509
509
  }
510
510
  }
511
- BaseOverlayDispatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: BaseOverlayDispatcher, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
512
- BaseOverlayDispatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: BaseOverlayDispatcher, providedIn: 'root' });
513
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: BaseOverlayDispatcher, decorators: [{
511
+ BaseOverlayDispatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: BaseOverlayDispatcher, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
512
+ BaseOverlayDispatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: BaseOverlayDispatcher, providedIn: 'root' });
513
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: BaseOverlayDispatcher, decorators: [{
514
514
  type: Injectable,
515
515
  args: [{ providedIn: 'root' }]
516
516
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
@@ -567,9 +567,9 @@ class OverlayKeyboardDispatcher extends BaseOverlayDispatcher {
567
567
  }
568
568
  }
569
569
  }
570
- OverlayKeyboardDispatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayKeyboardDispatcher, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
571
- OverlayKeyboardDispatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayKeyboardDispatcher, providedIn: 'root' });
572
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayKeyboardDispatcher, decorators: [{
570
+ OverlayKeyboardDispatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayKeyboardDispatcher, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
571
+ OverlayKeyboardDispatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayKeyboardDispatcher, providedIn: 'root' });
572
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayKeyboardDispatcher, decorators: [{
573
573
  type: Injectable,
574
574
  args: [{ providedIn: 'root' }]
575
575
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
@@ -678,9 +678,9 @@ class OverlayOutsideClickDispatcher extends BaseOverlayDispatcher {
678
678
  }
679
679
  }
680
680
  }
681
- OverlayOutsideClickDispatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayOutsideClickDispatcher, deps: [{ token: DOCUMENT }, { token: i1$1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
682
- OverlayOutsideClickDispatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayOutsideClickDispatcher, providedIn: 'root' });
683
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayOutsideClickDispatcher, decorators: [{
681
+ OverlayOutsideClickDispatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayOutsideClickDispatcher, deps: [{ token: DOCUMENT }, { token: i1$1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
682
+ OverlayOutsideClickDispatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayOutsideClickDispatcher, providedIn: 'root' });
683
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayOutsideClickDispatcher, decorators: [{
684
684
  type: Injectable,
685
685
  args: [{ providedIn: 'root' }]
686
686
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
@@ -754,9 +754,9 @@ class OverlayContainer {
754
754
  this._containerElement = container;
755
755
  }
756
756
  }
757
- OverlayContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayContainer, deps: [{ token: DOCUMENT }, { token: i1$1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
758
- OverlayContainer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayContainer, providedIn: 'root' });
759
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayContainer, decorators: [{
757
+ OverlayContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayContainer, deps: [{ token: DOCUMENT }, { token: i1$1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
758
+ OverlayContainer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayContainer, providedIn: 'root' });
759
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayContainer, decorators: [{
760
760
  type: Injectable,
761
761
  args: [{ providedIn: 'root' }]
762
762
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
@@ -1278,15 +1278,17 @@ class FlexibleConnectedPositionStrategy {
1278
1278
  this._clearPanelClasses();
1279
1279
  this._resetOverlayElementStyles();
1280
1280
  this._resetBoundingBoxStyles();
1281
- // We need the bounding rects for the origin and the overlay to determine how to position
1281
+ // We need the bounding rects for the origin, the overlay and the container to determine how to position
1282
1282
  // the overlay relative to the origin.
1283
1283
  // We use the viewport rect to determine whether a position would go off-screen.
1284
1284
  this._viewportRect = this._getNarrowedViewportRect();
1285
1285
  this._originRect = this._getOriginRect();
1286
1286
  this._overlayRect = this._pane.getBoundingClientRect();
1287
+ this._containerRect = this._overlayContainer.getContainerElement().getBoundingClientRect();
1287
1288
  const originRect = this._originRect;
1288
1289
  const overlayRect = this._overlayRect;
1289
1290
  const viewportRect = this._viewportRect;
1291
+ const containerRect = this._containerRect;
1290
1292
  // Positions where the overlay will fit with flexible dimensions.
1291
1293
  const flexibleFits = [];
1292
1294
  // Fallback if none of the preferred positions fit within the viewport.
@@ -1295,7 +1297,7 @@ class FlexibleConnectedPositionStrategy {
1295
1297
  // If a good fit is found, it will be applied immediately.
1296
1298
  for (let pos of this._preferredPositions) {
1297
1299
  // Get the exact (x, y) coordinate for the point-of-origin on the origin element.
1298
- let originPoint = this._getOriginPoint(originRect, pos);
1300
+ let originPoint = this._getOriginPoint(originRect, containerRect, pos);
1299
1301
  // From that point-of-origin, get the exact (x, y) coordinate for the top-left corner of the
1300
1302
  // overlay in this position. We use the top-left corner for calculations and later translate
1301
1303
  // this into an appropriate (top, left, bottom, right) style.
@@ -1402,8 +1404,9 @@ class FlexibleConnectedPositionStrategy {
1402
1404
  this._originRect = this._getOriginRect();
1403
1405
  this._overlayRect = this._pane.getBoundingClientRect();
1404
1406
  this._viewportRect = this._getNarrowedViewportRect();
1407
+ this._containerRect = this._overlayContainer.getContainerElement().getBoundingClientRect();
1405
1408
  const lastPosition = this._lastPosition || this._preferredPositions[0];
1406
- const originPoint = this._getOriginPoint(this._originRect, lastPosition);
1409
+ const originPoint = this._getOriginPoint(this._originRect, this._containerRect, lastPosition);
1407
1410
  this._applyPosition(lastPosition, originPoint);
1408
1411
  }
1409
1412
  }
@@ -1505,7 +1508,7 @@ class FlexibleConnectedPositionStrategy {
1505
1508
  /**
1506
1509
  * Gets the (x, y) coordinate of a connection point on the origin based on a relative position.
1507
1510
  */
1508
- _getOriginPoint(originRect, pos) {
1511
+ _getOriginPoint(originRect, containerRect, pos) {
1509
1512
  let x;
1510
1513
  if (pos.originX == 'center') {
1511
1514
  // Note: when centering we should always use the `left`
@@ -1517,6 +1520,11 @@ class FlexibleConnectedPositionStrategy {
1517
1520
  const endX = this._isRtl() ? originRect.left : originRect.right;
1518
1521
  x = pos.originX == 'start' ? startX : endX;
1519
1522
  }
1523
+ // When zooming in Safari the container rectangle contains negative values for the position
1524
+ // and we need to re-add them to the calculated coordinates.
1525
+ if (containerRect.left < 0) {
1526
+ x -= containerRect.left;
1527
+ }
1520
1528
  let y;
1521
1529
  if (pos.originY == 'center') {
1522
1530
  y = originRect.top + originRect.height / 2;
@@ -1524,6 +1532,14 @@ class FlexibleConnectedPositionStrategy {
1524
1532
  else {
1525
1533
  y = pos.originY == 'top' ? originRect.top : originRect.bottom;
1526
1534
  }
1535
+ // Normally the containerRect's top value would be zero, however when the overlay is attached to an input
1536
+ // (e.g. in an autocomplete), mobile browsers will shift everything in order to put the input in the middle
1537
+ // of the screen and to make space for the virtual keyboard. We need to account for this offset,
1538
+ // otherwise our positioning will be thrown off.
1539
+ // Additionally, when zooming in Safari this fixes the vertical position.
1540
+ if (containerRect.top < 0) {
1541
+ y -= containerRect.top;
1542
+ }
1527
1543
  return { x, y };
1528
1544
  }
1529
1545
  /**
@@ -1590,7 +1606,7 @@ class FlexibleConnectedPositionStrategy {
1590
1606
  /**
1591
1607
  * Whether the overlay can fit within the viewport when it may resize either its width or height.
1592
1608
  * @param fit How well the overlay fits in the viewport at some position.
1593
- * @param point The (x, y) coordinates of the overlat at some position.
1609
+ * @param point The (x, y) coordinates of the overlay at some position.
1594
1610
  * @param viewport The geometry of the viewport.
1595
1611
  */
1596
1612
  _canFitWithFlexibleDimensions(fit, point, viewport) {
@@ -1611,7 +1627,7 @@ class FlexibleConnectedPositionStrategy {
1611
1627
  * right and bottom).
1612
1628
  *
1613
1629
  * @param start Starting point from which the overlay is pushed.
1614
- * @param overlay Dimensions of the overlay.
1630
+ * @param rawOverlayRect Dimensions of the overlay.
1615
1631
  * @param scrollPosition Current viewport scroll position.
1616
1632
  * @returns The point at which to position the overlay after pushing. This is effectively a new
1617
1633
  * originPoint.
@@ -1906,14 +1922,6 @@ class FlexibleConnectedPositionStrategy {
1906
1922
  if (this._isPushed) {
1907
1923
  overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);
1908
1924
  }
1909
- let virtualKeyboardOffset = this._overlayContainer
1910
- .getContainerElement()
1911
- .getBoundingClientRect().top;
1912
- // Normally this would be zero, however when the overlay is attached to an input (e.g. in an
1913
- // autocomplete), mobile browsers will shift everything in order to put the input in the middle
1914
- // of the screen and to make space for the virtual keyboard. We need to account for this offset,
1915
- // otherwise our positioning will be thrown off.
1916
- overlayPoint.y -= virtualKeyboardOffset;
1917
1925
  // We want to set either `top` or `bottom` based on whether the overlay wants to appear
1918
1926
  // above or below the origin and the direction in which the element will expand.
1919
1927
  if (position.overlayY === 'bottom') {
@@ -2349,9 +2357,9 @@ class OverlayPositionBuilder {
2349
2357
  return new FlexibleConnectedPositionStrategy(origin, this._viewportRuler, this._document, this._platform, this._overlayContainer);
2350
2358
  }
2351
2359
  }
2352
- OverlayPositionBuilder.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayPositionBuilder, deps: [{ token: i1.ViewportRuler }, { token: DOCUMENT }, { token: i1$1.Platform }, { token: OverlayContainer }], target: i0.ɵɵFactoryTarget.Injectable });
2353
- OverlayPositionBuilder.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayPositionBuilder, providedIn: 'root' });
2354
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayPositionBuilder, decorators: [{
2360
+ OverlayPositionBuilder.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayPositionBuilder, deps: [{ token: i1.ViewportRuler }, { token: DOCUMENT }, { token: i1$1.Platform }, { token: OverlayContainer }], target: i0.ɵɵFactoryTarget.Injectable });
2361
+ OverlayPositionBuilder.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayPositionBuilder, providedIn: 'root' });
2362
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayPositionBuilder, decorators: [{
2355
2363
  type: Injectable,
2356
2364
  args: [{ providedIn: 'root' }]
2357
2365
  }], ctorParameters: function () { return [{ type: i1.ViewportRuler }, { type: undefined, decorators: [{
@@ -2450,9 +2458,9 @@ class Overlay {
2450
2458
  return new DomPortalOutlet(pane, this._componentFactoryResolver, this._appRef, this._injector, this._document);
2451
2459
  }
2452
2460
  }
2453
- Overlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: Overlay, deps: [{ token: ScrollStrategyOptions }, { token: OverlayContainer }, { token: i0.ComponentFactoryResolver }, { token: OverlayPositionBuilder }, { token: OverlayKeyboardDispatcher }, { token: i0.Injector }, { token: i0.NgZone }, { token: DOCUMENT }, { token: i5.Directionality }, { token: i6.Location }, { token: OverlayOutsideClickDispatcher }], target: i0.ɵɵFactoryTarget.Injectable });
2454
- Overlay.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: Overlay });
2455
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: Overlay, decorators: [{
2461
+ Overlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: Overlay, deps: [{ token: ScrollStrategyOptions }, { token: OverlayContainer }, { token: i0.ComponentFactoryResolver }, { token: OverlayPositionBuilder }, { token: OverlayKeyboardDispatcher }, { token: i0.Injector }, { token: i0.NgZone }, { token: DOCUMENT }, { token: i5.Directionality }, { token: i6.Location }, { token: OverlayOutsideClickDispatcher }], target: i0.ɵɵFactoryTarget.Injectable });
2462
+ Overlay.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: Overlay });
2463
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: Overlay, decorators: [{
2456
2464
  type: Injectable
2457
2465
  }], ctorParameters: function () { return [{ type: ScrollStrategyOptions }, { type: OverlayContainer }, { type: i0.ComponentFactoryResolver }, { type: OverlayPositionBuilder }, { type: OverlayKeyboardDispatcher }, { type: i0.Injector }, { type: i0.NgZone }, { type: undefined, decorators: [{
2458
2466
  type: Inject,
@@ -2506,9 +2514,9 @@ class CdkOverlayOrigin {
2506
2514
  this.elementRef = elementRef;
2507
2515
  }
2508
2516
  }
2509
- CdkOverlayOrigin.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: CdkOverlayOrigin, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
2510
- CdkOverlayOrigin.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0-next.3", type: CdkOverlayOrigin, selector: "[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]", exportAs: ["cdkOverlayOrigin"], ngImport: i0 });
2511
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: CdkOverlayOrigin, decorators: [{
2517
+ CdkOverlayOrigin.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: CdkOverlayOrigin, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
2518
+ CdkOverlayOrigin.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0", type: CdkOverlayOrigin, selector: "[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]", exportAs: ["cdkOverlayOrigin"], ngImport: i0 });
2519
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: CdkOverlayOrigin, decorators: [{
2512
2520
  type: Directive,
2513
2521
  args: [{
2514
2522
  selector: '[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]',
@@ -2773,9 +2781,9 @@ class CdkConnectedOverlay {
2773
2781
  this._positionSubscription.unsubscribe();
2774
2782
  }
2775
2783
  }
2776
- CdkConnectedOverlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: CdkConnectedOverlay, deps: [{ token: Overlay }, { token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY }, { token: i5.Directionality, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
2777
- CdkConnectedOverlay.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0-next.3", type: CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: { origin: ["cdkConnectedOverlayOrigin", "origin"], positions: ["cdkConnectedOverlayPositions", "positions"], positionStrategy: ["cdkConnectedOverlayPositionStrategy", "positionStrategy"], offsetX: ["cdkConnectedOverlayOffsetX", "offsetX"], offsetY: ["cdkConnectedOverlayOffsetY", "offsetY"], width: ["cdkConnectedOverlayWidth", "width"], height: ["cdkConnectedOverlayHeight", "height"], minWidth: ["cdkConnectedOverlayMinWidth", "minWidth"], minHeight: ["cdkConnectedOverlayMinHeight", "minHeight"], backdropClass: ["cdkConnectedOverlayBackdropClass", "backdropClass"], panelClass: ["cdkConnectedOverlayPanelClass", "panelClass"], viewportMargin: ["cdkConnectedOverlayViewportMargin", "viewportMargin"], scrollStrategy: ["cdkConnectedOverlayScrollStrategy", "scrollStrategy"], open: ["cdkConnectedOverlayOpen", "open"], disableClose: ["cdkConnectedOverlayDisableClose", "disableClose"], transformOriginSelector: ["cdkConnectedOverlayTransformOriginOn", "transformOriginSelector"], hasBackdrop: ["cdkConnectedOverlayHasBackdrop", "hasBackdrop"], lockPosition: ["cdkConnectedOverlayLockPosition", "lockPosition"], flexibleDimensions: ["cdkConnectedOverlayFlexibleDimensions", "flexibleDimensions"], growAfterOpen: ["cdkConnectedOverlayGrowAfterOpen", "growAfterOpen"], push: ["cdkConnectedOverlayPush", "push"] }, outputs: { backdropClick: "backdropClick", positionChange: "positionChange", attach: "attach", detach: "detach", overlayKeydown: "overlayKeydown", overlayOutsideClick: "overlayOutsideClick" }, exportAs: ["cdkConnectedOverlay"], usesOnChanges: true, ngImport: i0 });
2778
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: CdkConnectedOverlay, decorators: [{
2784
+ CdkConnectedOverlay.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: CdkConnectedOverlay, deps: [{ token: Overlay }, { token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY }, { token: i5.Directionality, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
2785
+ CdkConnectedOverlay.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.1.0", type: CdkConnectedOverlay, selector: "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", inputs: { origin: ["cdkConnectedOverlayOrigin", "origin"], positions: ["cdkConnectedOverlayPositions", "positions"], positionStrategy: ["cdkConnectedOverlayPositionStrategy", "positionStrategy"], offsetX: ["cdkConnectedOverlayOffsetX", "offsetX"], offsetY: ["cdkConnectedOverlayOffsetY", "offsetY"], width: ["cdkConnectedOverlayWidth", "width"], height: ["cdkConnectedOverlayHeight", "height"], minWidth: ["cdkConnectedOverlayMinWidth", "minWidth"], minHeight: ["cdkConnectedOverlayMinHeight", "minHeight"], backdropClass: ["cdkConnectedOverlayBackdropClass", "backdropClass"], panelClass: ["cdkConnectedOverlayPanelClass", "panelClass"], viewportMargin: ["cdkConnectedOverlayViewportMargin", "viewportMargin"], scrollStrategy: ["cdkConnectedOverlayScrollStrategy", "scrollStrategy"], open: ["cdkConnectedOverlayOpen", "open"], disableClose: ["cdkConnectedOverlayDisableClose", "disableClose"], transformOriginSelector: ["cdkConnectedOverlayTransformOriginOn", "transformOriginSelector"], hasBackdrop: ["cdkConnectedOverlayHasBackdrop", "hasBackdrop"], lockPosition: ["cdkConnectedOverlayLockPosition", "lockPosition"], flexibleDimensions: ["cdkConnectedOverlayFlexibleDimensions", "flexibleDimensions"], growAfterOpen: ["cdkConnectedOverlayGrowAfterOpen", "growAfterOpen"], push: ["cdkConnectedOverlayPush", "push"] }, outputs: { backdropClick: "backdropClick", positionChange: "positionChange", attach: "attach", detach: "detach", overlayKeydown: "overlayKeydown", overlayOutsideClick: "overlayOutsideClick" }, exportAs: ["cdkConnectedOverlay"], usesOnChanges: true, ngImport: i0 });
2786
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: CdkConnectedOverlay, decorators: [{
2779
2787
  type: Directive,
2780
2788
  args: [{
2781
2789
  selector: '[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]',
@@ -2882,10 +2890,10 @@ const CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER = {
2882
2890
  */
2883
2891
  class OverlayModule {
2884
2892
  }
2885
- OverlayModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2886
- OverlayModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayModule, declarations: [CdkConnectedOverlay, CdkOverlayOrigin], imports: [BidiModule, PortalModule, ScrollingModule], exports: [CdkConnectedOverlay, CdkOverlayOrigin, ScrollingModule] });
2887
- OverlayModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayModule, providers: [Overlay, CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER], imports: [[BidiModule, PortalModule, ScrollingModule], ScrollingModule] });
2888
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: OverlayModule, decorators: [{
2893
+ OverlayModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2894
+ OverlayModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayModule, declarations: [CdkConnectedOverlay, CdkOverlayOrigin], imports: [BidiModule, PortalModule, ScrollingModule], exports: [CdkConnectedOverlay, CdkOverlayOrigin, ScrollingModule] });
2895
+ OverlayModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayModule, providers: [Overlay, CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER], imports: [[BidiModule, PortalModule, ScrollingModule], ScrollingModule] });
2896
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: OverlayModule, decorators: [{
2889
2897
  type: NgModule,
2890
2898
  args: [{
2891
2899
  imports: [BidiModule, PortalModule, ScrollingModule],
@@ -2981,9 +2989,9 @@ class FullscreenOverlayContainer extends OverlayContainer {
2981
2989
  null);
2982
2990
  }
2983
2991
  }
2984
- FullscreenOverlayContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: FullscreenOverlayContainer, deps: [{ token: DOCUMENT }, { token: i1$1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
2985
- FullscreenOverlayContainer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: FullscreenOverlayContainer, providedIn: 'root' });
2986
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0-next.3", ngImport: i0, type: FullscreenOverlayContainer, decorators: [{
2992
+ FullscreenOverlayContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: FullscreenOverlayContainer, deps: [{ token: DOCUMENT }, { token: i1$1.Platform }], target: i0.ɵɵFactoryTarget.Injectable });
2993
+ FullscreenOverlayContainer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: FullscreenOverlayContainer, providedIn: 'root' });
2994
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.0", ngImport: i0, type: FullscreenOverlayContainer, decorators: [{
2987
2995
  type: Injectable,
2988
2996
  args: [{ providedIn: 'root' }]
2989
2997
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{