source: trip-planner-front/node_modules/@angular/cdk/bundles/cdk-overlay.umd.js.map@ eed0bf8

Last change on this file since eed0bf8 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 241.3 KB
Line 
1{"version":3,"file":"cdk-overlay.umd.js","sources":["../../../../../external/npm/node_modules/tslib/tslib.es6.js","../../../../../src/cdk/overlay/scroll/block-scroll-strategy.ts","../../../../../src/cdk/overlay/scroll/scroll-strategy.ts","../../../../../src/cdk/overlay/scroll/close-scroll-strategy.ts","../../../../../src/cdk/overlay/scroll/noop-scroll-strategy.ts","../../../../../src/cdk/overlay/position/scroll-clip.ts","../../../../../src/cdk/overlay/scroll/reposition-scroll-strategy.ts","../../../../../src/cdk/overlay/scroll/scroll-strategy-options.ts","../../../../../src/cdk/overlay/scroll/index.ts","../../../../../src/cdk/overlay/overlay-config.ts","../../../../../src/cdk/overlay/position/connected-position.ts","../../../../../src/cdk/overlay/dispatchers/base-overlay-dispatcher.ts","../../../../../src/cdk/overlay/dispatchers/overlay-keyboard-dispatcher.ts","../../../../../src/cdk/overlay/dispatchers/overlay-outside-click-dispatcher.ts","../../../../../src/cdk/overlay/overlay-container.ts","../../../../../src/cdk/overlay/overlay-ref.ts","../../../../../src/cdk/overlay/position/flexible-connected-position-strategy.ts","../../../../../src/cdk/overlay/position/connected-position-strategy.ts","../../../../../src/cdk/overlay/position/global-position-strategy.ts","../../../../../src/cdk/overlay/position/overlay-position-builder.ts","../../../../../src/cdk/overlay/overlay.ts","../../../../../src/cdk/overlay/overlay-directives.ts","../../../../../src/cdk/overlay/overlay-module.ts","../../../../../src/cdk/overlay/dispatchers/index.ts","../../../../../src/cdk/overlay/fullscreen-overlay-container.ts","../../../../../src/cdk/overlay/public-api.ts","../../../../../src/cdk/overlay/index.ts"],"sourcesContent":["/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n if (typeof b !== \"function\" && b !== null)\r\n throw new TypeError(\"Class extends value \" + String(b) + \" is not a constructor or null\");\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport var __createBinding = Object.create ? (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });\r\n}) : (function(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n});\r\n\r\nexport function __exportStar(m, o) {\r\n for (var p in m) if (p !== \"default\" && !Object.prototype.hasOwnProperty.call(o, p)) __createBinding(o, m, p);\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\n/** @deprecated */\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n}\r\n\r\nexport function __spreadArray(to, from, pack) {\r\n if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {\r\n if (ar || !(i in from)) {\r\n if (!ar) ar = Array.prototype.slice.call(from, 0, i);\r\n ar[i] = from[i];\r\n }\r\n }\r\n return to.concat(ar || from);\r\n}\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nvar __setModuleDefault = Object.create ? (function(o, v) {\r\n Object.defineProperty(o, \"default\", { enumerable: true, value: v });\r\n}) : function(o, v) {\r\n o[\"default\"] = v;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (k !== \"default\" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);\r\n __setModuleDefault(result, mod);\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, state, kind, f) {\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a getter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot read private member from an object whose class did not declare it\");\r\n return kind === \"m\" ? f : kind === \"a\" ? f.call(receiver) : f ? f.value : state.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, state, value, kind, f) {\r\n if (kind === \"m\") throw new TypeError(\"Private method is not writable\");\r\n if (kind === \"a\" && !f) throw new TypeError(\"Private accessor was defined without a setter\");\r\n if (typeof state === \"function\" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError(\"Cannot write private member to an object whose class did not declare it\");\r\n return (kind === \"a\" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;\r\n}\r\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 {ScrollStrategy} from './scroll-strategy';\nimport {ViewportRuler} from '@angular/cdk/scrolling';\nimport {coerceCssPixelValue} from '@angular/cdk/coercion';\nimport {supportsScrollBehavior} from '@angular/cdk/platform';\n\nconst scrollBehaviorSupported = supportsScrollBehavior();\n\n/**\n * Strategy that will prevent the user from scrolling while the overlay is visible.\n */\nexport class BlockScrollStrategy implements ScrollStrategy {\n private _previousHTMLStyles = {top: '', left: ''};\n private _previousScrollPosition: {top: number, left: number};\n private _isEnabled = false;\n private _document: Document;\n\n constructor(private _viewportRuler: ViewportRuler, document: any) {\n this._document = document;\n }\n\n /** Attaches this scroll strategy to an overlay. */\n attach() {}\n\n /** Blocks page-level scroll while the attached overlay is open. */\n enable() {\n if (this._canBeEnabled()) {\n const root = this._document.documentElement!;\n\n this._previousScrollPosition = this._viewportRuler.getViewportScrollPosition();\n\n // Cache the previous inline styles in case the user had set them.\n this._previousHTMLStyles.left = root.style.left || '';\n this._previousHTMLStyles.top = root.style.top || '';\n\n // Note: we're using the `html` node, instead of the `body`, because the `body` may\n // have the user agent margin, whereas the `html` is guaranteed not to have one.\n root.style.left = coerceCssPixelValue(-this._previousScrollPosition.left);\n root.style.top = coerceCssPixelValue(-this._previousScrollPosition.top);\n root.classList.add('cdk-global-scrollblock');\n this._isEnabled = true;\n }\n }\n\n /** Unblocks page-level scroll while the attached overlay is open. */\n disable() {\n if (this._isEnabled) {\n const html = this._document.documentElement!;\n const body = this._document.body!;\n const htmlStyle = html.style;\n const bodyStyle = body.style;\n const previousHtmlScrollBehavior = htmlStyle.scrollBehavior || '';\n const previousBodyScrollBehavior = bodyStyle.scrollBehavior || '';\n\n this._isEnabled = false;\n\n htmlStyle.left = this._previousHTMLStyles.left;\n htmlStyle.top = this._previousHTMLStyles.top;\n html.classList.remove('cdk-global-scrollblock');\n\n // Disable user-defined smooth scrolling temporarily while we restore the scroll position.\n // See https://developer.mozilla.org/en-US/docs/Web/CSS/scroll-behavior\n // Note that we don't mutate the property if the browser doesn't support `scroll-behavior`,\n // because it can throw off feature detections in `supportsScrollBehavior` which\n // checks for `'scrollBehavior' in documentElement.style`.\n if (scrollBehaviorSupported) {\n htmlStyle.scrollBehavior = bodyStyle.scrollBehavior = 'auto';\n }\n\n window.scroll(this._previousScrollPosition.left, this._previousScrollPosition.top);\n\n if (scrollBehaviorSupported) {\n htmlStyle.scrollBehavior = previousHtmlScrollBehavior;\n bodyStyle.scrollBehavior = previousBodyScrollBehavior;\n }\n }\n }\n\n private _canBeEnabled(): boolean {\n // Since the scroll strategies can't be singletons, we have to use a global CSS class\n // (`cdk-global-scrollblock`) to make sure that we don't try to disable global\n // scrolling multiple times.\n const html = this._document.documentElement!;\n\n if (html.classList.contains('cdk-global-scrollblock') || this._isEnabled) {\n return false;\n }\n\n const body = this._document.body;\n const viewport = this._viewportRuler.getViewportSize();\n return body.scrollHeight > viewport.height || body.scrollWidth > viewport.width;\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 {OverlayReference} from '../overlay-reference';\n\n/**\n * Describes a strategy that will be used by an overlay to handle scroll events while it is open.\n */\nexport interface ScrollStrategy {\n /** Enable this scroll strategy (called when the attached overlay is attached to a portal). */\n enable: () => void;\n\n /** Disable this scroll strategy (called when the attached overlay is detached from a portal). */\n disable: () => void;\n\n /** Attaches this `ScrollStrategy` to an overlay. */\n attach: (overlayRef: OverlayReference) => void;\n\n /** Detaches the scroll strategy from the current overlay. */\n detach?: () => void;\n}\n\n/**\n * Returns an error to be thrown when attempting to attach an already-attached scroll strategy.\n */\nexport function getMatScrollStrategyAlreadyAttachedError(): Error {\n return Error(`Scroll strategy has already been attached.`);\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 */\nimport {NgZone} from '@angular/core';\nimport {ScrollStrategy, getMatScrollStrategyAlreadyAttachedError} from './scroll-strategy';\nimport {OverlayReference} from '../overlay-reference';\nimport {Subscription} from 'rxjs';\nimport {ScrollDispatcher, ViewportRuler} from '@angular/cdk/scrolling';\n\n/**\n * Config options for the CloseScrollStrategy.\n */\nexport interface CloseScrollStrategyConfig {\n /** Amount of pixels the user has to scroll before the overlay is closed. */\n threshold?: number;\n}\n\n/**\n * Strategy that will close the overlay as soon as the user starts scrolling.\n */\nexport class CloseScrollStrategy implements ScrollStrategy {\n private _scrollSubscription: Subscription|null = null;\n private _overlayRef: OverlayReference;\n private _initialScrollPosition: number;\n\n constructor(\n private _scrollDispatcher: ScrollDispatcher,\n private _ngZone: NgZone,\n private _viewportRuler: ViewportRuler,\n private _config?: CloseScrollStrategyConfig) {}\n\n /** Attaches this scroll strategy to an overlay. */\n attach(overlayRef: OverlayReference) {\n if (this._overlayRef && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getMatScrollStrategyAlreadyAttachedError();\n }\n\n this._overlayRef = overlayRef;\n }\n\n /** Enables the closing of the attached overlay on scroll. */\n enable() {\n if (this._scrollSubscription) {\n return;\n }\n\n const stream = this._scrollDispatcher.scrolled(0);\n\n if (this._config && this._config.threshold && this._config.threshold > 1) {\n this._initialScrollPosition = this._viewportRuler.getViewportScrollPosition().top;\n\n this._scrollSubscription = stream.subscribe(() => {\n const scrollPosition = this._viewportRuler.getViewportScrollPosition().top;\n\n if (Math.abs(scrollPosition - this._initialScrollPosition) > this._config!.threshold!) {\n this._detach();\n } else {\n this._overlayRef.updatePosition();\n }\n });\n } else {\n this._scrollSubscription = stream.subscribe(this._detach);\n }\n }\n\n /** Disables the closing the attached overlay on scroll. */\n disable() {\n if (this._scrollSubscription) {\n this._scrollSubscription.unsubscribe();\n this._scrollSubscription = null;\n }\n }\n\n detach() {\n this.disable();\n this._overlayRef = null!;\n }\n\n /** Detaches the overlay ref and disables the scroll strategy. */\n private _detach = () => {\n this.disable();\n\n if (this._overlayRef.hasAttached()) {\n this._ngZone.run(() => this._overlayRef.detach());\n }\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 {ScrollStrategy} from './scroll-strategy';\n\n/** Scroll strategy that doesn't do anything. */\nexport class NoopScrollStrategy implements ScrollStrategy {\n /** Does nothing, as this scroll strategy is a no-op. */\n enable() { }\n /** Does nothing, as this scroll strategy is a no-op. */\n disable() { }\n /** Does nothing, as this scroll strategy is a no-op. */\n attach() { }\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\n// TODO(jelbourn): move this to live with the rest of the scrolling code\n// TODO(jelbourn): someday replace this with IntersectionObservers\n\n/**\n * Gets whether an element is scrolled outside of view by any of its parent scrolling containers.\n * @param element Dimensions of the element (from getBoundingClientRect)\n * @param scrollContainers Dimensions of element's scrolling containers (from getBoundingClientRect)\n * @returns Whether the element is scrolled out of view\n * @docs-private\n */\nexport function isElementScrolledOutsideView(element: ClientRect, scrollContainers: ClientRect[]) {\n return scrollContainers.some(containerBounds => {\n const outsideAbove = element.bottom < containerBounds.top;\n const outsideBelow = element.top > containerBounds.bottom;\n const outsideLeft = element.right < containerBounds.left;\n const outsideRight = element.left > containerBounds.right;\n\n return outsideAbove || outsideBelow || outsideLeft || outsideRight;\n });\n}\n\n\n/**\n * Gets whether an element is clipped by any of its scrolling containers.\n * @param element Dimensions of the element (from getBoundingClientRect)\n * @param scrollContainers Dimensions of element's scrolling containers (from getBoundingClientRect)\n * @returns Whether the element is clipped\n * @docs-private\n */\nexport function isElementClippedByScrolling(element: ClientRect, scrollContainers: ClientRect[]) {\n return scrollContainers.some(scrollContainerRect => {\n const clippedAbove = element.top < scrollContainerRect.top;\n const clippedBelow = element.bottom > scrollContainerRect.bottom;\n const clippedLeft = element.left < scrollContainerRect.left;\n const clippedRight = element.right > scrollContainerRect.right;\n\n return clippedAbove || clippedBelow || clippedLeft || clippedRight;\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 {NgZone} from '@angular/core';\nimport {Subscription} from 'rxjs';\nimport {ScrollStrategy, getMatScrollStrategyAlreadyAttachedError} from './scroll-strategy';\nimport {OverlayReference} from '../overlay-reference';\nimport {ScrollDispatcher, ViewportRuler} from '@angular/cdk/scrolling';\nimport {isElementScrolledOutsideView} from '../position/scroll-clip';\n\n/**\n * Config options for the RepositionScrollStrategy.\n */\nexport interface RepositionScrollStrategyConfig {\n /** Time in milliseconds to throttle the scroll events. */\n scrollThrottle?: number;\n\n /** Whether to close the overlay once the user has scrolled away completely. */\n autoClose?: boolean;\n}\n\n/**\n * Strategy that will update the element position as the user is scrolling.\n */\nexport class RepositionScrollStrategy implements ScrollStrategy {\n private _scrollSubscription: Subscription|null = null;\n private _overlayRef: OverlayReference;\n\n constructor(\n private _scrollDispatcher: ScrollDispatcher,\n private _viewportRuler: ViewportRuler,\n private _ngZone: NgZone,\n private _config?: RepositionScrollStrategyConfig) { }\n\n /** Attaches this scroll strategy to an overlay. */\n attach(overlayRef: OverlayReference) {\n if (this._overlayRef && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getMatScrollStrategyAlreadyAttachedError();\n }\n\n this._overlayRef = overlayRef;\n }\n\n /** Enables repositioning of the attached overlay on scroll. */\n enable() {\n if (!this._scrollSubscription) {\n const throttle = this._config ? this._config.scrollThrottle : 0;\n\n this._scrollSubscription = this._scrollDispatcher.scrolled(throttle).subscribe(() => {\n this._overlayRef.updatePosition();\n\n // TODO(crisbeto): make `close` on by default once all components can handle it.\n if (this._config && this._config.autoClose) {\n const overlayRect = this._overlayRef.overlayElement.getBoundingClientRect();\n const {width, height} = this._viewportRuler.getViewportSize();\n\n // TODO(crisbeto): include all ancestor scroll containers here once\n // we have a way of exposing the trigger element to the scroll strategy.\n const parentRects = [{width, height, bottom: height, right: width, top: 0, left: 0}];\n\n if (isElementScrolledOutsideView(overlayRect, parentRects)) {\n this.disable();\n this._ngZone.run(() => this._overlayRef.detach());\n }\n }\n });\n }\n }\n\n /** Disables repositioning of the attached overlay on scroll. */\n disable() {\n if (this._scrollSubscription) {\n this._scrollSubscription.unsubscribe();\n this._scrollSubscription = null;\n }\n }\n\n detach() {\n this.disable();\n this._overlayRef = null!;\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 {ScrollDispatcher, ViewportRuler} from '@angular/cdk/scrolling';\nimport {DOCUMENT} from '@angular/common';\nimport {Inject, Injectable, NgZone} from '@angular/core';\nimport {BlockScrollStrategy} from './block-scroll-strategy';\nimport {CloseScrollStrategy, CloseScrollStrategyConfig} from './close-scroll-strategy';\nimport {NoopScrollStrategy} from './noop-scroll-strategy';\nimport {\n RepositionScrollStrategy,\n RepositionScrollStrategyConfig,\n} from './reposition-scroll-strategy';\n\n\n/**\n * Options for how an overlay will handle scrolling.\n *\n * Users can provide a custom value for `ScrollStrategyOptions` to replace the default\n * behaviors. This class primarily acts as a factory for ScrollStrategy instances.\n */\n@Injectable({providedIn: 'root'})\nexport class ScrollStrategyOptions {\n private _document: Document;\n\n constructor(\n private _scrollDispatcher: ScrollDispatcher,\n private _viewportRuler: ViewportRuler,\n private _ngZone: NgZone,\n @Inject(DOCUMENT) document: any) {\n this._document = document;\n }\n\n /** Do nothing on scroll. */\n noop = () => new NoopScrollStrategy();\n\n /**\n * Close the overlay as soon as the user scrolls.\n * @param config Configuration to be used inside the scroll strategy.\n */\n close = (config?: CloseScrollStrategyConfig) => new CloseScrollStrategy(this._scrollDispatcher,\n this._ngZone, this._viewportRuler, config)\n\n /** Block scrolling. */\n block = () => new BlockScrollStrategy(this._viewportRuler, this._document);\n\n /**\n * Update the overlay's position on scroll.\n * @param config Configuration to be used inside the scroll strategy.\n * Allows debouncing the reposition calls.\n */\n reposition = (config?: RepositionScrollStrategyConfig) => new RepositionScrollStrategy(\n this._scrollDispatcher, this._viewportRuler, this._ngZone, config)\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 {CdkScrollable, ScrollDispatcher} from '@angular/cdk/scrolling';\n\n// Export pre-defined scroll strategies and interface to build custom ones.\nexport {ScrollStrategy} from './scroll-strategy';\nexport {ScrollStrategyOptions} from './scroll-strategy-options';\nexport {\n RepositionScrollStrategy,\n RepositionScrollStrategyConfig\n} from './reposition-scroll-strategy';\nexport {CloseScrollStrategy} from './close-scroll-strategy';\nexport {NoopScrollStrategy} from './noop-scroll-strategy';\nexport {BlockScrollStrategy} from './block-scroll-strategy';\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 {PositionStrategy} from './position/position-strategy';\nimport {Direction, Directionality} from '@angular/cdk/bidi';\nimport {ScrollStrategy, NoopScrollStrategy} from './scroll/index';\n\n\n/** Initial configuration used when creating an overlay. */\nexport class OverlayConfig {\n /** Strategy with which to position the overlay. */\n positionStrategy?: PositionStrategy;\n\n /** Strategy to be used when handling scroll events while the overlay is open. */\n scrollStrategy?: ScrollStrategy = new NoopScrollStrategy();\n\n /** Custom class to add to the overlay pane. */\n panelClass?: string | string[] = '';\n\n /** Whether the overlay has a backdrop. */\n hasBackdrop?: boolean = false;\n\n /** Custom class to add to the backdrop */\n backdropClass?: string | string[] = 'cdk-overlay-dark-backdrop';\n\n /** The width of the overlay panel. If a number is provided, pixel units are assumed. */\n width?: number | string;\n\n /** The height of the overlay panel. If a number is provided, pixel units are assumed. */\n height?: number | string;\n\n /** The min-width of the overlay panel. If a number is provided, pixel units are assumed. */\n minWidth?: number | string;\n\n /** The min-height of the overlay panel. If a number is provided, pixel units are assumed. */\n minHeight?: number | string;\n\n /** The max-width of the overlay panel. If a number is provided, pixel units are assumed. */\n maxWidth?: number | string;\n\n /** The max-height of the overlay panel. If a number is provided, pixel units are assumed. */\n maxHeight?: number | string;\n\n /**\n * Direction of the text in the overlay panel. If a `Directionality` instance\n * is passed in, the overlay will handle changes to its value automatically.\n */\n direction?: Direction | Directionality;\n\n /**\n * Whether the overlay should be disposed of when the user goes backwards/forwards in history.\n * Note that this usually doesn't include clicking on links (unless the user is using\n * the `HashLocationStrategy`).\n */\n disposeOnNavigation?: boolean = false;\n\n constructor(config?: OverlayConfig) {\n if (config) {\n // Use `Iterable` instead of `Array` because TypeScript, as of 3.6.3,\n // loses the array generic type in the `for of`. But we *also* have to use `Array` because\n // typescript won't iterate over an `Iterable` unless you compile with `--downlevelIteration`\n const configKeys =\n Object.keys(config) as Iterable<keyof OverlayConfig> & (keyof OverlayConfig)[];\n for (const key of configKeys) {\n if (config[key] !== undefined) {\n // TypeScript, as of version 3.5, sees the left-hand-side of this expression\n // as \"I don't know *which* key this is, so the only valid value is the intersection\n // of all the posible values.\" In this case, that happens to be `undefined`. TypeScript\n // is not smart enough to see that the right-hand-side is actually an access of the same\n // exact type with the same exact key, meaning that the value type must be identical.\n // So we use `any` to work around this.\n this[key] = config[key] as any;\n }\n }\n }\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\n/** Horizontal dimension of a connection point on the perimeter of the origin or overlay element. */\nimport {Optional} from '@angular/core';\nexport type HorizontalConnectionPos = 'start' | 'center' | 'end';\n\n/** Vertical dimension of a connection point on the perimeter of the origin or overlay element. */\nexport type VerticalConnectionPos = 'top' | 'center' | 'bottom';\n\n\n/** A connection point on the origin element. */\nexport interface OriginConnectionPosition {\n originX: HorizontalConnectionPos;\n originY: VerticalConnectionPos;\n}\n\n/** A connection point on the overlay element. */\nexport interface OverlayConnectionPosition {\n overlayX: HorizontalConnectionPos;\n overlayY: VerticalConnectionPos;\n}\n\n/** The points of the origin element and the overlay element to connect. */\nexport class ConnectionPositionPair {\n /** X-axis attachment point for connected overlay origin. Can be 'start', 'end', or 'center'. */\n originX: HorizontalConnectionPos;\n /** Y-axis attachment point for connected overlay origin. Can be 'top', 'bottom', or 'center'. */\n originY: VerticalConnectionPos;\n /** X-axis attachment point for connected overlay. Can be 'start', 'end', or 'center'. */\n overlayX: HorizontalConnectionPos;\n /** Y-axis attachment point for connected overlay. Can be 'top', 'bottom', or 'center'. */\n overlayY: VerticalConnectionPos;\n\n constructor(\n origin: OriginConnectionPosition,\n overlay: OverlayConnectionPosition,\n /** Offset along the X axis. */\n public offsetX?: number,\n /** Offset along the Y axis. */\n public offsetY?: number,\n /** Class(es) to be applied to the panel while this position is active. */\n public panelClass?: string | string[]) {\n\n this.originX = origin.originX;\n this.originY = origin.originY;\n this.overlayX = overlay.overlayX;\n this.overlayY = overlay.overlayY;\n }\n}\n\n/**\n * Set of properties regarding the position of the origin and overlay relative to the viewport\n * with respect to the containing Scrollable elements.\n *\n * The overlay and origin are clipped if any part of their bounding client rectangle exceeds the\n * bounds of any one of the strategy's Scrollable's bounding client rectangle.\n *\n * The overlay and origin are outside view if there is no overlap between their bounding client\n * rectangle and any one of the strategy's Scrollable's bounding client rectangle.\n *\n * ----------- -----------\n * | outside | | clipped |\n * | view | --------------------------\n * | | | | | |\n * ---------- | ----------- |\n * -------------------------- | |\n * | | | Scrollable |\n * | | | |\n * | | --------------------------\n * | Scrollable |\n * | |\n * --------------------------\n *\n * @docs-private\n */\nexport class ScrollingVisibility {\n isOriginClipped: boolean;\n isOriginOutsideView: boolean;\n isOverlayClipped: boolean;\n isOverlayOutsideView: boolean;\n}\n\n/** The change event emitted by the strategy when a fallback position is used. */\nexport class ConnectedOverlayPositionChange {\n constructor(\n /** The position used as a result of this change. */\n public connectionPair: ConnectionPositionPair,\n /** @docs-private */\n @Optional() public scrollableViewProperties: ScrollingVisibility) {}\n}\n\n/**\n * Validates whether a vertical position property matches the expected values.\n * @param property Name of the property being validated.\n * @param value Value of the property being validated.\n * @docs-private\n */\nexport function validateVerticalPosition(property: string, value: VerticalConnectionPos) {\n if (value !== 'top' && value !== 'bottom' && value !== 'center') {\n throw Error(`ConnectedPosition: Invalid ${property} \"${value}\". ` +\n `Expected \"top\", \"bottom\" or \"center\".`);\n }\n}\n\n/**\n * Validates whether a horizontal position property matches the expected values.\n * @param property Name of the property being validated.\n * @param value Value of the property being validated.\n * @docs-private\n */\nexport function validateHorizontalPosition(property: string, value: HorizontalConnectionPos) {\n if (value !== 'start' && value !== 'end' && value !== 'center') {\n throw Error(`ConnectedPosition: Invalid ${property} \"${value}\". ` +\n `Expected \"start\", \"end\" or \"center\".`);\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 {DOCUMENT} from '@angular/common';\nimport {Inject, Injectable, OnDestroy} from '@angular/core';\nimport {OverlayReference} from '../overlay-reference';\n\n\n/**\n * Service for dispatching events that land on the body to appropriate overlay ref,\n * if any. It maintains a list of attached overlays to determine best suited overlay based\n * on event target and order of overlay opens.\n */\n@Injectable({providedIn: 'root'})\nexport abstract class BaseOverlayDispatcher implements OnDestroy {\n\n /** Currently attached overlays in the order they were attached. */\n _attachedOverlays: OverlayReference[] = [];\n\n protected _document: Document;\n protected _isAttached: boolean;\n\n constructor(@Inject(DOCUMENT) document: any) {\n this._document = document;\n }\n\n ngOnDestroy(): void {\n this.detach();\n }\n\n /** Add a new overlay to the list of attached overlay refs. */\n add(overlayRef: OverlayReference): void {\n // Ensure that we don't get the same overlay multiple times.\n this.remove(overlayRef);\n this._attachedOverlays.push(overlayRef);\n }\n\n /** Remove an overlay from the list of attached overlay refs. */\n remove(overlayRef: OverlayReference): void {\n const index = this._attachedOverlays.indexOf(overlayRef);\n\n if (index > -1) {\n this._attachedOverlays.splice(index, 1);\n }\n\n // Remove the global listener once there are no more overlays.\n if (this._attachedOverlays.length === 0) {\n this.detach();\n }\n }\n\n /** Detaches the global event listener. */\n protected abstract detach(): void;\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 {DOCUMENT} from '@angular/common';\nimport {Inject, Injectable} from '@angular/core';\nimport {OverlayReference} from '../overlay-reference';\nimport {BaseOverlayDispatcher} from './base-overlay-dispatcher';\n\n\n/**\n * Service for dispatching keyboard events that land on the body to appropriate overlay ref,\n * if any. It maintains a list of attached overlays to determine best suited overlay based\n * on event target and order of overlay opens.\n */\n@Injectable({providedIn: 'root'})\nexport class OverlayKeyboardDispatcher extends BaseOverlayDispatcher {\n\n constructor(@Inject(DOCUMENT) document: any) {\n super(document);\n }\n\n /** Add a new overlay to the list of attached overlay refs. */\n override add(overlayRef: OverlayReference): void {\n super.add(overlayRef);\n\n // Lazily start dispatcher once first overlay is added\n if (!this._isAttached) {\n this._document.body.addEventListener('keydown', this._keydownListener);\n this._isAttached = true;\n }\n }\n\n /** Detaches the global keyboard event listener. */\n protected detach() {\n if (this._isAttached) {\n this._document.body.removeEventListener('keydown', this._keydownListener);\n this._isAttached = false;\n }\n }\n\n /** Keyboard event listener that will be attached to the body. */\n private _keydownListener = (event: KeyboardEvent) => {\n const overlays = this._attachedOverlays;\n\n for (let i = overlays.length - 1; i > -1; i--) {\n // Dispatch the keydown event to the top overlay which has subscribers to its keydown events.\n // We want to target the most recent overlay, rather than trying to match where the event came\n // from, because some components might open an overlay, but keep focus on a trigger element\n // (e.g. for select and autocomplete). We skip overlays without keydown event subscriptions,\n // because we don't want overlays that don't handle keyboard events to block the ones below\n // them that do.\n if (overlays[i]._keydownEvents.observers.length > 0) {\n overlays[i]._keydownEvents.next(event);\n break;\n }\n }\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 {DOCUMENT} from '@angular/common';\nimport {Inject, Injectable} from '@angular/core';\nimport {OverlayReference} from '../overlay-reference';\nimport {Platform, _getEventTarget} from '@angular/cdk/platform';\nimport {BaseOverlayDispatcher} from './base-overlay-dispatcher';\n\n/**\n * Service for dispatching mouse click events that land on the body to appropriate overlay ref,\n * if any. It maintains a list of attached overlays to determine best suited overlay based\n * on event target and order of overlay opens.\n */\n@Injectable({providedIn: 'root'})\nexport class OverlayOutsideClickDispatcher extends BaseOverlayDispatcher {\n private _cursorOriginalValue: string;\n private _cursorStyleIsSet = false;\n\n constructor(@Inject(DOCUMENT) document: any, private _platform: Platform) {\n super(document);\n }\n\n /** Add a new overlay to the list of attached overlay refs. */\n override add(overlayRef: OverlayReference): void {\n super.add(overlayRef);\n\n // Safari on iOS does not generate click events for non-interactive\n // elements. However, we want to receive a click for any element outside\n // the overlay. We can force a \"clickable\" state by setting\n // `cursor: pointer` on the document body. See:\n // https://developer.mozilla.org/en-US/docs/Web/API/Element/click_event#Safari_Mobile\n // https://developer.apple.com/library/archive/documentation/AppleApplications/Reference/SafariWebContent/HandlingEvents/HandlingEvents.html\n if (!this._isAttached) {\n const body = this._document.body;\n body.addEventListener('click', this._clickListener, true);\n body.addEventListener('auxclick', this._clickListener, true);\n body.addEventListener('contextmenu', this._clickListener, true);\n\n // click event is not fired on iOS. To make element \"clickable\" we are\n // setting the cursor to pointer\n if (this._platform.IOS && !this._cursorStyleIsSet) {\n this._cursorOriginalValue = body.style.cursor;\n body.style.cursor = 'pointer';\n this._cursorStyleIsSet = true;\n }\n\n this._isAttached = true;\n }\n }\n\n /** Detaches the global keyboard event listener. */\n protected detach() {\n if (this._isAttached) {\n const body = this._document.body;\n body.removeEventListener('click', this._clickListener, true);\n body.removeEventListener('auxclick', this._clickListener, true);\n body.removeEventListener('contextmenu', this._clickListener, true);\n if (this._platform.IOS && this._cursorStyleIsSet) {\n body.style.cursor = this._cursorOriginalValue;\n this._cursorStyleIsSet = false;\n }\n this._isAttached = false;\n }\n }\n\n /** Click event listener that will be attached to the body propagate phase. */\n private _clickListener = (event: MouseEvent) => {\n const target = _getEventTarget(event);\n // We copy the array because the original may be modified asynchronously if the\n // outsidePointerEvents listener decides to detach overlays resulting in index errors inside\n // the for loop.\n const overlays = this._attachedOverlays.slice();\n\n // Dispatch the mouse event to the top overlay which has subscribers to its mouse events.\n // We want to target all overlays for which the click could be considered as outside click.\n // As soon as we reach an overlay for which the click is not outside click we break off\n // the loop.\n for (let i = overlays.length - 1; i > -1; i--) {\n const overlayRef = overlays[i];\n if (overlayRef._outsidePointerEvents.observers.length < 1 || !overlayRef.hasAttached()) {\n continue;\n }\n\n // If it's a click inside the overlay, just break - we should do nothing\n // If it's an outside click dispatch the mouse event, and proceed with the next overlay\n if (overlayRef.overlayElement.contains(target as Node)) {\n break;\n }\n\n overlayRef._outsidePointerEvents.next(event);\n }\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 {DOCUMENT} from '@angular/common';\nimport {Inject, Injectable, OnDestroy} from '@angular/core';\nimport {Platform, _isTestEnvironment} from '@angular/cdk/platform';\n\n/** Container inside which all overlays will render. */\n@Injectable({providedIn: 'root'})\nexport class OverlayContainer implements OnDestroy {\n protected _containerElement: HTMLElement;\n protected _document: Document;\n\n constructor(@Inject(DOCUMENT) document: any, protected _platform: Platform) {\n this._document = document;\n }\n\n ngOnDestroy() {\n const container = this._containerElement;\n\n if (container && container.parentNode) {\n container.parentNode.removeChild(container);\n }\n }\n\n /**\n * This method returns the overlay container element. It will lazily\n * create the element the first time it is called to facilitate using\n * the container in non-browser environments.\n * @returns the container element\n */\n getContainerElement(): HTMLElement {\n if (!this._containerElement) {\n this._createContainer();\n }\n\n return this._containerElement;\n }\n\n /**\n * Create the overlay container element, which is simply a div\n * with the 'cdk-overlay-container' class on the document body.\n */\n protected _createContainer(): void {\n const containerClass = 'cdk-overlay-container';\n\n // TODO(crisbeto): remove the testing check once we have an overlay testing\n // module or Angular starts tearing down the testing `NgModule`. See:\n // https://github.com/angular/angular/issues/18831\n if (this._platform.isBrowser || _isTestEnvironment()) {\n const oppositePlatformContainers =\n this._document.querySelectorAll(`.${containerClass}[platform=\"server\"], ` +\n `.${containerClass}[platform=\"test\"]`);\n\n // Remove any old containers from the opposite platform.\n // This can happen when transitioning from the server to the client.\n for (let i = 0; i < oppositePlatformContainers.length; i++) {\n oppositePlatformContainers[i].parentNode!.removeChild(oppositePlatformContainers[i]);\n }\n }\n\n const container = this._document.createElement('div');\n container.classList.add(containerClass);\n\n // A long time ago we kept adding new overlay containers whenever a new app was instantiated,\n // but at some point we added logic which clears the duplicate ones in order to avoid leaks.\n // The new logic was a little too aggressive since it was breaking some legitimate use cases.\n // To mitigate the problem we made it so that only containers from a different platform are\n // cleared, but the side-effect was that people started depending on the overly-aggressive\n // logic to clean up their tests for them. Until we can introduce an overlay-specific testing\n // module which does the cleanup, we try to detect that we're in a test environment and we\n // always clear the container. See #17006.\n // TODO(crisbeto): remove the test environment check once we have an overlay testing module.\n if (_isTestEnvironment()) {\n container.setAttribute('platform', 'test');\n } else if (!this._platform.isBrowser) {\n container.setAttribute('platform', 'server');\n }\n\n this._document.body.appendChild(container);\n this._containerElement = container;\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 {Direction, Directionality} from '@angular/cdk/bidi';\nimport {ComponentPortal, Portal, PortalOutlet, TemplatePortal} from '@angular/cdk/portal';\nimport {ComponentRef, EmbeddedViewRef, NgZone} from '@angular/core';\nimport {Location} from '@angular/common';\nimport {Observable, Subject, merge, SubscriptionLike, Subscription} from 'rxjs';\nimport {take, takeUntil} from 'rxjs/operators';\nimport {OverlayKeyboardDispatcher} from './dispatchers/overlay-keyboard-dispatcher';\nimport {OverlayOutsideClickDispatcher} from './dispatchers/overlay-outside-click-dispatcher';\nimport {OverlayConfig} from './overlay-config';\nimport {coerceCssPixelValue, coerceArray} from '@angular/cdk/coercion';\nimport {OverlayReference} from './overlay-reference';\nimport {PositionStrategy} from './position/position-strategy';\nimport {ScrollStrategy} from './scroll';\n\n\n/** An object where all of its properties cannot be written. */\nexport type ImmutableObject<T> = {\n readonly [P in keyof T]: T[P];\n};\n\n/**\n * Reference to an overlay that has been created with the Overlay service.\n * Used to manipulate or dispose of said overlay.\n */\nexport class OverlayRef implements PortalOutlet, OverlayReference {\n private _backdropElement: HTMLElement | null = null;\n private readonly _backdropClick = new Subject<MouseEvent>();\n private readonly _attachments = new Subject<void>();\n private readonly _detachments = new Subject<void>();\n private _positionStrategy: PositionStrategy | undefined;\n private _scrollStrategy: ScrollStrategy | undefined;\n private _locationChanges: SubscriptionLike = Subscription.EMPTY;\n private _backdropClickHandler = (event: MouseEvent) => this._backdropClick.next(event);\n\n /**\n * Reference to the parent of the `_host` at the time it was detached. Used to restore\n * the `_host` to its original position in the DOM when it gets re-attached.\n */\n private _previousHostParent: HTMLElement;\n\n /** Stream of keydown events dispatched to this overlay. */\n readonly _keydownEvents = new Subject<KeyboardEvent>();\n\n /** Stream of mouse outside events dispatched to this overlay. */\n readonly _outsidePointerEvents = new Subject<MouseEvent>();\n\n constructor(\n private _portalOutlet: PortalOutlet,\n private _host: HTMLElement,\n private _pane: HTMLElement,\n private _config: ImmutableObject<OverlayConfig>,\n private _ngZone: NgZone,\n private _keyboardDispatcher: OverlayKeyboardDispatcher,\n private _document: Document,\n private _location: Location,\n private _outsideClickDispatcher: OverlayOutsideClickDispatcher) {\n\n if (_config.scrollStrategy) {\n this._scrollStrategy = _config.scrollStrategy;\n this._scrollStrategy.attach(this);\n }\n\n this._positionStrategy = _config.positionStrategy;\n }\n\n /** The overlay's HTML element */\n get overlayElement(): HTMLElement {\n return this._pane;\n }\n\n /** The overlay's backdrop HTML element. */\n get backdropElement(): HTMLElement | null {\n return this._backdropElement;\n }\n\n /**\n * Wrapper around the panel element. Can be used for advanced\n * positioning where a wrapper with specific styling is\n * required around the overlay pane.\n */\n get hostElement(): HTMLElement {\n return this._host;\n }\n\n attach<T>(portal: ComponentPortal<T>): ComponentRef<T>;\n attach<T>(portal: TemplatePortal<T>): EmbeddedViewRef<T>;\n attach(portal: any): any;\n\n /**\n * Attaches content, given via a Portal, to the overlay.\n * If the overlay is configured to have a backdrop, it will be created.\n *\n * @param portal Portal instance to which to attach the overlay.\n * @returns The portal attachment result.\n */\n attach(portal: Portal<any>): any {\n let attachResult = this._portalOutlet.attach(portal);\n\n // Update the pane element with the given configuration.\n if (!this._host.parentElement && this._previousHostParent) {\n this._previousHostParent.appendChild(this._host);\n }\n\n if (this._positionStrategy) {\n this._positionStrategy.attach(this);\n }\n\n this._updateStackingOrder();\n this._updateElementSize();\n this._updateElementDirection();\n\n if (this._scrollStrategy) {\n this._scrollStrategy.enable();\n }\n\n // Update the position once the zone is stable so that the overlay will be fully rendered\n // before attempting to position it, as the position may depend on the size of the rendered\n // content.\n this._ngZone.onStable\n .pipe(take(1))\n .subscribe(() => {\n // The overlay could've been detached before the zone has stabilized.\n if (this.hasAttached()) {\n this.updatePosition();\n }\n });\n\n // Enable pointer events for the overlay pane element.\n this._togglePointerEvents(true);\n\n if (this._config.hasBackdrop) {\n this._attachBackdrop();\n }\n\n if (this._config.panelClass) {\n this._toggleClasses(this._pane, this._config.panelClass, true);\n }\n\n // Only emit the `attachments` event once all other setup is done.\n this._attachments.next();\n\n // Track this overlay by the keyboard dispatcher\n this._keyboardDispatcher.add(this);\n\n if (this._config.disposeOnNavigation) {\n this._locationChanges = this._location.subscribe(() => this.dispose());\n }\n\n this._outsideClickDispatcher.add(this);\n return attachResult;\n }\n\n /**\n * Detaches an overlay from a portal.\n * @returns The portal detachment result.\n */\n detach(): any {\n if (!this.hasAttached()) {\n return;\n }\n\n this.detachBackdrop();\n\n // When the overlay is detached, the pane element should disable pointer events.\n // This is necessary because otherwise the pane element will cover the page and disable\n // pointer events therefore. Depends on the position strategy and the applied pane boundaries.\n this._togglePointerEvents(false);\n\n if (this._positionStrategy && this._positionStrategy.detach) {\n this._positionStrategy.detach();\n }\n\n if (this._scrollStrategy) {\n this._scrollStrategy.disable();\n }\n\n const detachmentResult = this._portalOutlet.detach();\n\n // Only emit after everything is detached.\n this._detachments.next();\n\n // Remove this overlay from keyboard dispatcher tracking.\n this._keyboardDispatcher.remove(this);\n\n // Keeping the host element in the DOM can cause scroll jank, because it still gets\n // rendered, even though it's transparent and unclickable which is why we remove it.\n this._detachContentWhenStable();\n this._locationChanges.unsubscribe();\n this._outsideClickDispatcher.remove(this);\n return detachmentResult;\n }\n\n /** Cleans up the overlay from the DOM. */\n dispose(): void {\n const isAttached = this.hasAttached();\n\n if (this._positionStrategy) {\n this._positionStrategy.dispose();\n }\n\n this._disposeScrollStrategy();\n this._disposeBackdrop(this._backdropElement);\n this._locationChanges.unsubscribe();\n this._keyboardDispatcher.remove(this);\n this._portalOutlet.dispose();\n this._attachments.complete();\n this._backdropClick.complete();\n this._keydownEvents.complete();\n this._outsidePointerEvents.complete();\n this._outsideClickDispatcher.remove(this);\n\n if (this._host && this._host.parentNode) {\n this._host.parentNode.removeChild(this._host);\n this._host = null!;\n }\n\n this._previousHostParent = this._pane = null!;\n\n if (isAttached) {\n this._detachments.next();\n }\n\n this._detachments.complete();\n }\n\n /** Whether the overlay has attached content. */\n hasAttached(): boolean {\n return this._portalOutlet.hasAttached();\n }\n\n /** Gets an observable that emits when the backdrop has been clicked. */\n backdropClick(): Observable<MouseEvent> {\n return this._backdropClick;\n }\n\n /** Gets an observable that emits when the overlay has been attached. */\n attachments(): Observable<void> {\n return this._attachments;\n }\n\n /** Gets an observable that emits when the overlay has been detached. */\n detachments(): Observable<void> {\n return this._detachments;\n }\n\n /** Gets an observable of keydown events targeted to this overlay. */\n keydownEvents(): Observable<KeyboardEvent> {\n return this._keydownEvents;\n }\n\n /** Gets an observable of pointer events targeted outside this overlay. */\n outsidePointerEvents(): Observable<MouseEvent> {\n return this._outsidePointerEvents;\n }\n\n /** Gets the current overlay configuration, which is immutable. */\n getConfig(): OverlayConfig {\n return this._config;\n }\n\n /** Updates the position of the overlay based on the position strategy. */\n updatePosition(): void {\n if (this._positionStrategy) {\n this._positionStrategy.apply();\n }\n }\n\n /** Switches to a new position strategy and updates the overlay position. */\n updatePositionStrategy(strategy: PositionStrategy): void {\n if (strategy === this._positionStrategy) {\n return;\n }\n\n if (this._positionStrategy) {\n this._positionStrategy.dispose();\n }\n\n this._positionStrategy = strategy;\n\n if (this.hasAttached()) {\n strategy.attach(this);\n this.updatePosition();\n }\n }\n\n /** Update the size properties of the overlay. */\n updateSize(sizeConfig: OverlaySizeConfig): void {\n this._config = {...this._config, ...sizeConfig};\n this._updateElementSize();\n }\n\n /** Sets the LTR/RTL direction for the overlay. */\n setDirection(dir: Direction | Directionality): void {\n this._config = {...this._config, direction: dir};\n this._updateElementDirection();\n }\n\n /** Add a CSS class or an array of classes to the overlay pane. */\n addPanelClass(classes: string | string[]): void {\n if (this._pane) {\n this._toggleClasses(this._pane, classes, true);\n }\n }\n\n /** Remove a CSS class or an array of classes from the overlay pane. */\n removePanelClass(classes: string | string[]): void {\n if (this._pane) {\n this._toggleClasses(this._pane, classes, false);\n }\n }\n\n /**\n * Returns the layout direction of the overlay panel.\n */\n getDirection(): Direction {\n const direction = this._config.direction;\n\n if (!direction) {\n return 'ltr';\n }\n\n return typeof direction === 'string' ? direction : direction.value;\n }\n\n /** Switches to a new scroll strategy. */\n updateScrollStrategy(strategy: ScrollStrategy): void {\n if (strategy === this._scrollStrategy) {\n return;\n }\n\n this._disposeScrollStrategy();\n this._scrollStrategy = strategy;\n\n if (this.hasAttached()) {\n strategy.attach(this);\n strategy.enable();\n }\n }\n\n /** Updates the text direction of the overlay panel. */\n private _updateElementDirection() {\n this._host.setAttribute('dir', this.getDirection());\n }\n\n /** Updates the size of the overlay element based on the overlay config. */\n private _updateElementSize() {\n if (!this._pane) {\n return;\n }\n\n const style = this._pane.style;\n\n style.width = coerceCssPixelValue(this._config.width);\n style.height = coerceCssPixelValue(this._config.height);\n style.minWidth = coerceCssPixelValue(this._config.minWidth);\n style.minHeight = coerceCssPixelValue(this._config.minHeight);\n style.maxWidth = coerceCssPixelValue(this._config.maxWidth);\n style.maxHeight = coerceCssPixelValue(this._config.maxHeight);\n }\n\n /** Toggles the pointer events for the overlay pane element. */\n private _togglePointerEvents(enablePointer: boolean) {\n this._pane.style.pointerEvents = enablePointer ? '' : 'none';\n }\n\n /** Attaches a backdrop for this overlay. */\n private _attachBackdrop() {\n const showingClass = 'cdk-overlay-backdrop-showing';\n\n this._backdropElement = this._document.createElement('div');\n this._backdropElement.classList.add('cdk-overlay-backdrop');\n\n if (this._config.backdropClass) {\n this._toggleClasses(this._backdropElement, this._config.backdropClass, true);\n }\n\n // Insert the backdrop before the pane in the DOM order,\n // in order to handle stacked overlays properly.\n this._host.parentElement!.insertBefore(this._backdropElement, this._host);\n\n // Forward backdrop clicks such that the consumer of the overlay can perform whatever\n // action desired when such a click occurs (usually closing the overlay).\n this._backdropElement.addEventListener('click', this._backdropClickHandler);\n\n // Add class to fade-in the backdrop after one frame.\n if (typeof requestAnimationFrame !== 'undefined') {\n this._ngZone.runOutsideAngular(() => {\n requestAnimationFrame(() => {\n if (this._backdropElement) {\n this._backdropElement.classList.add(showingClass);\n }\n });\n });\n } else {\n this._backdropElement.classList.add(showingClass);\n }\n }\n\n /**\n * Updates the stacking order of the element, moving it to the top if necessary.\n * This is required in cases where one overlay was detached, while another one,\n * that should be behind it, was destroyed. The next time both of them are opened,\n * the stacking will be wrong, because the detached element's pane will still be\n * in its original DOM position.\n */\n private _updateStackingOrder() {\n if (this._host.nextSibling) {\n this._host.parentNode!.appendChild(this._host);\n }\n }\n\n /** Detaches the backdrop (if any) associated with the overlay. */\n detachBackdrop(): void {\n const backdropToDetach = this._backdropElement;\n\n if (!backdropToDetach) {\n return;\n }\n\n let timeoutId: any;\n const finishDetach = () => {\n // It may not be attached to anything in certain cases (e.g. unit tests).\n if (backdropToDetach) {\n backdropToDetach.removeEventListener('click', this._backdropClickHandler);\n backdropToDetach.removeEventListener('transitionend', finishDetach);\n this._disposeBackdrop(backdropToDetach);\n }\n\n if (this._config.backdropClass) {\n this._toggleClasses(backdropToDetach!, this._config.backdropClass, false);\n }\n\n clearTimeout(timeoutId);\n };\n\n backdropToDetach.classList.remove('cdk-overlay-backdrop-showing');\n\n this._ngZone.runOutsideAngular(() => {\n backdropToDetach!.addEventListener('transitionend', finishDetach);\n });\n\n // If the backdrop doesn't have a transition, the `transitionend` event won't fire.\n // In this case we make it unclickable and we try to remove it after a delay.\n backdropToDetach.style.pointerEvents = 'none';\n\n // Run this outside the Angular zone because there's nothing that Angular cares about.\n // If it were to run inside the Angular zone, every test that used Overlay would have to be\n // either async or fakeAsync.\n timeoutId = this._ngZone.runOutsideAngular(() => setTimeout(finishDetach, 500));\n }\n\n /** Toggles a single CSS class or an array of classes on an element. */\n private _toggleClasses(element: HTMLElement, cssClasses: string | string[], isAdd: boolean) {\n const classList = element.classList;\n\n coerceArray(cssClasses).forEach(cssClass => {\n // We can't do a spread here, because IE doesn't support setting multiple classes.\n // Also trying to add an empty string to a DOMTokenList will throw.\n if (cssClass) {\n isAdd ? classList.add(cssClass) : classList.remove(cssClass);\n }\n });\n }\n\n /** Detaches the overlay content next time the zone stabilizes. */\n private _detachContentWhenStable() {\n // Normally we wouldn't have to explicitly run this outside the `NgZone`, however\n // if the consumer is using `zone-patch-rxjs`, the `Subscription.unsubscribe` call will\n // be patched to run inside the zone, which will throw us into an infinite loop.\n this._ngZone.runOutsideAngular(() => {\n // We can't remove the host here immediately, because the overlay pane's content\n // might still be animating. This stream helps us avoid interrupting the animation\n // by waiting for the pane to become empty.\n const subscription = this._ngZone.onStable\n .pipe(takeUntil(merge(this._attachments, this._detachments)))\n .subscribe(() => {\n // Needs a couple of checks for the pane and host, because\n // they may have been removed by the time the zone stabilizes.\n if (!this._pane || !this._host || this._pane.children.length === 0) {\n if (this._pane && this._config.panelClass) {\n this._toggleClasses(this._pane, this._config.panelClass, false);\n }\n\n if (this._host && this._host.parentElement) {\n this._previousHostParent = this._host.parentElement;\n this._previousHostParent.removeChild(this._host);\n }\n\n subscription.unsubscribe();\n }\n });\n });\n }\n\n /** Disposes of a scroll strategy. */\n private _disposeScrollStrategy() {\n const scrollStrategy = this._scrollStrategy;\n\n if (scrollStrategy) {\n scrollStrategy.disable();\n\n if (scrollStrategy.detach) {\n scrollStrategy.detach();\n }\n }\n }\n\n /** Removes a backdrop element from the DOM. */\n private _disposeBackdrop(backdrop: HTMLElement | null) {\n if (backdrop) {\n if (backdrop.parentNode) {\n backdrop.parentNode.removeChild(backdrop);\n }\n\n // It is possible that a new portal has been attached to this overlay since we started\n // removing the backdrop. If that is the case, only clear the backdrop reference if it\n // is still the same instance that we started to remove.\n if (this._backdropElement === backdrop) {\n this._backdropElement = null;\n }\n }\n }\n}\n\n\n/** Size properties for an overlay. */\nexport interface OverlaySizeConfig {\n width?: number | string;\n height?: number | string;\n minWidth?: number | string;\n minHeight?: number | string;\n maxWidth?: number | string;\n maxHeight?: number | string;\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 {PositionStrategy} from './position-strategy';\nimport {ElementRef} from '@angular/core';\nimport {ViewportRuler, CdkScrollable, ViewportScrollPosition} from '@angular/cdk/scrolling';\nimport {\n ConnectedOverlayPositionChange,\n ConnectionPositionPair,\n ScrollingVisibility,\n validateHorizontalPosition,\n validateVerticalPosition,\n} from './connected-position';\nimport {Observable, Subscription, Subject} from 'rxjs';\nimport {OverlayReference} from '../overlay-reference';\nimport {isElementScrolledOutsideView, isElementClippedByScrolling} from './scroll-clip';\nimport {coerceCssPixelValue, coerceArray} from '@angular/cdk/coercion';\nimport {Platform} from '@angular/cdk/platform';\nimport {OverlayContainer} from '../overlay-container';\n\n// TODO: refactor clipping detection into a separate thing (part of scrolling module)\n// TODO: doesn't handle both flexible width and height when it has to scroll along both axis.\n\n/** Class to be added to the overlay bounding box. */\nconst boundingBoxClass = 'cdk-overlay-connected-position-bounding-box';\n\n/** Regex used to split a string on its CSS units. */\nconst cssUnitPattern = /([A-Za-z%]+)$/;\n\n/** Possible values that can be set as the origin of a FlexibleConnectedPositionStrategy. */\nexport type FlexibleConnectedPositionStrategyOrigin = ElementRef | Element | Point & {\n width?: number;\n height?: number;\n};\n\n/**\n * A strategy for positioning overlays. Using this strategy, an overlay is given an\n * implicit position relative some origin element. The relative position is defined in terms of\n * a point on the origin element that is connected to a point on the overlay element. For example,\n * a basic dropdown is connecting the bottom-left corner of the origin to the top-left corner\n * of the overlay.\n */\nexport class FlexibleConnectedPositionStrategy implements PositionStrategy {\n /** The overlay to which this strategy is attached. */\n private _overlayRef: OverlayReference;\n\n /** Whether we're performing the very first positioning of the overlay. */\n private _isInitialRender: boolean;\n\n /** Last size used for the bounding box. Used to avoid resizing the overlay after open. */\n private _lastBoundingBoxSize = {width: 0, height: 0};\n\n /** Whether the overlay was pushed in a previous positioning. */\n private _isPushed = false;\n\n /** Whether the overlay can be pushed on-screen on the initial open. */\n private _canPush = true;\n\n /** Whether the overlay can grow via flexible width/height after the initial open. */\n private _growAfterOpen = false;\n\n /** Whether the overlay's width and height can be constrained to fit within the viewport. */\n private _hasFlexibleDimensions = true;\n\n /** Whether the overlay position is locked. */\n private _positionLocked = false;\n\n /** Cached origin dimensions */\n private _originRect: ClientRect;\n\n /** Cached overlay dimensions */\n private _overlayRect: ClientRect;\n\n /** Cached viewport dimensions */\n private _viewportRect: ClientRect;\n\n /** Amount of space that must be maintained between the overlay and the edge of the viewport. */\n private _viewportMargin = 0;\n\n /** The Scrollable containers used to check scrollable view properties on position change. */\n private _scrollables: CdkScrollable[] = [];\n\n /** Ordered list of preferred positions, from most to least desirable. */\n _preferredPositions: ConnectionPositionPair[] = [];\n\n /** The origin element against which the overlay will be positioned. */\n private _origin: FlexibleConnectedPositionStrategyOrigin;\n\n /** The overlay pane element. */\n private _pane: HTMLElement;\n\n /** Whether the strategy has been disposed of already. */\n private _isDisposed: boolean;\n\n /**\n * Parent element for the overlay panel used to constrain the overlay panel's size to fit\n * within the viewport.\n */\n private _boundingBox: HTMLElement | null;\n\n /** The last position to have been calculated as the best fit position. */\n private _lastPosition: ConnectedPosition | null;\n\n /** Subject that emits whenever the position changes. */\n private readonly _positionChanges = new Subject<ConnectedOverlayPositionChange>();\n\n /** Subscription to viewport size changes. */\n private _resizeSubscription = Subscription.EMPTY;\n\n /** Default offset for the overlay along the x axis. */\n private _offsetX = 0;\n\n /** Default offset for the overlay along the y axis. */\n private _offsetY = 0;\n\n /** Selector to be used when finding the elements on which to set the transform origin. */\n private _transformOriginSelector: string;\n\n /** Keeps track of the CSS classes that the position strategy has applied on the overlay panel. */\n private _appliedPanelClasses: string[] = [];\n\n /** Amount by which the overlay was pushed in each axis during the last time it was positioned. */\n private _previousPushAmount: {x: number, y: number} | null;\n\n /** Observable sequence of position changes. */\n positionChanges: Observable<ConnectedOverlayPositionChange> = this._positionChanges;\n\n /** Ordered list of preferred positions, from most to least desirable. */\n get positions(): ConnectionPositionPair[] {\n return this._preferredPositions;\n }\n\n constructor(\n connectedTo: FlexibleConnectedPositionStrategyOrigin, private _viewportRuler: ViewportRuler,\n private _document: Document, private _platform: Platform,\n private _overlayContainer: OverlayContainer) {\n this.setOrigin(connectedTo);\n }\n\n /** Attaches this position strategy to an overlay. */\n attach(overlayRef: OverlayReference): void {\n if (this._overlayRef && overlayRef !== this._overlayRef &&\n (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw Error('This position strategy is already attached to an overlay');\n }\n\n this._validatePositions();\n\n overlayRef.hostElement.classList.add(boundingBoxClass);\n\n this._overlayRef = overlayRef;\n this._boundingBox = overlayRef.hostElement;\n this._pane = overlayRef.overlayElement;\n this._isDisposed = false;\n this._isInitialRender = true;\n this._lastPosition = null;\n this._resizeSubscription.unsubscribe();\n this._resizeSubscription = this._viewportRuler.change().subscribe(() => {\n // When the window is resized, we want to trigger the next reposition as if it\n // was an initial render, in order for the strategy to pick a new optimal position,\n // otherwise position locking will cause it to stay at the old one.\n this._isInitialRender = true;\n this.apply();\n });\n }\n\n /**\n * Updates the position of the overlay element, using whichever preferred position relative\n * to the origin best fits on-screen.\n *\n * The selection of a position goes as follows:\n * - If any positions fit completely within the viewport as-is,\n * choose the first position that does so.\n * - If flexible dimensions are enabled and at least one satifies the given minimum width/height,\n * choose the position with the greatest available size modified by the positions' weight.\n * - If pushing is enabled, take the position that went off-screen the least and push it\n * on-screen.\n * - If none of the previous criteria were met, use the position that goes off-screen the least.\n * @docs-private\n */\n apply(): void {\n // We shouldn't do anything if the strategy was disposed or we're on the server.\n if (this._isDisposed || !this._platform.isBrowser) {\n return;\n }\n\n // If the position has been applied already (e.g. when the overlay was opened) and the\n // consumer opted into locking in the position, re-use the old position, in order to\n // prevent the overlay from jumping around.\n if (!this._isInitialRender && this._positionLocked && this._lastPosition) {\n this.reapplyLastPosition();\n return;\n }\n\n this._clearPanelClasses();\n this._resetOverlayElementStyles();\n this._resetBoundingBoxStyles();\n\n // We need the bounding rects for the origin and the overlay to determine how to position\n // the overlay relative to the origin.\n // We use the viewport rect to determine whether a position would go off-screen.\n this._viewportRect = this._getNarrowedViewportRect();\n this._originRect = this._getOriginRect();\n this._overlayRect = this._pane.getBoundingClientRect();\n\n const originRect = this._originRect;\n const overlayRect = this._overlayRect;\n const viewportRect = this._viewportRect;\n\n // Positions where the overlay will fit with flexible dimensions.\n const flexibleFits: FlexibleFit[] = [];\n\n // Fallback if none of the preferred positions fit within the viewport.\n let fallback: FallbackPosition | undefined;\n\n // Go through each of the preferred positions looking for a good fit.\n // If a good fit is found, it will be applied immediately.\n for (let pos of this._preferredPositions) {\n // Get the exact (x, y) coordinate for the point-of-origin on the origin element.\n let originPoint = this._getOriginPoint(originRect, pos);\n\n // From that point-of-origin, get the exact (x, y) coordinate for the top-left corner of the\n // overlay in this position. We use the top-left corner for calculations and later translate\n // this into an appropriate (top, left, bottom, right) style.\n let overlayPoint = this._getOverlayPoint(originPoint, overlayRect, pos);\n\n // Calculate how well the overlay would fit into the viewport with this point.\n let overlayFit = this._getOverlayFit(overlayPoint, overlayRect, viewportRect, pos);\n\n // If the overlay, without any further work, fits into the viewport, use this position.\n if (overlayFit.isCompletelyWithinViewport) {\n this._isPushed = false;\n this._applyPosition(pos, originPoint);\n return;\n }\n\n // If the overlay has flexible dimensions, we can use this position\n // so long as there's enough space for the minimum dimensions.\n if (this._canFitWithFlexibleDimensions(overlayFit, overlayPoint, viewportRect)) {\n // Save positions where the overlay will fit with flexible dimensions. We will use these\n // if none of the positions fit *without* flexible dimensions.\n flexibleFits.push({\n position: pos,\n origin: originPoint,\n overlayRect,\n boundingBoxRect: this._calculateBoundingBoxRect(originPoint, pos)\n });\n\n continue;\n }\n\n // If the current preferred position does not fit on the screen, remember the position\n // if it has more visible area on-screen than we've seen and move onto the next preferred\n // position.\n if (!fallback || fallback.overlayFit.visibleArea < overlayFit.visibleArea) {\n fallback = {overlayFit, overlayPoint, originPoint, position: pos, overlayRect};\n }\n }\n\n // If there are any positions where the overlay would fit with flexible dimensions, choose the\n // one that has the greatest area available modified by the position's weight\n if (flexibleFits.length) {\n let bestFit: FlexibleFit | null = null;\n let bestScore = -1;\n for (const fit of flexibleFits) {\n const score =\n fit.boundingBoxRect.width * fit.boundingBoxRect.height * (fit.position.weight || 1);\n if (score > bestScore) {\n bestScore = score;\n bestFit = fit;\n }\n }\n\n this._isPushed = false;\n this._applyPosition(bestFit!.position, bestFit!.origin);\n return;\n }\n\n // When none of the preferred positions fit within the viewport, take the position\n // that went off-screen the least and attempt to push it on-screen.\n if (this._canPush) {\n // TODO(jelbourn): after pushing, the opening \"direction\" of the overlay might not make sense.\n this._isPushed = true;\n this._applyPosition(fallback!.position, fallback!.originPoint);\n return;\n }\n\n // All options for getting the overlay within the viewport have been exhausted, so go with the\n // position that went off-screen the least.\n this._applyPosition(fallback!.position, fallback!.originPoint);\n }\n\n detach(): void {\n this._clearPanelClasses();\n this._lastPosition = null;\n this._previousPushAmount = null;\n this._resizeSubscription.unsubscribe();\n }\n\n /** Cleanup after the element gets destroyed. */\n dispose(): void {\n if (this._isDisposed) {\n return;\n }\n\n // We can't use `_resetBoundingBoxStyles` here, because it resets\n // some properties to zero, rather than removing them.\n if (this._boundingBox) {\n extendStyles(this._boundingBox.style, {\n top: '',\n left: '',\n right: '',\n bottom: '',\n height: '',\n width: '',\n alignItems: '',\n justifyContent: '',\n } as CSSStyleDeclaration);\n }\n\n if (this._pane) {\n this._resetOverlayElementStyles();\n }\n\n if (this._overlayRef) {\n this._overlayRef.hostElement.classList.remove(boundingBoxClass);\n }\n\n this.detach();\n this._positionChanges.complete();\n this._overlayRef = this._boundingBox = null!;\n this._isDisposed = true;\n }\n\n /**\n * This re-aligns the overlay element with the trigger in its last calculated position,\n * even if a position higher in the \"preferred positions\" list would now fit. This\n * allows one to re-align the panel without changing the orientation of the panel.\n */\n reapplyLastPosition(): void {\n if (!this._isDisposed && (!this._platform || this._platform.isBrowser)) {\n this._originRect = this._getOriginRect();\n this._overlayRect = this._pane.getBoundingClientRect();\n this._viewportRect = this._getNarrowedViewportRect();\n\n const lastPosition = this._lastPosition || this._preferredPositions[0];\n const originPoint = this._getOriginPoint(this._originRect, lastPosition);\n\n this._applyPosition(lastPosition, originPoint);\n }\n }\n\n /**\n * Sets the list of Scrollable containers that host the origin element so that\n * on reposition we can evaluate if it or the overlay has been clipped or outside view. Every\n * Scrollable must be an ancestor element of the strategy's origin element.\n */\n withScrollableContainers(scrollables: CdkScrollable[]): this {\n this._scrollables = scrollables;\n return this;\n }\n\n /**\n * Adds new preferred positions.\n * @param positions List of positions options for this overlay.\n */\n withPositions(positions: ConnectedPosition[]): this {\n this._preferredPositions = positions;\n\n // If the last calculated position object isn't part of the positions anymore, clear\n // it in order to avoid it being picked up if the consumer tries to re-apply.\n if (positions.indexOf(this._lastPosition!) === -1) {\n this._lastPosition = null;\n }\n\n this._validatePositions();\n\n return this;\n }\n\n /**\n * Sets a minimum distance the overlay may be positioned to the edge of the viewport.\n * @param margin Required margin between the overlay and the viewport edge in pixels.\n */\n withViewportMargin(margin: number): this {\n this._viewportMargin = margin;\n return this;\n }\n\n /** Sets whether the overlay's width and height can be constrained to fit within the viewport. */\n withFlexibleDimensions(flexibleDimensions = true): this {\n this._hasFlexibleDimensions = flexibleDimensions;\n return this;\n }\n\n /** Sets whether the overlay can grow after the initial open via flexible width/height. */\n withGrowAfterOpen(growAfterOpen = true): this {\n this._growAfterOpen = growAfterOpen;\n return this;\n }\n\n /** Sets whether the overlay can be pushed on-screen if none of the provided positions fit. */\n withPush(canPush = true): this {\n this._canPush = canPush;\n return this;\n }\n\n /**\n * Sets whether the overlay's position should be locked in after it is positioned\n * initially. When an overlay is locked in, it won't attempt to reposition itself\n * when the position is re-applied (e.g. when the user scrolls away).\n * @param isLocked Whether the overlay should locked in.\n */\n withLockedPosition(isLocked = true): this {\n this._positionLocked = isLocked;\n return this;\n }\n\n /**\n * Sets the origin, relative to which to position the overlay.\n * Using an element origin is useful for building components that need to be positioned\n * relatively to a trigger (e.g. dropdown menus or tooltips), whereas using a point can be\n * used for cases like contextual menus which open relative to the user's pointer.\n * @param origin Reference to the new origin.\n */\n setOrigin(origin: FlexibleConnectedPositionStrategyOrigin): this {\n this._origin = origin;\n return this;\n }\n\n /**\n * Sets the default offset for the overlay's connection point on the x-axis.\n * @param offset New offset in the X axis.\n */\n withDefaultOffsetX(offset: number): this {\n this._offsetX = offset;\n return this;\n }\n\n /**\n * Sets the default offset for the overlay's connection point on the y-axis.\n * @param offset New offset in the Y axis.\n */\n withDefaultOffsetY(offset: number): this {\n this._offsetY = offset;\n return this;\n }\n\n /**\n * Configures that the position strategy should set a `transform-origin` on some elements\n * inside the overlay, depending on the current position that is being applied. This is\n * useful for the cases where the origin of an animation can change depending on the\n * alignment of the overlay.\n * @param selector CSS selector that will be used to find the target\n * elements onto which to set the transform origin.\n */\n withTransformOriginOn(selector: string): this {\n this._transformOriginSelector = selector;\n return this;\n }\n\n /**\n * Gets the (x, y) coordinate of a connection point on the origin based on a relative position.\n */\n private _getOriginPoint(originRect: ClientRect, pos: ConnectedPosition): Point {\n let x: number;\n if (pos.originX == 'center') {\n // Note: when centering we should always use the `left`\n // offset, otherwise the position will be wrong in RTL.\n x = originRect.left + (originRect.width / 2);\n } else {\n const startX = this._isRtl() ? originRect.right : originRect.left;\n const endX = this._isRtl() ? originRect.left : originRect.right;\n x = pos.originX == 'start' ? startX : endX;\n }\n\n let y: number;\n if (pos.originY == 'center') {\n y = originRect.top + (originRect.height / 2);\n } else {\n y = pos.originY == 'top' ? originRect.top : originRect.bottom;\n }\n\n return {x, y};\n }\n\n\n /**\n * Gets the (x, y) coordinate of the top-left corner of the overlay given a given position and\n * origin point to which the overlay should be connected.\n */\n private _getOverlayPoint(\n originPoint: Point,\n overlayRect: ClientRect,\n pos: ConnectedPosition): Point {\n\n // Calculate the (overlayStartX, overlayStartY), the start of the\n // potential overlay position relative to the origin point.\n let overlayStartX: number;\n if (pos.overlayX == 'center') {\n overlayStartX = -overlayRect.width / 2;\n } else if (pos.overlayX === 'start') {\n overlayStartX = this._isRtl() ? -overlayRect.width : 0;\n } else {\n overlayStartX = this._isRtl() ? 0 : -overlayRect.width;\n }\n\n let overlayStartY: number;\n if (pos.overlayY == 'center') {\n overlayStartY = -overlayRect.height / 2;\n } else {\n overlayStartY = pos.overlayY == 'top' ? 0 : -overlayRect.height;\n }\n\n // The (x, y) coordinates of the overlay.\n return {\n x: originPoint.x + overlayStartX,\n y: originPoint.y + overlayStartY,\n };\n }\n\n /** Gets how well an overlay at the given point will fit within the viewport. */\n private _getOverlayFit(point: Point, rawOverlayRect: ClientRect, viewport: ClientRect,\n position: ConnectedPosition): OverlayFit {\n\n // Round the overlay rect when comparing against the\n // viewport, because the viewport is always rounded.\n const overlay = getRoundedBoundingClientRect(rawOverlayRect);\n let {x, y} = point;\n let offsetX = this._getOffset(position, 'x');\n let offsetY = this._getOffset(position, 'y');\n\n // Account for the offsets since they could push the overlay out of the viewport.\n if (offsetX) {\n x += offsetX;\n }\n\n if (offsetY) {\n y += offsetY;\n }\n\n // How much the overlay would overflow at this position, on each side.\n let leftOverflow = 0 - x;\n let rightOverflow = (x + overlay.width) - viewport.width;\n let topOverflow = 0 - y;\n let bottomOverflow = (y + overlay.height) - viewport.height;\n\n // Visible parts of the element on each axis.\n let visibleWidth = this._subtractOverflows(overlay.width, leftOverflow, rightOverflow);\n let visibleHeight = this._subtractOverflows(overlay.height, topOverflow, bottomOverflow);\n let visibleArea = visibleWidth * visibleHeight;\n\n return {\n visibleArea,\n isCompletelyWithinViewport: (overlay.width * overlay.height) === visibleArea,\n fitsInViewportVertically: visibleHeight === overlay.height,\n fitsInViewportHorizontally: visibleWidth == overlay.width,\n };\n }\n\n /**\n * Whether the overlay can fit within the viewport when it may resize either its width or height.\n * @param fit How well the overlay fits in the viewport at some position.\n * @param point The (x, y) coordinates of the overlat at some position.\n * @param viewport The geometry of the viewport.\n */\n private _canFitWithFlexibleDimensions(fit: OverlayFit, point: Point, viewport: ClientRect) {\n if (this._hasFlexibleDimensions) {\n const availableHeight = viewport.bottom - point.y;\n const availableWidth = viewport.right - point.x;\n const minHeight = getPixelValue(this._overlayRef.getConfig().minHeight);\n const minWidth = getPixelValue(this._overlayRef.getConfig().minWidth);\n\n const verticalFit = fit.fitsInViewportVertically ||\n (minHeight != null && minHeight <= availableHeight);\n const horizontalFit = fit.fitsInViewportHorizontally ||\n (minWidth != null && minWidth <= availableWidth);\n\n return verticalFit && horizontalFit;\n }\n return false;\n }\n\n /**\n * Gets the point at which the overlay can be \"pushed\" on-screen. If the overlay is larger than\n * the viewport, the top-left corner will be pushed on-screen (with overflow occuring on the\n * right and bottom).\n *\n * @param start Starting point from which the overlay is pushed.\n * @param overlay Dimensions of the overlay.\n * @param scrollPosition Current viewport scroll position.\n * @returns The point at which to position the overlay after pushing. This is effectively a new\n * originPoint.\n */\n private _pushOverlayOnScreen(start: Point,\n rawOverlayRect: ClientRect,\n scrollPosition: ViewportScrollPosition): Point {\n // If the position is locked and we've pushed the overlay already, reuse the previous push\n // amount, rather than pushing it again. If we were to continue pushing, the element would\n // remain in the viewport, which goes against the expectations when position locking is enabled.\n if (this._previousPushAmount && this._positionLocked) {\n return {\n x: start.x + this._previousPushAmount.x,\n y: start.y + this._previousPushAmount.y\n };\n }\n\n // Round the overlay rect when comparing against the\n // viewport, because the viewport is always rounded.\n const overlay = getRoundedBoundingClientRect(rawOverlayRect);\n const viewport = this._viewportRect;\n\n // Determine how much the overlay goes outside the viewport on each\n // side, which we'll use to decide which direction to push it.\n const overflowRight = Math.max(start.x + overlay.width - viewport.width, 0);\n const overflowBottom = Math.max(start.y + overlay.height - viewport.height, 0);\n const overflowTop = Math.max(viewport.top - scrollPosition.top - start.y, 0);\n const overflowLeft = Math.max(viewport.left - scrollPosition.left - start.x, 0);\n\n // Amount by which to push the overlay in each axis such that it remains on-screen.\n let pushX = 0;\n let pushY = 0;\n\n // If the overlay fits completely within the bounds of the viewport, push it from whichever\n // direction is goes off-screen. Otherwise, push the top-left corner such that its in the\n // viewport and allow for the trailing end of the overlay to go out of bounds.\n if (overlay.width <= viewport.width) {\n pushX = overflowLeft || -overflowRight;\n } else {\n pushX = start.x < this._viewportMargin ? (viewport.left - scrollPosition.left) - start.x : 0;\n }\n\n if (overlay.height <= viewport.height) {\n pushY = overflowTop || -overflowBottom;\n } else {\n pushY = start.y < this._viewportMargin ? (viewport.top - scrollPosition.top) - start.y : 0;\n }\n\n this._previousPushAmount = {x: pushX, y: pushY};\n\n return {\n x: start.x + pushX,\n y: start.y + pushY,\n };\n }\n\n /**\n * Applies a computed position to the overlay and emits a position change.\n * @param position The position preference\n * @param originPoint The point on the origin element where the overlay is connected.\n */\n private _applyPosition(position: ConnectedPosition, originPoint: Point) {\n this._setTransformOrigin(position);\n this._setOverlayElementStyles(originPoint, position);\n this._setBoundingBoxStyles(originPoint, position);\n\n if (position.panelClass) {\n this._addPanelClasses(position.panelClass);\n }\n\n // Save the last connected position in case the position needs to be re-calculated.\n this._lastPosition = position;\n\n // Notify that the position has been changed along with its change properties.\n // We only emit if we've got any subscriptions, because the scroll visibility\n // calculcations can be somewhat expensive.\n if (this._positionChanges.observers.length) {\n const scrollableViewProperties = this._getScrollVisibility();\n const changeEvent = new ConnectedOverlayPositionChange(position, scrollableViewProperties);\n this._positionChanges.next(changeEvent);\n }\n\n this._isInitialRender = false;\n }\n\n /** Sets the transform origin based on the configured selector and the passed-in position. */\n private _setTransformOrigin(position: ConnectedPosition) {\n if (!this._transformOriginSelector) {\n return;\n }\n\n const elements: NodeListOf<HTMLElement> =\n this._boundingBox!.querySelectorAll(this._transformOriginSelector);\n let xOrigin: 'left' | 'right' | 'center';\n let yOrigin: 'top' | 'bottom' | 'center' = position.overlayY;\n\n if (position.overlayX === 'center') {\n xOrigin = 'center';\n } else if (this._isRtl()) {\n xOrigin = position.overlayX === 'start' ? 'right' : 'left';\n } else {\n xOrigin = position.overlayX === 'start' ? 'left' : 'right';\n }\n\n for (let i = 0; i < elements.length; i++) {\n elements[i].style.transformOrigin = `${xOrigin} ${yOrigin}`;\n }\n }\n\n /**\n * Gets the position and size of the overlay's sizing container.\n *\n * This method does no measuring and applies no styles so that we can cheaply compute the\n * bounds for all positions and choose the best fit based on these results.\n */\n private _calculateBoundingBoxRect(origin: Point, position: ConnectedPosition): BoundingBoxRect {\n const viewport = this._viewportRect;\n const isRtl = this._isRtl();\n let height: number, top: number, bottom: number;\n\n if (position.overlayY === 'top') {\n // Overlay is opening \"downward\" and thus is bound by the bottom viewport edge.\n top = origin.y;\n height = viewport.height - top + this._viewportMargin;\n } else if (position.overlayY === 'bottom') {\n // Overlay is opening \"upward\" and thus is bound by the top viewport edge. We need to add\n // the viewport margin back in, because the viewport rect is narrowed down to remove the\n // margin, whereas the `origin` position is calculated based on its `ClientRect`.\n bottom = viewport.height - origin.y + this._viewportMargin * 2;\n height = viewport.height - bottom + this._viewportMargin;\n } else {\n // If neither top nor bottom, it means that the overlay is vertically centered on the\n // origin point. Note that we want the position relative to the viewport, rather than\n // the page, which is why we don't use something like `viewport.bottom - origin.y` and\n // `origin.y - viewport.top`.\n const smallestDistanceToViewportEdge =\n Math.min(viewport.bottom - origin.y + viewport.top, origin.y);\n\n const previousHeight = this._lastBoundingBoxSize.height;\n\n height = smallestDistanceToViewportEdge * 2;\n top = origin.y - smallestDistanceToViewportEdge;\n\n if (height > previousHeight && !this._isInitialRender && !this._growAfterOpen) {\n top = origin.y - (previousHeight / 2);\n }\n }\n\n // The overlay is opening 'right-ward' (the content flows to the right).\n const isBoundedByRightViewportEdge =\n (position.overlayX === 'start' && !isRtl) ||\n (position.overlayX === 'end' && isRtl);\n\n // The overlay is opening 'left-ward' (the content flows to the left).\n const isBoundedByLeftViewportEdge =\n (position.overlayX === 'end' && !isRtl) ||\n (position.overlayX === 'start' && isRtl);\n\n let width: number, left: number, right: number;\n\n if (isBoundedByLeftViewportEdge) {\n right = viewport.width - origin.x + this._viewportMargin;\n width = origin.x - this._viewportMargin;\n } else if (isBoundedByRightViewportEdge) {\n left = origin.x;\n width = viewport.right - origin.x;\n } else {\n // If neither start nor end, it means that the overlay is horizontally centered on the\n // origin point. Note that we want the position relative to the viewport, rather than\n // the page, which is why we don't use something like `viewport.right - origin.x` and\n // `origin.x - viewport.left`.\n const smallestDistanceToViewportEdge =\n Math.min(viewport.right - origin.x + viewport.left, origin.x);\n const previousWidth = this._lastBoundingBoxSize.width;\n\n width = smallestDistanceToViewportEdge * 2;\n left = origin.x - smallestDistanceToViewportEdge;\n\n if (width > previousWidth && !this._isInitialRender && !this._growAfterOpen) {\n left = origin.x - (previousWidth / 2);\n }\n }\n\n return {top: top!, left: left!, bottom: bottom!, right: right!, width, height};\n }\n\n /**\n * Sets the position and size of the overlay's sizing wrapper. The wrapper is positioned on the\n * origin's connection point and stetches to the bounds of the viewport.\n *\n * @param origin The point on the origin element where the overlay is connected.\n * @param position The position preference\n */\n private _setBoundingBoxStyles(origin: Point, position: ConnectedPosition): void {\n const boundingBoxRect = this._calculateBoundingBoxRect(origin, position);\n\n // It's weird if the overlay *grows* while scrolling, so we take the last size into account\n // when applying a new size.\n if (!this._isInitialRender && !this._growAfterOpen) {\n boundingBoxRect.height = Math.min(boundingBoxRect.height, this._lastBoundingBoxSize.height);\n boundingBoxRect.width = Math.min(boundingBoxRect.width, this._lastBoundingBoxSize.width);\n }\n\n const styles = {} as CSSStyleDeclaration;\n\n if (this._hasExactPosition()) {\n styles.top = styles.left = '0';\n styles.bottom = styles.right = styles.maxHeight = styles.maxWidth = '';\n styles.width = styles.height = '100%';\n } else {\n const maxHeight = this._overlayRef.getConfig().maxHeight;\n const maxWidth = this._overlayRef.getConfig().maxWidth;\n\n styles.height = coerceCssPixelValue(boundingBoxRect.height);\n styles.top = coerceCssPixelValue(boundingBoxRect.top);\n styles.bottom = coerceCssPixelValue(boundingBoxRect.bottom);\n styles.width = coerceCssPixelValue(boundingBoxRect.width);\n styles.left = coerceCssPixelValue(boundingBoxRect.left);\n styles.right = coerceCssPixelValue(boundingBoxRect.right);\n\n // Push the pane content towards the proper direction.\n if (position.overlayX === 'center') {\n styles.alignItems = 'center';\n } else {\n styles.alignItems = position.overlayX === 'end' ? 'flex-end' : 'flex-start';\n }\n\n if (position.overlayY === 'center') {\n styles.justifyContent = 'center';\n } else {\n styles.justifyContent = position.overlayY === 'bottom' ? 'flex-end' : 'flex-start';\n }\n\n if (maxHeight) {\n styles.maxHeight = coerceCssPixelValue(maxHeight);\n }\n\n if (maxWidth) {\n styles.maxWidth = coerceCssPixelValue(maxWidth);\n }\n }\n\n this._lastBoundingBoxSize = boundingBoxRect;\n\n extendStyles(this._boundingBox!.style, styles);\n }\n\n /** Resets the styles for the bounding box so that a new positioning can be computed. */\n private _resetBoundingBoxStyles() {\n extendStyles(this._boundingBox!.style, {\n top: '0',\n left: '0',\n right: '0',\n bottom: '0',\n height: '',\n width: '',\n alignItems: '',\n justifyContent: '',\n } as CSSStyleDeclaration);\n }\n\n /** Resets the styles for the overlay pane so that a new positioning can be computed. */\n private _resetOverlayElementStyles() {\n extendStyles(this._pane.style, {\n top: '',\n left: '',\n bottom: '',\n right: '',\n position: '',\n transform: '',\n } as CSSStyleDeclaration);\n }\n\n /** Sets positioning styles to the overlay element. */\n private _setOverlayElementStyles(originPoint: Point, position: ConnectedPosition): void {\n const styles = {} as CSSStyleDeclaration;\n const hasExactPosition = this._hasExactPosition();\n const hasFlexibleDimensions = this._hasFlexibleDimensions;\n const config = this._overlayRef.getConfig();\n\n if (hasExactPosition) {\n const scrollPosition = this._viewportRuler.getViewportScrollPosition();\n extendStyles(styles, this._getExactOverlayY(position, originPoint, scrollPosition));\n extendStyles(styles, this._getExactOverlayX(position, originPoint, scrollPosition));\n } else {\n styles.position = 'static';\n }\n\n // Use a transform to apply the offsets. We do this because the `center` positions rely on\n // being in the normal flex flow and setting a `top` / `left` at all will completely throw\n // off the position. We also can't use margins, because they won't have an effect in some\n // cases where the element doesn't have anything to \"push off of\". Finally, this works\n // better both with flexible and non-flexible positioning.\n let transformString = '';\n let offsetX = this._getOffset(position, 'x');\n let offsetY = this._getOffset(position, 'y');\n\n if (offsetX) {\n transformString += `translateX(${offsetX}px) `;\n }\n\n if (offsetY) {\n transformString += `translateY(${offsetY}px)`;\n }\n\n styles.transform = transformString.trim();\n\n // If a maxWidth or maxHeight is specified on the overlay, we remove them. We do this because\n // we need these values to both be set to \"100%\" for the automatic flexible sizing to work.\n // The maxHeight and maxWidth are set on the boundingBox in order to enforce the constraint.\n // Note that this doesn't apply when we have an exact position, in which case we do want to\n // apply them because they'll be cleared from the bounding box.\n if (config.maxHeight) {\n if (hasExactPosition) {\n styles.maxHeight = coerceCssPixelValue(config.maxHeight);\n } else if (hasFlexibleDimensions) {\n styles.maxHeight = '';\n }\n }\n\n if (config.maxWidth) {\n if (hasExactPosition) {\n styles.maxWidth = coerceCssPixelValue(config.maxWidth);\n } else if (hasFlexibleDimensions) {\n styles.maxWidth = '';\n }\n }\n\n extendStyles(this._pane.style, styles);\n }\n\n /** Gets the exact top/bottom for the overlay when not using flexible sizing or when pushing. */\n private _getExactOverlayY(position: ConnectedPosition,\n originPoint: Point,\n scrollPosition: ViewportScrollPosition) {\n // Reset any existing styles. This is necessary in case the\n // preferred position has changed since the last `apply`.\n let styles = {top: '', bottom: ''} as CSSStyleDeclaration;\n let overlayPoint = this._getOverlayPoint(originPoint, this._overlayRect, position);\n\n if (this._isPushed) {\n overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);\n }\n\n let virtualKeyboardOffset =\n this._overlayContainer.getContainerElement().getBoundingClientRect().top;\n\n // Normally this would be zero, however when the overlay is attached to an input (e.g. in an\n // autocomplete), mobile browsers will shift everything in order to put the input in the middle\n // of the screen and to make space for the virtual keyboard. We need to account for this offset,\n // otherwise our positioning will be thrown off.\n overlayPoint.y -= virtualKeyboardOffset;\n\n // We want to set either `top` or `bottom` based on whether the overlay wants to appear\n // above or below the origin and the direction in which the element will expand.\n if (position.overlayY === 'bottom') {\n // When using `bottom`, we adjust the y position such that it is the distance\n // from the bottom of the viewport rather than the top.\n const documentHeight = this._document.documentElement!.clientHeight;\n styles.bottom = `${documentHeight - (overlayPoint.y + this._overlayRect.height)}px`;\n } else {\n styles.top = coerceCssPixelValue(overlayPoint.y);\n }\n\n return styles;\n }\n\n /** Gets the exact left/right for the overlay when not using flexible sizing or when pushing. */\n private _getExactOverlayX(position: ConnectedPosition,\n originPoint: Point,\n scrollPosition: ViewportScrollPosition) {\n // Reset any existing styles. This is necessary in case the preferred position has\n // changed since the last `apply`.\n let styles = {left: '', right: ''} as CSSStyleDeclaration;\n let overlayPoint = this._getOverlayPoint(originPoint, this._overlayRect, position);\n\n if (this._isPushed) {\n overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);\n }\n\n // We want to set either `left` or `right` based on whether the overlay wants to appear \"before\"\n // or \"after\" the origin, which determines the direction in which the element will expand.\n // For the horizontal axis, the meaning of \"before\" and \"after\" change based on whether the\n // page is in RTL or LTR.\n let horizontalStyleProperty: 'left' | 'right';\n\n if (this._isRtl()) {\n horizontalStyleProperty = position.overlayX === 'end' ? 'left' : 'right';\n } else {\n horizontalStyleProperty = position.overlayX === 'end' ? 'right' : 'left';\n }\n\n // When we're setting `right`, we adjust the x position such that it is the distance\n // from the right edge of the viewport rather than the left edge.\n if (horizontalStyleProperty === 'right') {\n const documentWidth = this._document.documentElement!.clientWidth;\n styles.right = `${documentWidth - (overlayPoint.x + this._overlayRect.width)}px`;\n } else {\n styles.left = coerceCssPixelValue(overlayPoint.x);\n }\n\n return styles;\n }\n\n /**\n * Gets the view properties of the trigger and overlay, including whether they are clipped\n * or completely outside the view of any of the strategy's scrollables.\n */\n private _getScrollVisibility(): ScrollingVisibility {\n // Note: needs fresh rects since the position could've changed.\n const originBounds = this._getOriginRect();\n const overlayBounds = this._pane.getBoundingClientRect();\n\n // TODO(jelbourn): instead of needing all of the client rects for these scrolling containers\n // every time, we should be able to use the scrollTop of the containers if the size of those\n // containers hasn't changed.\n const scrollContainerBounds = this._scrollables.map(scrollable => {\n return scrollable.getElementRef().nativeElement.getBoundingClientRect();\n });\n\n return {\n isOriginClipped: isElementClippedByScrolling(originBounds, scrollContainerBounds),\n isOriginOutsideView: isElementScrolledOutsideView(originBounds, scrollContainerBounds),\n isOverlayClipped: isElementClippedByScrolling(overlayBounds, scrollContainerBounds),\n isOverlayOutsideView: isElementScrolledOutsideView(overlayBounds, scrollContainerBounds),\n };\n }\n\n /** Subtracts the amount that an element is overflowing on an axis from its length. */\n private _subtractOverflows(length: number, ...overflows: number[]): number {\n return overflows.reduce((currentValue: number, currentOverflow: number) => {\n return currentValue - Math.max(currentOverflow, 0);\n }, length);\n }\n\n /** Narrows the given viewport rect by the current _viewportMargin. */\n private _getNarrowedViewportRect(): ClientRect {\n // We recalculate the viewport rect here ourselves, rather than using the ViewportRuler,\n // because we want to use the `clientWidth` and `clientHeight` as the base. The difference\n // being that the client properties don't include the scrollbar, as opposed to `innerWidth`\n // and `innerHeight` that do. This is necessary, because the overlay container uses\n // 100% `width` and `height` which don't include the scrollbar either.\n const width = this._document.documentElement!.clientWidth;\n const height = this._document.documentElement!.clientHeight;\n const scrollPosition = this._viewportRuler.getViewportScrollPosition();\n\n return {\n top: scrollPosition.top + this._viewportMargin,\n left: scrollPosition.left + this._viewportMargin,\n right: scrollPosition.left + width - this._viewportMargin,\n bottom: scrollPosition.top + height - this._viewportMargin,\n width: width - (2 * this._viewportMargin),\n height: height - (2 * this._viewportMargin),\n };\n }\n\n /** Whether the we're dealing with an RTL context */\n private _isRtl() {\n return this._overlayRef.getDirection() === 'rtl';\n }\n\n /** Determines whether the overlay uses exact or flexible positioning. */\n private _hasExactPosition() {\n return !this._hasFlexibleDimensions || this._isPushed;\n }\n\n /** Retrieves the offset of a position along the x or y axis. */\n private _getOffset(position: ConnectedPosition, axis: 'x' | 'y') {\n if (axis === 'x') {\n // We don't do something like `position['offset' + axis]` in\n // order to avoid breking minifiers that rename properties.\n return position.offsetX == null ? this._offsetX : position.offsetX;\n }\n\n return position.offsetY == null ? this._offsetY : position.offsetY;\n }\n\n /** Validates that the current position match the expected values. */\n private _validatePositions(): void {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!this._preferredPositions.length) {\n throw Error('FlexibleConnectedPositionStrategy: At least one position is required.');\n }\n\n // TODO(crisbeto): remove these once Angular's template type\n // checking is advanced enough to catch these cases.\n this._preferredPositions.forEach(pair => {\n validateHorizontalPosition('originX', pair.originX);\n validateVerticalPosition('originY', pair.originY);\n validateHorizontalPosition('overlayX', pair.overlayX);\n validateVerticalPosition('overlayY', pair.overlayY);\n });\n }\n }\n\n /** Adds a single CSS class or an array of classes on the overlay panel. */\n private _addPanelClasses(cssClasses: string | string[]) {\n if (this._pane) {\n coerceArray(cssClasses).forEach(cssClass => {\n if (cssClass !== '' && this._appliedPanelClasses.indexOf(cssClass) === -1) {\n this._appliedPanelClasses.push(cssClass);\n this._pane.classList.add(cssClass);\n }\n });\n }\n }\n\n /** Clears the classes that the position strategy has applied from the overlay panel. */\n private _clearPanelClasses() {\n if (this._pane) {\n this._appliedPanelClasses.forEach(cssClass => {\n this._pane.classList.remove(cssClass);\n });\n this._appliedPanelClasses = [];\n }\n }\n\n /** Returns the ClientRect of the current origin. */\n private _getOriginRect(): ClientRect {\n const origin = this._origin;\n\n if (origin instanceof ElementRef) {\n return origin.nativeElement.getBoundingClientRect();\n }\n\n // Check for Element so SVG elements are also supported.\n if (origin instanceof Element) {\n return origin.getBoundingClientRect();\n }\n\n const width = origin.width || 0;\n const height = origin.height || 0;\n\n // If the origin is a point, return a client rect as if it was a 0x0 element at the point.\n return {\n top: origin.y,\n bottom: origin.y + height,\n left: origin.x,\n right: origin.x + width,\n height,\n width\n };\n }\n}\n\n/** A simple (x, y) coordinate. */\ninterface Point {\n x: number;\n y: number;\n}\n\n/** Record of measurements for how an overlay (at a given position) fits into the viewport. */\ninterface OverlayFit {\n /** Whether the overlay fits completely in the viewport. */\n isCompletelyWithinViewport: boolean;\n\n /** Whether the overlay fits in the viewport on the y-axis. */\n fitsInViewportVertically: boolean;\n\n /** Whether the overlay fits in the viewport on the x-axis. */\n fitsInViewportHorizontally: boolean;\n\n /** The total visible area (in px^2) of the overlay inside the viewport. */\n visibleArea: number;\n}\n\n/** Record of the measurments determining whether an overlay will fit in a specific position. */\ninterface FallbackPosition {\n position: ConnectedPosition;\n originPoint: Point;\n overlayPoint: Point;\n overlayFit: OverlayFit;\n overlayRect: ClientRect;\n}\n\n/** Position and size of the overlay sizing wrapper for a specific position. */\ninterface BoundingBoxRect {\n top: number;\n left: number;\n bottom: number;\n right: number;\n height: number;\n width: number;\n}\n\n/** Record of measures determining how well a given position will fit with flexible dimensions. */\ninterface FlexibleFit {\n position: ConnectedPosition;\n origin: Point;\n overlayRect: ClientRect;\n boundingBoxRect: BoundingBoxRect;\n}\n\n/** A connected position as specified by the user. */\nexport interface ConnectedPosition {\n originX: 'start' | 'center' | 'end';\n originY: 'top' | 'center' | 'bottom';\n\n overlayX: 'start' | 'center' | 'end';\n overlayY: 'top' | 'center' | 'bottom';\n\n weight?: number;\n offsetX?: number;\n offsetY?: number;\n panelClass?: string | string[];\n}\n\n/** Shallow-extends a stylesheet object with another stylesheet object. */\nfunction extendStyles(destination: CSSStyleDeclaration,\n source: CSSStyleDeclaration): CSSStyleDeclaration {\n for (let key in source) {\n if (source.hasOwnProperty(key)) {\n destination[key] = source[key];\n }\n }\n\n return destination;\n}\n\n\n/**\n * Extracts the pixel value as a number from a value, if it's a number\n * or a CSS pixel string (e.g. `1337px`). Otherwise returns null.\n */\nfunction getPixelValue(input: number|string|null|undefined): number|null {\n if (typeof input !== 'number' && input != null) {\n const [value, units] = input.split(cssUnitPattern);\n return (!units || units === 'px') ? parseFloat(value) : null;\n }\n\n return input || null;\n}\n\n/**\n * Gets a version of an element's bounding `ClientRect` where all the values are rounded down to\n * the nearest pixel. This allows us to account for the cases where there may be sub-pixel\n * deviations in the `ClientRect` returned by the browser (e.g. when zoomed in with a percentage\n * size, see #21350).\n */\nfunction getRoundedBoundingClientRect(clientRect: ClientRect): ClientRect {\n return {\n top: Math.floor(clientRect.top),\n right: Math.floor(clientRect.right),\n bottom: Math.floor(clientRect.bottom),\n left: Math.floor(clientRect.left),\n width: Math.floor(clientRect.width),\n height: Math.floor(clientRect.height)\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 {Direction} from '@angular/cdk/bidi';\nimport {Platform} from '@angular/cdk/platform';\nimport {CdkScrollable, ViewportRuler} from '@angular/cdk/scrolling';\nimport {ElementRef} from '@angular/core';\nimport {Observable} from 'rxjs';\n\nimport {OverlayContainer} from '../overlay-container';\nimport {OverlayReference} from '../overlay-reference';\n\nimport {\n ConnectedOverlayPositionChange,\n ConnectionPositionPair,\n OriginConnectionPosition,\n OverlayConnectionPosition,\n} from './connected-position';\nimport {FlexibleConnectedPositionStrategy} from './flexible-connected-position-strategy';\nimport {PositionStrategy} from './position-strategy';\n\n/**\n * A strategy for positioning overlays. Using this strategy, an overlay is given an\n * implicit position relative to some origin element. The relative position is defined in terms of\n * a point on the origin element that is connected to a point on the overlay element. For example,\n * a basic dropdown is connecting the bottom-left corner of the origin to the top-left corner\n * of the overlay.\n * @deprecated Use `FlexibleConnectedPositionStrategy` instead.\n * @breaking-change 8.0.0\n */\nexport class ConnectedPositionStrategy implements PositionStrategy {\n /**\n * Reference to the underlying position strategy to which all the API calls are proxied.\n * @docs-private\n */\n _positionStrategy: FlexibleConnectedPositionStrategy;\n\n /** The overlay to which this strategy is attached. */\n private _overlayRef: OverlayReference;\n\n private _direction: Direction | null;\n\n /** Ordered list of preferred positions, from most to least desirable. */\n _preferredPositions: ConnectionPositionPair[] = [];\n\n /** Emits an event when the connection point changes. */\n readonly onPositionChange: Observable<ConnectedOverlayPositionChange>;\n\n constructor(\n originPos: OriginConnectionPosition, overlayPos: OverlayConnectionPosition,\n connectedTo: ElementRef<HTMLElement>, viewportRuler: ViewportRuler, document: Document,\n platform: Platform, overlayContainer: OverlayContainer) {\n // Since the `ConnectedPositionStrategy` is deprecated and we don't want to maintain\n // the extra logic, we create an instance of the positioning strategy that has some\n // defaults that make it behave as the old position strategy and to which we'll\n // proxy all of the API calls.\n this._positionStrategy = new FlexibleConnectedPositionStrategy(\n connectedTo, viewportRuler, document, platform, overlayContainer)\n .withFlexibleDimensions(false)\n .withPush(false)\n .withViewportMargin(0);\n\n this.withFallbackPosition(originPos, overlayPos);\n this.onPositionChange = this._positionStrategy.positionChanges;\n }\n\n /** Ordered list of preferred positions, from most to least desirable. */\n get positions(): ConnectionPositionPair[] {\n return this._preferredPositions;\n }\n\n /** Attach this position strategy to an overlay. */\n attach(overlayRef: OverlayReference): void {\n this._overlayRef = overlayRef;\n this._positionStrategy.attach(overlayRef);\n\n if (this._direction) {\n overlayRef.setDirection(this._direction);\n this._direction = null;\n }\n }\n\n /** Disposes all resources used by the position strategy. */\n dispose() {\n this._positionStrategy.dispose();\n }\n\n /** @docs-private */\n detach() {\n this._positionStrategy.detach();\n }\n\n /**\n * Updates the position of the overlay element, using whichever preferred position relative\n * to the origin fits on-screen.\n * @docs-private\n */\n apply(): void {\n this._positionStrategy.apply();\n }\n\n /**\n * Re-positions the overlay element with the trigger in its last calculated position,\n * even if a position higher in the \"preferred positions\" list would now fit. This\n * allows one to re-align the panel without changing the orientation of the panel.\n */\n recalculateLastPosition(): void {\n this._positionStrategy.reapplyLastPosition();\n }\n\n /**\n * Sets the list of Scrollable containers that host the origin element so that\n * on reposition we can evaluate if it or the overlay has been clipped or outside view. Every\n * Scrollable must be an ancestor element of the strategy's origin element.\n */\n withScrollableContainers(scrollables: CdkScrollable[]) {\n this._positionStrategy.withScrollableContainers(scrollables);\n }\n\n /**\n * Adds a new preferred fallback position.\n * @param originPos\n * @param overlayPos\n */\n withFallbackPosition(\n originPos: OriginConnectionPosition,\n overlayPos: OverlayConnectionPosition,\n offsetX?: number,\n offsetY?: number): this {\n\n const position = new ConnectionPositionPair(originPos, overlayPos, offsetX, offsetY);\n this._preferredPositions.push(position);\n this._positionStrategy.withPositions(this._preferredPositions);\n return this;\n }\n\n /**\n * Sets the layout direction so the overlay's position can be adjusted to match.\n * @param dir New layout direction.\n */\n withDirection(dir: 'ltr' | 'rtl'): this {\n // Since the direction might be declared before the strategy is attached,\n // we save the value in a temporary property and we'll transfer it to the\n // overlay ref on attachment.\n if (this._overlayRef) {\n this._overlayRef.setDirection(dir);\n } else {\n this._direction = dir;\n }\n\n return this;\n }\n\n /**\n * Sets an offset for the overlay's connection point on the x-axis\n * @param offset New offset in the X axis.\n */\n withOffsetX(offset: number): this {\n this._positionStrategy.withDefaultOffsetX(offset);\n return this;\n }\n\n /**\n * Sets an offset for the overlay's connection point on the y-axis\n * @param offset New offset in the Y axis.\n */\n withOffsetY(offset: number): this {\n this._positionStrategy.withDefaultOffsetY(offset);\n return this;\n }\n\n /**\n * Sets whether the overlay's position should be locked in after it is positioned\n * initially. When an overlay is locked in, it won't attempt to reposition itself\n * when the position is re-applied (e.g. when the user scrolls away).\n * @param isLocked Whether the overlay should locked in.\n */\n withLockedPosition(isLocked: boolean): this {\n this._positionStrategy.withLockedPosition(isLocked);\n return this;\n }\n\n /**\n * Overwrites the current set of positions with an array of new ones.\n * @param positions Position pairs to be set on the strategy.\n */\n withPositions(positions: ConnectionPositionPair[]): this {\n this._preferredPositions = positions.slice();\n this._positionStrategy.withPositions(this._preferredPositions);\n return this;\n }\n\n /**\n * Sets the origin element, relative to which to position the overlay.\n * @param origin Reference to the new origin element.\n */\n setOrigin(origin: ElementRef): this {\n this._positionStrategy.setOrigin(origin);\n return this;\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 {PositionStrategy} from './position-strategy';\nimport {OverlayReference} from '../overlay-reference';\n\n/** Class to be added to the overlay pane wrapper. */\nconst wrapperClass = 'cdk-global-overlay-wrapper';\n\n/**\n * A strategy for positioning overlays. Using this strategy, an overlay is given an\n * explicit position relative to the browser's viewport. We use flexbox, instead of\n * transforms, in order to avoid issues with subpixel rendering which can cause the\n * element to become blurry.\n */\nexport class GlobalPositionStrategy implements PositionStrategy {\n /** The overlay to which this strategy is attached. */\n private _overlayRef: OverlayReference;\n private _cssPosition: string = 'static';\n private _topOffset: string = '';\n private _bottomOffset: string = '';\n private _leftOffset: string = '';\n private _rightOffset: string = '';\n private _alignItems: string = '';\n private _justifyContent: string = '';\n private _width: string = '';\n private _height: string = '';\n private _isDisposed: boolean;\n\n attach(overlayRef: OverlayReference): void {\n const config = overlayRef.getConfig();\n\n this._overlayRef = overlayRef;\n\n if (this._width && !config.width) {\n overlayRef.updateSize({width: this._width});\n }\n\n if (this._height && !config.height) {\n overlayRef.updateSize({height: this._height});\n }\n\n overlayRef.hostElement.classList.add(wrapperClass);\n this._isDisposed = false;\n }\n\n /**\n * Sets the top position of the overlay. Clears any previously set vertical position.\n * @param value New top offset.\n */\n top(value: string = ''): this {\n this._bottomOffset = '';\n this._topOffset = value;\n this._alignItems = 'flex-start';\n return this;\n }\n\n /**\n * Sets the left position of the overlay. Clears any previously set horizontal position.\n * @param value New left offset.\n */\n left(value: string = ''): this {\n this._rightOffset = '';\n this._leftOffset = value;\n this._justifyContent = 'flex-start';\n return this;\n }\n\n /**\n * Sets the bottom position of the overlay. Clears any previously set vertical position.\n * @param value New bottom offset.\n */\n bottom(value: string = ''): this {\n this._topOffset = '';\n this._bottomOffset = value;\n this._alignItems = 'flex-end';\n return this;\n }\n\n /**\n * Sets the right position of the overlay. Clears any previously set horizontal position.\n * @param value New right offset.\n */\n right(value: string = ''): this {\n this._leftOffset = '';\n this._rightOffset = value;\n this._justifyContent = 'flex-end';\n return this;\n }\n\n /**\n * Sets the overlay width and clears any previously set width.\n * @param value New width for the overlay\n * @deprecated Pass the `width` through the `OverlayConfig`.\n * @breaking-change 8.0.0\n */\n width(value: string = ''): this {\n if (this._overlayRef) {\n this._overlayRef.updateSize({width: value});\n } else {\n this._width = value;\n }\n\n return this;\n }\n\n /**\n * Sets the overlay height and clears any previously set height.\n * @param value New height for the overlay\n * @deprecated Pass the `height` through the `OverlayConfig`.\n * @breaking-change 8.0.0\n */\n height(value: string = ''): this {\n if (this._overlayRef) {\n this._overlayRef.updateSize({height: value});\n } else {\n this._height = value;\n }\n\n return this;\n }\n\n /**\n * Centers the overlay horizontally with an optional offset.\n * Clears any previously set horizontal position.\n *\n * @param offset Overlay offset from the horizontal center.\n */\n centerHorizontally(offset: string = ''): this {\n this.left(offset);\n this._justifyContent = 'center';\n return this;\n }\n\n /**\n * Centers the overlay vertically with an optional offset.\n * Clears any previously set vertical position.\n *\n * @param offset Overlay offset from the vertical center.\n */\n centerVertically(offset: string = ''): this {\n this.top(offset);\n this._alignItems = 'center';\n return this;\n }\n\n /**\n * Apply the position to the element.\n * @docs-private\n */\n apply(): void {\n // Since the overlay ref applies the strategy asynchronously, it could\n // have been disposed before it ends up being applied. If that is the\n // case, we shouldn't do anything.\n if (!this._overlayRef || !this._overlayRef.hasAttached()) {\n return;\n }\n\n const styles = this._overlayRef.overlayElement.style;\n const parentStyles = this._overlayRef.hostElement.style;\n const config = this._overlayRef.getConfig();\n const {width, height, maxWidth, maxHeight} = config;\n const shouldBeFlushHorizontally = (width === '100%' || width === '100vw') &&\n (!maxWidth || maxWidth === '100%' || maxWidth === '100vw');\n const shouldBeFlushVertically = (height === '100%' || height === '100vh') &&\n (!maxHeight || maxHeight === '100%' || maxHeight === '100vh');\n\n styles.position = this._cssPosition;\n styles.marginLeft = shouldBeFlushHorizontally ? '0' : this._leftOffset;\n styles.marginTop = shouldBeFlushVertically ? '0' : this._topOffset;\n styles.marginBottom = this._bottomOffset;\n styles.marginRight = this._rightOffset;\n\n if (shouldBeFlushHorizontally) {\n parentStyles.justifyContent = 'flex-start';\n } else if (this._justifyContent === 'center') {\n parentStyles.justifyContent = 'center';\n } else if (this._overlayRef.getConfig().direction === 'rtl') {\n // In RTL the browser will invert `flex-start` and `flex-end` automatically, but we\n // don't want that because our positioning is explicitly `left` and `right`, hence\n // why we do another inversion to ensure that the overlay stays in the same position.\n // TODO: reconsider this if we add `start` and `end` methods.\n if (this._justifyContent === 'flex-start') {\n parentStyles.justifyContent = 'flex-end';\n } else if (this._justifyContent === 'flex-end') {\n parentStyles.justifyContent = 'flex-start';\n }\n } else {\n parentStyles.justifyContent = this._justifyContent;\n }\n\n parentStyles.alignItems = shouldBeFlushVertically ? 'flex-start' : this._alignItems;\n }\n\n /**\n * Cleans up the DOM changes from the position strategy.\n * @docs-private\n */\n dispose(): void {\n if (this._isDisposed || !this._overlayRef) {\n return;\n }\n\n const styles = this._overlayRef.overlayElement.style;\n const parent = this._overlayRef.hostElement;\n const parentStyles = parent.style;\n\n parent.classList.remove(wrapperClass);\n parentStyles.justifyContent = parentStyles.alignItems = styles.marginTop =\n styles.marginBottom = styles.marginLeft = styles.marginRight = styles.position = '';\n\n this._overlayRef = null!;\n this._isDisposed = true;\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 {Platform} from '@angular/cdk/platform';\nimport {ViewportRuler} from '@angular/cdk/scrolling';\nimport {DOCUMENT} from '@angular/common';\nimport {ElementRef, Inject, Injectable} from '@angular/core';\n\nimport {OverlayContainer} from '../overlay-container';\n\nimport {OriginConnectionPosition, OverlayConnectionPosition} from './connected-position';\nimport {ConnectedPositionStrategy} from './connected-position-strategy';\nimport {\n FlexibleConnectedPositionStrategy,\n FlexibleConnectedPositionStrategyOrigin,\n} from './flexible-connected-position-strategy';\nimport {GlobalPositionStrategy} from './global-position-strategy';\n\n\n/** Builder for overlay position strategy. */\n@Injectable({providedIn: 'root'})\nexport class OverlayPositionBuilder {\n constructor(\n private _viewportRuler: ViewportRuler, @Inject(DOCUMENT) private _document: any,\n private _platform: Platform, private _overlayContainer: OverlayContainer) {}\n\n /**\n * Creates a global position strategy.\n */\n global(): GlobalPositionStrategy {\n return new GlobalPositionStrategy();\n }\n\n /**\n * Creates a relative position strategy.\n * @param elementRef\n * @param originPos\n * @param overlayPos\n * @deprecated Use `flexibleConnectedTo` instead.\n * @breaking-change 8.0.0\n */\n connectedTo(\n elementRef: ElementRef,\n originPos: OriginConnectionPosition,\n overlayPos: OverlayConnectionPosition): ConnectedPositionStrategy {\n return new ConnectedPositionStrategy(\n originPos, overlayPos, elementRef, this._viewportRuler, this._document, this._platform,\n this._overlayContainer);\n }\n\n /**\n * Creates a flexible position strategy.\n * @param origin Origin relative to which to position the overlay.\n */\n flexibleConnectedTo(origin: FlexibleConnectedPositionStrategyOrigin):\n FlexibleConnectedPositionStrategy {\n return new FlexibleConnectedPositionStrategy(origin, this._viewportRuler, this._document,\n this._platform, this._overlayContainer);\n }\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 {Directionality} from '@angular/cdk/bidi';\nimport {DomPortalOutlet} from '@angular/cdk/portal';\nimport {DOCUMENT, Location} from '@angular/common';\nimport {\n ApplicationRef,\n ComponentFactoryResolver,\n Inject,\n Injectable,\n Injector,\n NgZone,\n} from '@angular/core';\nimport {OverlayKeyboardDispatcher} from './dispatchers/overlay-keyboard-dispatcher';\nimport {OverlayOutsideClickDispatcher} from './dispatchers/overlay-outside-click-dispatcher';\nimport {OverlayConfig} from './overlay-config';\nimport {OverlayContainer} from './overlay-container';\nimport {OverlayRef} from './overlay-ref';\nimport {OverlayPositionBuilder} from './position/overlay-position-builder';\nimport {ScrollStrategyOptions} from './scroll/index';\n\n\n/** Next overlay unique ID. */\nlet nextUniqueId = 0;\n\n// Note that Overlay is *not* scoped to the app root because of the ComponentFactoryResolver\n// which needs to be different depending on where OverlayModule is imported.\n\n/**\n * Service to create Overlays. Overlays are dynamically added pieces of floating UI, meant to be\n * used as a low-level building block for other components. Dialogs, tooltips, menus,\n * selects, etc. can all be built using overlays. The service should primarily be used by authors\n * of re-usable components rather than developers building end-user applications.\n *\n * An overlay *is* a PortalOutlet, so any kind of Portal can be loaded into one.\n */\n@Injectable()\nexport class Overlay {\n private _appRef: ApplicationRef;\n\n constructor(\n /** Scrolling strategies that can be used when creating an overlay. */\n public scrollStrategies: ScrollStrategyOptions,\n private _overlayContainer: OverlayContainer,\n private _componentFactoryResolver: ComponentFactoryResolver,\n private _positionBuilder: OverlayPositionBuilder,\n private _keyboardDispatcher: OverlayKeyboardDispatcher,\n private _injector: Injector,\n private _ngZone: NgZone,\n @Inject(DOCUMENT) private _document: any,\n private _directionality: Directionality,\n private _location: Location,\n private _outsideClickDispatcher: OverlayOutsideClickDispatcher) { }\n\n /**\n * Creates an overlay.\n * @param config Configuration applied to the overlay.\n * @returns Reference to the created overlay.\n */\n create(config?: OverlayConfig): OverlayRef {\n const host = this._createHostElement();\n const pane = this._createPaneElement(host);\n const portalOutlet = this._createPortalOutlet(pane);\n const overlayConfig = new OverlayConfig(config);\n\n overlayConfig.direction = overlayConfig.direction || this._directionality.value;\n\n return new OverlayRef(portalOutlet, host, pane, overlayConfig, this._ngZone,\n this._keyboardDispatcher, this._document, this._location, this._outsideClickDispatcher);\n }\n\n /**\n * Gets a position builder that can be used, via fluent API,\n * to construct and configure a position strategy.\n * @returns An overlay position builder.\n */\n position(): OverlayPositionBuilder {\n return this._positionBuilder;\n }\n\n /**\n * Creates the DOM element for an overlay and appends it to the overlay container.\n * @returns Newly-created pane element\n */\n private _createPaneElement(host: HTMLElement): HTMLElement {\n const pane = this._document.createElement('div');\n\n pane.id = `cdk-overlay-${nextUniqueId++}`;\n pane.classList.add('cdk-overlay-pane');\n host.appendChild(pane);\n\n return pane;\n }\n\n /**\n * Creates the host element that wraps around an overlay\n * and can be used for advanced positioning.\n * @returns Newly-create host element.\n */\n private _createHostElement(): HTMLElement {\n const host = this._document.createElement('div');\n this._overlayContainer.getContainerElement().appendChild(host);\n return host;\n }\n\n /**\n * Create a DomPortalOutlet into which the overlay content can be loaded.\n * @param pane The DOM element to turn into a portal outlet.\n * @returns A portal outlet for the given DOM element.\n */\n private _createPortalOutlet(pane: HTMLElement): DomPortalOutlet {\n // We have to resolve the ApplicationRef later in order to allow people\n // to use overlay-based providers during app initialization.\n if (!this._appRef) {\n this._appRef = this._injector.get<ApplicationRef>(ApplicationRef);\n }\n\n return new DomPortalOutlet(pane, this._componentFactoryResolver, this._appRef, this._injector,\n this._document);\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 {Direction, Directionality} from '@angular/cdk/bidi';\nimport {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ESCAPE, hasModifierKey} from '@angular/cdk/keycodes';\nimport {TemplatePortal} from '@angular/cdk/portal';\nimport {\n Directive,\n ElementRef,\n EventEmitter,\n Inject,\n InjectionToken,\n Input,\n OnChanges,\n OnDestroy,\n Optional,\n Output,\n SimpleChanges,\n TemplateRef,\n ViewContainerRef,\n} from '@angular/core';\nimport {Subscription} from 'rxjs';\nimport {takeWhile} from 'rxjs/operators';\nimport {Overlay} from './overlay';\nimport {OverlayConfig} from './overlay-config';\nimport {OverlayRef} from './overlay-ref';\nimport {ConnectedOverlayPositionChange} from './position/connected-position';\nimport {\n ConnectedPosition,\n FlexibleConnectedPositionStrategy,\n} from './position/flexible-connected-position-strategy';\nimport {\n RepositionScrollStrategy,\n ScrollStrategy,\n} from './scroll/index';\n\n\n/** Default set of positions for the overlay. Follows the behavior of a dropdown. */\nconst defaultPositionList: ConnectedPosition[] = [\n {\n originX: 'start',\n originY: 'bottom',\n overlayX: 'start',\n overlayY: 'top'\n },\n {\n originX: 'start',\n originY: 'top',\n overlayX: 'start',\n overlayY: 'bottom'\n },\n {\n originX: 'end',\n originY: 'top',\n overlayX: 'end',\n overlayY: 'bottom'\n },\n {\n originX: 'end',\n originY: 'bottom',\n overlayX: 'end',\n overlayY: 'top'\n }\n];\n\n/** Injection token that determines the scroll handling while the connected overlay is open. */\nexport const CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY =\n new InjectionToken<() => ScrollStrategy>('cdk-connected-overlay-scroll-strategy');\n\n/**\n * Directive applied to an element to make it usable as an origin for an Overlay using a\n * ConnectedPositionStrategy.\n */\n@Directive({\n selector: '[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]',\n exportAs: 'cdkOverlayOrigin',\n})\nexport class CdkOverlayOrigin {\n constructor(\n /** Reference to the element on which the directive is applied. */\n public elementRef: ElementRef) { }\n}\n\n\n/**\n * Directive to facilitate declarative creation of an\n * Overlay using a FlexibleConnectedPositionStrategy.\n */\n@Directive({\n selector: '[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]',\n exportAs: 'cdkConnectedOverlay'\n})\nexport class CdkConnectedOverlay implements OnDestroy, OnChanges {\n private _overlayRef: OverlayRef;\n private _templatePortal: TemplatePortal;\n private _hasBackdrop = false;\n private _lockPosition = false;\n private _growAfterOpen = false;\n private _flexibleDimensions = false;\n private _push = false;\n private _backdropSubscription = Subscription.EMPTY;\n private _attachSubscription = Subscription.EMPTY;\n private _detachSubscription = Subscription.EMPTY;\n private _positionSubscription = Subscription.EMPTY;\n private _offsetX: number;\n private _offsetY: number;\n private _position: FlexibleConnectedPositionStrategy;\n private _scrollStrategyFactory: () => ScrollStrategy;\n\n /** Origin for the connected overlay. */\n @Input('cdkConnectedOverlayOrigin') origin: CdkOverlayOrigin;\n\n /** Registered connected position pairs. */\n @Input('cdkConnectedOverlayPositions') positions: ConnectedPosition[];\n\n /**\n * This input overrides the positions input if specified. It lets users pass\n * in arbitrary positioning strategies.\n */\n @Input('cdkConnectedOverlayPositionStrategy') positionStrategy: FlexibleConnectedPositionStrategy;\n\n /** The offset in pixels for the overlay connection point on the x-axis */\n @Input('cdkConnectedOverlayOffsetX')\n get offsetX(): number { return this._offsetX; }\n set offsetX(offsetX: number) {\n this._offsetX = offsetX;\n\n if (this._position) {\n this._updatePositionStrategy(this._position);\n }\n }\n\n /** The offset in pixels for the overlay connection point on the y-axis */\n @Input('cdkConnectedOverlayOffsetY')\n get offsetY() { return this._offsetY; }\n set offsetY(offsetY: number) {\n this._offsetY = offsetY;\n\n if (this._position) {\n this._updatePositionStrategy(this._position);\n }\n }\n\n /** The width of the overlay panel. */\n @Input('cdkConnectedOverlayWidth') width: number | string;\n\n /** The height of the overlay panel. */\n @Input('cdkConnectedOverlayHeight') height: number | string;\n\n /** The min width of the overlay panel. */\n @Input('cdkConnectedOverlayMinWidth') minWidth: number | string;\n\n /** The min height of the overlay panel. */\n @Input('cdkConnectedOverlayMinHeight') minHeight: number | string;\n\n /** The custom class to be set on the backdrop element. */\n @Input('cdkConnectedOverlayBackdropClass') backdropClass: string;\n\n /** The custom class to add to the overlay pane element. */\n @Input('cdkConnectedOverlayPanelClass') panelClass: string | string[];\n\n /** Margin between the overlay and the viewport edges. */\n @Input('cdkConnectedOverlayViewportMargin') viewportMargin: number = 0;\n\n /** Strategy to be used when handling scroll events while the overlay is open. */\n @Input('cdkConnectedOverlayScrollStrategy') scrollStrategy: ScrollStrategy;\n\n /** Whether the overlay is open. */\n @Input('cdkConnectedOverlayOpen') open: boolean = false;\n\n /** Whether the overlay can be closed by user interaction. */\n @Input('cdkConnectedOverlayDisableClose') disableClose: boolean = false;\n\n /** CSS selector which to set the transform origin. */\n @Input('cdkConnectedOverlayTransformOriginOn') transformOriginSelector: string;\n\n /** Whether or not the overlay should attach a backdrop. */\n @Input('cdkConnectedOverlayHasBackdrop')\n get hasBackdrop() { return this._hasBackdrop; }\n set hasBackdrop(value: any) { this._hasBackdrop = coerceBooleanProperty(value); }\n\n /** Whether or not the overlay should be locked when scrolling. */\n @Input('cdkConnectedOverlayLockPosition')\n get lockPosition() { return this._lockPosition; }\n set lockPosition(value: any) { this._lockPosition = coerceBooleanProperty(value); }\n\n /** Whether the overlay's width and height can be constrained to fit within the viewport. */\n @Input('cdkConnectedOverlayFlexibleDimensions')\n get flexibleDimensions() { return this._flexibleDimensions; }\n set flexibleDimensions(value: boolean) {\n this._flexibleDimensions = coerceBooleanProperty(value);\n }\n\n /** Whether the overlay can grow after the initial open when flexible positioning is turned on. */\n @Input('cdkConnectedOverlayGrowAfterOpen')\n get growAfterOpen() { return this._growAfterOpen; }\n set growAfterOpen(value: boolean) { this._growAfterOpen = coerceBooleanProperty(value); }\n\n /** Whether the overlay can be pushed on-screen if none of the provided positions fit. */\n @Input('cdkConnectedOverlayPush')\n get push() { return this._push; }\n set push(value: boolean) { this._push = coerceBooleanProperty(value); }\n\n /** Event emitted when the backdrop is clicked. */\n @Output() readonly backdropClick = new EventEmitter<MouseEvent>();\n\n /** Event emitted when the position has changed. */\n @Output() readonly positionChange = new EventEmitter<ConnectedOverlayPositionChange>();\n\n /** Event emitted when the overlay has been attached. */\n @Output() readonly attach = new EventEmitter<void>();\n\n /** Event emitted when the overlay has been detached. */\n @Output() readonly detach = new EventEmitter<void>();\n\n /** Emits when there are keyboard events that are targeted at the overlay. */\n @Output() readonly overlayKeydown = new EventEmitter<KeyboardEvent>();\n\n /** Emits when there are mouse outside click events that are targeted at the overlay. */\n @Output() readonly overlayOutsideClick = new EventEmitter<MouseEvent>();\n\n // TODO(jelbourn): inputs for size, scroll behavior, animation, etc.\n\n constructor(\n private _overlay: Overlay,\n templateRef: TemplateRef<any>,\n viewContainerRef: ViewContainerRef,\n @Inject(CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY) scrollStrategyFactory: any,\n @Optional() private _dir: Directionality) {\n this._templatePortal = new TemplatePortal(templateRef, viewContainerRef);\n this._scrollStrategyFactory = scrollStrategyFactory;\n this.scrollStrategy = this._scrollStrategyFactory();\n }\n\n /** The associated overlay reference. */\n get overlayRef(): OverlayRef {\n return this._overlayRef;\n }\n\n /** The element's layout direction. */\n get dir(): Direction {\n return this._dir ? this._dir.value : 'ltr';\n }\n\n ngOnDestroy() {\n this._attachSubscription.unsubscribe();\n this._detachSubscription.unsubscribe();\n this._backdropSubscription.unsubscribe();\n this._positionSubscription.unsubscribe();\n\n if (this._overlayRef) {\n this._overlayRef.dispose();\n }\n }\n\n ngOnChanges(changes: SimpleChanges) {\n if (this._position) {\n this._updatePositionStrategy(this._position);\n this._overlayRef.updateSize({\n width: this.width,\n minWidth: this.minWidth,\n height: this.height,\n minHeight: this.minHeight,\n });\n\n if (changes['origin'] && this.open) {\n this._position.apply();\n }\n }\n\n if (changes['open']) {\n this.open ? this._attachOverlay() : this._detachOverlay();\n }\n }\n\n /** Creates an overlay */\n private _createOverlay() {\n if (!this.positions || !this.positions.length) {\n this.positions = defaultPositionList;\n }\n\n const overlayRef = this._overlayRef = this._overlay.create(this._buildConfig());\n this._attachSubscription = overlayRef.attachments().subscribe(() => this.attach.emit());\n this._detachSubscription = overlayRef.detachments().subscribe(() => this.detach.emit());\n overlayRef.keydownEvents().subscribe((event: KeyboardEvent) => {\n this.overlayKeydown.next(event);\n\n if (event.keyCode === ESCAPE && !this.disableClose && !hasModifierKey(event)) {\n event.preventDefault();\n this._detachOverlay();\n }\n });\n\n this._overlayRef.outsidePointerEvents().subscribe((event: MouseEvent) => {\n this.overlayOutsideClick.next(event);\n });\n }\n\n /** Builds the overlay config based on the directive's inputs */\n private _buildConfig(): OverlayConfig {\n const positionStrategy = this._position =\n this.positionStrategy || this._createPositionStrategy();\n const overlayConfig = new OverlayConfig({\n direction: this._dir,\n positionStrategy,\n scrollStrategy: this.scrollStrategy,\n hasBackdrop: this.hasBackdrop\n });\n\n if (this.width || this.width === 0) {\n overlayConfig.width = this.width;\n }\n\n if (this.height || this.height === 0) {\n overlayConfig.height = this.height;\n }\n\n if (this.minWidth || this.minWidth === 0) {\n overlayConfig.minWidth = this.minWidth;\n }\n\n if (this.minHeight || this.minHeight === 0) {\n overlayConfig.minHeight = this.minHeight;\n }\n\n if (this.backdropClass) {\n overlayConfig.backdropClass = this.backdropClass;\n }\n\n if (this.panelClass) {\n overlayConfig.panelClass = this.panelClass;\n }\n\n return overlayConfig;\n }\n\n /** Updates the state of a position strategy, based on the values of the directive inputs. */\n private _updatePositionStrategy(positionStrategy: FlexibleConnectedPositionStrategy) {\n const positions: ConnectedPosition[] = this.positions.map(currentPosition => ({\n originX: currentPosition.originX,\n originY: currentPosition.originY,\n overlayX: currentPosition.overlayX,\n overlayY: currentPosition.overlayY,\n offsetX: currentPosition.offsetX || this.offsetX,\n offsetY: currentPosition.offsetY || this.offsetY,\n panelClass: currentPosition.panelClass || undefined,\n }));\n\n return positionStrategy\n .setOrigin(this.origin.elementRef)\n .withPositions(positions)\n .withFlexibleDimensions(this.flexibleDimensions)\n .withPush(this.push)\n .withGrowAfterOpen(this.growAfterOpen)\n .withViewportMargin(this.viewportMargin)\n .withLockedPosition(this.lockPosition)\n .withTransformOriginOn(this.transformOriginSelector);\n }\n\n /** Returns the position strategy of the overlay to be set on the overlay config */\n private _createPositionStrategy(): FlexibleConnectedPositionStrategy {\n const strategy = this._overlay.position().flexibleConnectedTo(this.origin.elementRef);\n this._updatePositionStrategy(strategy);\n return strategy;\n }\n\n /** Attaches the overlay and subscribes to backdrop clicks if backdrop exists */\n private _attachOverlay() {\n if (!this._overlayRef) {\n this._createOverlay();\n } else {\n // Update the overlay size, in case the directive's inputs have changed\n this._overlayRef.getConfig().hasBackdrop = this.hasBackdrop;\n }\n\n if (!this._overlayRef.hasAttached()) {\n this._overlayRef.attach(this._templatePortal);\n }\n\n if (this.hasBackdrop) {\n this._backdropSubscription = this._overlayRef.backdropClick().subscribe(event => {\n this.backdropClick.emit(event);\n });\n } else {\n this._backdropSubscription.unsubscribe();\n }\n\n this._positionSubscription.unsubscribe();\n\n // Only subscribe to `positionChanges` if requested, because putting\n // together all the information for it can be expensive.\n if (this.positionChange.observers.length > 0) {\n this._positionSubscription = this._position.positionChanges\n .pipe(takeWhile(() => this.positionChange.observers.length > 0))\n .subscribe(position => {\n this.positionChange.emit(position);\n\n if (this.positionChange.observers.length === 0) {\n this._positionSubscription.unsubscribe();\n }\n });\n }\n }\n\n /** Detaches the overlay and unsubscribes to backdrop clicks if backdrop exists */\n private _detachOverlay() {\n if (this._overlayRef) {\n this._overlayRef.detach();\n }\n\n this._backdropSubscription.unsubscribe();\n this._positionSubscription.unsubscribe();\n }\n\n static ngAcceptInputType_hasBackdrop: BooleanInput;\n static ngAcceptInputType_lockPosition: BooleanInput;\n static ngAcceptInputType_flexibleDimensions: BooleanInput;\n static ngAcceptInputType_growAfterOpen: BooleanInput;\n static ngAcceptInputType_push: BooleanInput;\n}\n\n\n/** @docs-private */\nexport function CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY(overlay: Overlay):\n () => RepositionScrollStrategy {\n return () => overlay.scrollStrategies.reposition();\n}\n\n/** @docs-private */\nexport const CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER = {\n provide: CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY,\n deps: [Overlay],\n useFactory: CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY,\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 {BidiModule} from '@angular/cdk/bidi';\nimport {PortalModule} from '@angular/cdk/portal';\nimport {ScrollingModule} from '@angular/cdk/scrolling';\nimport {NgModule} from '@angular/core';\nimport {Overlay} from './overlay';\nimport {\n CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER,\n CdkConnectedOverlay,\n CdkOverlayOrigin,\n} from './overlay-directives';\n\n\n@NgModule({\n imports: [BidiModule, PortalModule, ScrollingModule],\n exports: [CdkConnectedOverlay, CdkOverlayOrigin, ScrollingModule],\n declarations: [CdkConnectedOverlay, CdkOverlayOrigin],\n providers: [\n Overlay,\n CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER,\n ],\n})\nexport class OverlayModule {}\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 {OverlayOutsideClickDispatcher} from './overlay-outside-click-dispatcher';\nexport {OverlayKeyboardDispatcher} from './overlay-keyboard-dispatcher';\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 {Injectable, Inject, OnDestroy} from '@angular/core';\nimport {OverlayContainer} from './overlay-container';\nimport {DOCUMENT} from '@angular/common';\nimport {Platform} from '@angular/cdk/platform';\n\n\n/**\n * Alternative to OverlayContainer that supports correct displaying of overlay elements in\n * Fullscreen mode\n * https://developer.mozilla.org/en-US/docs/Web/API/Element/requestFullScreen\n *\n * Should be provided in the root component.\n */\n@Injectable({providedIn: 'root'})\nexport class FullscreenOverlayContainer extends OverlayContainer implements OnDestroy {\n private _fullScreenEventName: string | undefined;\n private _fullScreenListener: () => void;\n\n constructor(@Inject(DOCUMENT) _document: any, platform: Platform) {\n super(_document, platform);\n }\n\n override ngOnDestroy() {\n super.ngOnDestroy();\n\n if (this._fullScreenEventName && this._fullScreenListener) {\n this._document.removeEventListener(this._fullScreenEventName, this._fullScreenListener);\n }\n }\n\n protected override _createContainer(): void {\n super._createContainer();\n this._adjustParentForFullscreenChange();\n this._addFullscreenChangeListener(() => this._adjustParentForFullscreenChange());\n }\n\n private _adjustParentForFullscreenChange(): void {\n if (!this._containerElement) {\n return;\n }\n\n const fullscreenElement = this.getFullscreenElement();\n const parent = fullscreenElement || this._document.body;\n parent.appendChild(this._containerElement);\n }\n\n private _addFullscreenChangeListener(fn: () => void) {\n const eventName = this._getEventName();\n\n if (eventName) {\n if (this._fullScreenListener) {\n this._document.removeEventListener(eventName, this._fullScreenListener);\n }\n\n this._document.addEventListener(eventName, fn);\n this._fullScreenListener = fn;\n }\n }\n\n private _getEventName(): string | undefined {\n if (!this._fullScreenEventName) {\n const _document = this._document as any;\n\n if (_document.fullscreenEnabled) {\n this._fullScreenEventName = 'fullscreenchange';\n } else if (_document.webkitFullscreenEnabled) {\n this._fullScreenEventName = 'webkitfullscreenchange';\n } else if (_document.mozFullScreenEnabled) {\n this._fullScreenEventName = 'mozfullscreenchange';\n } else if (_document.msFullscreenEnabled) {\n this._fullScreenEventName = 'MSFullscreenChange';\n }\n }\n\n return this._fullScreenEventName;\n }\n\n /**\n * When the page is put into fullscreen mode, a specific element is specified.\n * Only that element and its children are visible when in fullscreen mode.\n */\n getFullscreenElement(): Element {\n const _document = this._document as any;\n\n return _document.fullscreenElement ||\n _document.webkitFullscreenElement ||\n _document.mozFullScreenElement ||\n _document.msFullscreenElement ||\n null;\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\nexport * from './overlay-config';\nexport * from './position/connected-position';\nexport * from './scroll/index';\nexport * from './overlay-module';\nexport * from './dispatchers/index';\nexport {Overlay} from './overlay';\nexport {OverlayContainer} from './overlay-container';\nexport {CdkOverlayOrigin, CdkConnectedOverlay} from './overlay-directives';\nexport {FullscreenOverlayContainer} from './fullscreen-overlay-container';\nexport {OverlayRef, OverlaySizeConfig} from './overlay-ref';\nexport {ViewportRuler} from '@angular/cdk/scrolling';\nexport {ComponentType} from '@angular/cdk/portal';\nexport {OverlayPositionBuilder} from './position/overlay-position-builder';\n\n// Export pre-defined position strategies and interface to build custom ones.\nexport {PositionStrategy} from './position/position-strategy';\nexport {GlobalPositionStrategy} from './position/global-position-strategy';\nexport {ConnectedPositionStrategy} from './position/connected-position-strategy';\nexport {\n ConnectedPosition,\n FlexibleConnectedPositionStrategy,\n FlexibleConnectedPositionStrategyOrigin,\n} from './position/flexible-connected-position-strategy';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n\nexport {BaseOverlayDispatcher as ɵangular_material_src_cdk_overlay_overlay_d} from './dispatchers/base-overlay-dispatcher';\nexport {CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY as ɵangular_material_src_cdk_overlay_overlay_a,CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER as ɵangular_material_src_cdk_overlay_overlay_c,CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY as ɵangular_material_src_cdk_overlay_overlay_b} from './overlay-directives';"],"names":["supportsScrollBehavior","coerceCssPixelValue","Injectable","ScrollDispatcher","ViewportRuler","NgZone","Inject","DOCUMENT","Optional","_getEventTarget","Platform","_isTestEnvironment","Subject","Subscription","take","coerceArray","takeUntil","merge","ElementRef","ApplicationRef","DomPortalOutlet","ComponentFactoryResolver","Injector","Directionality","Location","InjectionToken","Directive","EventEmitter","TemplatePortal","coerceBooleanProperty","ESCAPE","hasModifierKey","takeWhile","TemplateRef","ViewContainerRef","Input","Output","NgModule","BidiModule","PortalModule","ScrollingModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAAA;;;;;;;;;;;;;;IAcA;IAEA,IAAI,aAAa,GAAG,UAAS,CAAC,EAAE,CAAC;QAC7B,aAAa,GAAG,MAAM,CAAC,cAAc;aAChC,EAAE,SAAS,EAAE,EAAE,EAAE,YAAY,KAAK,IAAI,UAAU,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,EAAE,CAAC;YAC5E,UAAU,CAAC,EAAE,CAAC,IAAI,KAAK,IAAI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