UNPKG

142 kBSource Map (JSON)View Raw
1{"version":3,"file":"angular-flex-layout-core.mjs","sources":["../../../../projects/libs/flex-layout/core/browser-provider.ts","../../../../projects/libs/flex-layout/core/module.ts","../../../../projects/libs/flex-layout/core/media-change.ts","../../../../projects/libs/flex-layout/core/stylesheet-map/stylesheet-map.ts","../../../../projects/libs/flex-layout/core/stylesheet-map/index.ts","../../../../projects/libs/flex-layout/core/tokens/library-config.ts","../../../../projects/libs/flex-layout/core/tokens/server-token.ts","../../../../projects/libs/flex-layout/core/tokens/breakpoint-token.ts","../../../../projects/libs/flex-layout/core/tokens/index.ts","../../../../projects/libs/flex-layout/core/add-alias.ts","../../../../projects/libs/flex-layout/core/style-builder/style-builder.ts","../../../../projects/libs/flex-layout/core/style-utils/style-utils.ts","../../../../projects/libs/flex-layout/core/utils/sort.ts","../../../../projects/libs/flex-layout/core/match-media/match-media.ts","../../../../projects/libs/flex-layout/core/breakpoints/data/break-points.ts","../../../../projects/libs/flex-layout/core/breakpoints/data/orientation-break-points.ts","../../../../projects/libs/flex-layout/core/breakpoints/breakpoint-tools.ts","../../../../projects/libs/flex-layout/core/breakpoints/break-points-token.ts","../../../../projects/libs/flex-layout/core/breakpoints/break-point-registry.ts","../../../../projects/libs/flex-layout/core/media-marshaller/print-hook.ts","../../../../projects/libs/flex-layout/core/media-marshaller/media-marshaller.ts","../../../../projects/libs/flex-layout/core/base/base2.ts","../../../../projects/libs/flex-layout/core/base/index.ts","../../../../projects/libs/flex-layout/core/breakpoints/index.ts","../../../../projects/libs/flex-layout/core/match-media/mock/mock-match-media.ts","../../../../projects/libs/flex-layout/core/match-media/index.ts","../../../../projects/libs/flex-layout/core/utils/array.ts","../../../../projects/libs/flex-layout/core/media-observer/media-observer.ts","../../../../projects/libs/flex-layout/core/media-observer/index.ts","../../../../projects/libs/flex-layout/core/media-trigger/media-trigger.ts","../../../../projects/libs/flex-layout/core/media-trigger/index.ts","../../../../projects/libs/flex-layout/core/utils/index.ts","../../../../projects/libs/flex-layout/core/basis-validator/basis-validator.ts","../../../../projects/libs/flex-layout/core/multiply/multiplier.ts","../../../../projects/libs/flex-layout/core/public-api.ts","../../../../projects/libs/flex-layout/core/angular-flex-layout-core.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport {APP_BOOTSTRAP_LISTENER, PLATFORM_ID, InjectionToken} from '@angular/core';\nimport {DOCUMENT, isPlatformBrowser} from '@angular/common';\n\n/**\n * Find all of the server-generated stylings, if any, and remove them\n * This will be in the form of inline classes and the style block in the\n * head of the DOM\n */\nexport function removeStyles(_document: Document, platformId: Object) {\n return () => {\n if (isPlatformBrowser(platformId)) {\n const elements = Array.from(_document.querySelectorAll(`[class*=${CLASS_NAME}]`));\n\n // RegExp constructor should only be used if passing a variable to the constructor.\n // When using static regular expression it is more performant to use reg exp literal.\n // This is also needed to provide Safari 9 compatibility, please see\n // https://stackoverflow.com/questions/37919802 for more discussion.\n const classRegex = /\\bflex-layout-.+?\\b/g;\n elements.forEach(el => {\n el.classList.contains(`${CLASS_NAME}ssr`) && el.parentNode ?\n el.parentNode.removeChild(el) : el.className.replace(classRegex, '');\n });\n }\n };\n}\n\n/**\n * Provider to remove SSR styles on the browser\n */\nexport const BROWSER_PROVIDER = {\n provide: <InjectionToken<(() => void)[]>>APP_BOOTSTRAP_LISTENER,\n useFactory: removeStyles,\n deps: [DOCUMENT, PLATFORM_ID],\n multi: true\n};\n\nexport const CLASS_NAME = 'flex-layout-';\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 {NgModule} from '@angular/core';\n\nimport {BROWSER_PROVIDER} from './browser-provider';\n\n\n/**\n * *****************************************************************\n * Define module for common Angular Layout utilities\n * *****************************************************************\n */\n@NgModule({\n providers: [BROWSER_PROVIDER]\n})\nexport class CoreModule {\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 */\nexport type MediaQuerySubscriber = (changes: MediaChange) => void;\n\n/**\n * Class instances emitted [to observers] for each mql notification\n */\nexport class MediaChange {\n property: string = '';\n value: any;\n\n /**\n * @param matches whether the mediaQuery is currently activated\n * @param mediaQuery e.g. (min-width: 600px) and (max-width: 959px)\n * @param mqAlias e.g. gt-sm, md, gt-lg\n * @param suffix e.g. GtSM, Md, GtLg\n * @param priority the priority of activation for the given breakpoint\n */\n constructor(public matches = false,\n public mediaQuery = 'all',\n public mqAlias = '',\n public suffix = '',\n public priority = 0) {\n }\n\n /** Create an exact copy of the MediaChange */\n clone(): MediaChange {\n return new MediaChange(this.matches, this.mediaQuery, this.mqAlias, this.suffix);\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 */\nimport {Injectable} from '@angular/core';\n\n/**\n * Utility to emulate a CSS stylesheet\n *\n * This utility class stores all of the styles for a given HTML element\n * as a readonly `stylesheet` map.\n */\n@Injectable({providedIn: 'root'})\nexport class StylesheetMap {\n\n readonly stylesheet = new Map<HTMLElement, Map<string, string|number>>();\n\n /**\n * Add an individual style to an HTML element\n */\n addStyleToElement(element: HTMLElement, style: string, value: string|number) {\n const stylesheet = this.stylesheet.get(element);\n if (stylesheet) {\n stylesheet.set(style, value);\n } else {\n this.stylesheet.set(element, new Map([[style, value]]));\n }\n }\n\n /**\n * Clear the virtual stylesheet\n */\n clearStyles() {\n this.stylesheet.clear();\n }\n\n /**\n * Retrieve a given style for an HTML element\n */\n getStyleForElement(el: HTMLElement, styleName: string): string {\n const styles = this.stylesheet.get(el);\n let value = '';\n if (styles) {\n const style = styles.get(styleName);\n if (typeof style === 'number' || typeof style === 'string') {\n value = style + '';\n }\n }\n return value;\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 './stylesheet-map';\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 {InjectionToken} from '@angular/core';\nimport {Multiplier} from '../multiply/multiplier';\n\n/** a set of configuration options for FlexLayoutModule */\nexport interface LayoutConfigOptions {\n addFlexToParent?: boolean;\n addOrientationBps?: boolean;\n disableDefaultBps?: boolean;\n disableVendorPrefixes?: boolean;\n serverLoaded?: boolean;\n useColumnBasisZero?: boolean;\n printWithBreakpoints?: string[];\n mediaTriggerAutoRestore?: boolean;\n ssrObserveBreakpoints?: string[];\n multiplier?: Multiplier;\n defaultUnit?: string;\n detectLayoutDisplay?: boolean;\n}\n\nexport const DEFAULT_CONFIG: Required<LayoutConfigOptions> = {\n addFlexToParent: true,\n addOrientationBps: false,\n disableDefaultBps: false,\n disableVendorPrefixes: false,\n serverLoaded: false,\n useColumnBasisZero: true,\n printWithBreakpoints: [],\n mediaTriggerAutoRestore: true,\n ssrObserveBreakpoints: [],\n // This is disabled by default because otherwise the multiplier would\n // run for all users, regardless of whether they're using this feature.\n // Instead, we disable it by default, which requires this ugly cast.\n multiplier: undefined as unknown as Multiplier,\n defaultUnit: 'px',\n detectLayoutDisplay: false,\n};\n\nexport const LAYOUT_CONFIG = new InjectionToken<LayoutConfigOptions>(\n 'Flex Layout token, config options for the library', {\n providedIn: 'root',\n factory: () => DEFAULT_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 */\nimport {InjectionToken} from '@angular/core';\n\n/**\n * Token that is provided to tell whether the FlexLayoutServerModule\n * has been included in the bundle\n *\n * NOTE: This can be manually provided to disable styles when using SSR\n */\nexport const SERVER_TOKEN = new InjectionToken<boolean>(\n 'FlexLayoutServerLoaded', {\n providedIn: 'root',\n factory: () => false\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 {InjectionToken} from '@angular/core';\nimport {BreakPoint} from '../breakpoints/break-point';\n\nexport const BREAKPOINT = new InjectionToken<BreakPoint|BreakPoint[]|null>(\n 'Flex Layout token, collect all breakpoints into one provider', {\n providedIn: 'root',\n factory: () => null\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 './library-config';\nexport * from './server-token';\nexport * from './breakpoint-token';\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 {MediaChange} from './media-change';\nimport {BreakPoint} from './breakpoints/break-point';\n\n/**\n * For the specified MediaChange, make sure it contains the breakpoint alias\n * and suffix (if available).\n */\nexport function mergeAlias(dest: MediaChange, source: BreakPoint | null): MediaChange {\n dest = dest ? dest.clone() : new MediaChange();\n if (source) {\n dest.mqAlias = source.alias;\n dest.mediaQuery = source.mediaQuery;\n dest.suffix = source.suffix as string;\n dest.priority = source.priority as number;\n }\n return dest;\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 {StyleDefinition} from '../style-utils/style-utils';\n\n/** A class that encapsulates CSS style generation for common directives */\nexport abstract class StyleBuilder {\n\n /** Whether to cache the generated output styles */\n shouldCache = true;\n\n /** Build the styles given an input string and configuration object from a host */\n abstract buildStyles(input: string, parent?: Object): StyleDefinition;\n\n /**\n * Run a side effect computation given the input string and the computed styles\n * from the build task and the host configuration object\n * NOTE: This should be a no-op unless an algorithm is provided in a subclass\n */\n sideEffect(_input: string, _styles: StyleDefinition, _parent?: Object) {\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 */\nimport {Inject, Injectable, PLATFORM_ID} from '@angular/core';\nimport {isPlatformBrowser, isPlatformServer} from '@angular/common';\n\nimport {applyCssPrefixes} from '@angular/flex-layout/_private-utils';\nimport {StylesheetMap} from '../stylesheet-map/stylesheet-map';\nimport {SERVER_TOKEN} from '../tokens/server-token';\nimport {LAYOUT_CONFIG, LayoutConfigOptions} from '../tokens/library-config';\n\n@Injectable({providedIn: 'root'})\nexport class StyleUtils {\n\n constructor(private _serverStylesheet: StylesheetMap,\n @Inject(SERVER_TOKEN) private _serverModuleLoaded: boolean,\n @Inject(PLATFORM_ID) private _platformId: Object,\n @Inject(LAYOUT_CONFIG) private layoutConfig: LayoutConfigOptions) {}\n\n /**\n * Applies styles given via string pair or object map to the directive element\n */\n applyStyleToElement(element: HTMLElement,\n style: StyleDefinition | string,\n value: string | number | null = null) {\n let styles: StyleDefinition = {};\n if (typeof style === 'string') {\n styles[style] = value;\n style = styles;\n }\n styles = this.layoutConfig.disableVendorPrefixes ? style : applyCssPrefixes(style);\n this._applyMultiValueStyleToElement(styles, element);\n }\n\n /**\n * Applies styles given via string pair or object map to the directive's element\n */\n applyStyleToElements(style: StyleDefinition, elements: HTMLElement[] = []) {\n const styles = this.layoutConfig.disableVendorPrefixes ? style : applyCssPrefixes(style);\n elements.forEach(el => {\n this._applyMultiValueStyleToElement(styles, el);\n });\n }\n\n /**\n * Determine the DOM element's Flexbox flow (flex-direction)\n *\n * Check inline style first then check computed (stylesheet) style\n */\n getFlowDirection(target: HTMLElement): [string, string] {\n const query = 'flex-direction';\n let value = this.lookupStyle(target, query);\n const hasInlineValue = this.lookupInlineStyle(target, query) ||\n (isPlatformServer(this._platformId) && this._serverModuleLoaded) ? value : '';\n\n return [value || 'row', hasInlineValue];\n }\n\n hasWrap(target: HTMLElement): boolean {\n const query = 'flex-wrap';\n return this.lookupStyle(target, query) === 'wrap';\n }\n\n /**\n * Find the DOM element's raw attribute value (if any)\n */\n lookupAttributeValue(element: HTMLElement, attribute: string): string {\n return element.getAttribute(attribute) ?? '';\n }\n\n /**\n * Find the DOM element's inline style value (if any)\n */\n lookupInlineStyle(element: HTMLElement, styleName: string): string {\n return isPlatformBrowser(this._platformId) ?\n element.style.getPropertyValue(styleName) : getServerStyle(element, styleName);\n }\n\n /**\n * Determine the inline or inherited CSS style\n * NOTE: platform-server has no implementation for getComputedStyle\n */\n lookupStyle(element: HTMLElement, styleName: string, inlineOnly = false): string {\n let value = '';\n if (element) {\n let immediateValue = value = this.lookupInlineStyle(element, styleName);\n if (!immediateValue) {\n if (isPlatformBrowser(this._platformId)) {\n if (!inlineOnly) {\n value = getComputedStyle(element).getPropertyValue(styleName);\n }\n } else {\n if (this._serverModuleLoaded) {\n value = this._serverStylesheet.getStyleForElement(element, styleName);\n }\n }\n }\n }\n\n // Note: 'inline' is the default of all elements, unless UA stylesheet overrides;\n // in which case getComputedStyle() should determine a valid value.\n return value ? value.trim() : '';\n }\n\n /**\n * Applies the styles to the element. The styles object map may contain an array of values\n * Each value will be added as element style\n * Keys are sorted to add prefixed styles (like -webkit-x) first, before the standard ones\n */\n private _applyMultiValueStyleToElement(styles: StyleDefinition,\n element: HTMLElement) {\n Object.keys(styles).sort().forEach(key => {\n const el = styles[key];\n const values: (string | number | null)[] = Array.isArray(el) ? el : [el];\n values.sort();\n for (let value of values) {\n value = value ? value + '' : '';\n if (isPlatformBrowser(this._platformId) || !this._serverModuleLoaded) {\n isPlatformBrowser(this._platformId) ?\n element.style.setProperty(key, value) : setServerStyle(element, key, value);\n } else {\n this._serverStylesheet.addStyleToElement(element, key, value);\n }\n }\n });\n }\n}\n\nfunction getServerStyle(element: any, styleName: string): string {\n const styleMap = readStyleAttribute(element);\n return styleMap[styleName] ?? '';\n}\n\nfunction setServerStyle(element: any, styleName: string, styleValue?: string|null) {\n styleName = styleName.replace(/([a-z])([A-Z])/g, '$1-$2').toLowerCase();\n const styleMap = readStyleAttribute(element);\n styleMap[styleName] = styleValue ?? '';\n writeStyleAttribute(element, styleMap);\n}\n\nfunction writeStyleAttribute(element: any, styleMap: {[name: string]: string}) {\n let styleAttrValue = '';\n for (const key in styleMap) {\n const newValue = styleMap[key];\n if (newValue) {\n styleAttrValue += `${key}:${styleMap[key]};`;\n }\n }\n element.setAttribute('style', styleAttrValue);\n}\n\nfunction readStyleAttribute(element: any): {[name: string]: string} {\n const styleMap: {[name: string]: string} = {};\n const styleAttribute = element.getAttribute('style');\n if (styleAttribute) {\n const styleList = styleAttribute.split(/;+/g);\n for (let i = 0; i < styleList.length; i++) {\n const style = styleList[i].trim();\n if (style.length > 0) {\n const colonIndex = style.indexOf(':');\n if (colonIndex === -1) {\n throw new Error(`Invalid CSS style: ${style}`);\n }\n const name = style.substr(0, colonIndex).trim();\n styleMap[name] = style.substr(colonIndex + 1).trim();\n }\n }\n }\n return styleMap;\n}\n\n/**\n * Definition of a css style. Either a property name (e.g. \"flex-basis\") or an object\n * map of property name and value (e.g. {display: 'none', flex-order: 5})\n */\nexport type StyleDefinition = { [property: string]: string | number | null };\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\ninterface WithPriority {\n priority?: number;\n}\n\n/** HOF to sort the breakpoints by descending priority */\nexport function sortDescendingPriority<T extends WithPriority>(a: T | null, b: T | null): number {\n const priorityA = a ? a.priority || 0 : 0;\n const priorityB = b ? b.priority || 0 : 0;\n return priorityB - priorityA;\n}\n\n/** HOF to sort the breakpoints by ascending priority */\nexport function sortAscendingPriority<T extends WithPriority>(a: T, b: T): number {\n const pA = a.priority || 0;\n const pB = b.priority || 0;\n return pA - pB;\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 {Inject, Injectable, NgZone, OnDestroy, PLATFORM_ID} from '@angular/core';\nimport {DOCUMENT, isPlatformBrowser} from '@angular/common';\nimport {BehaviorSubject, Observable, merge, Observer} from 'rxjs';\nimport {filter} from 'rxjs/operators';\n\nimport {MediaChange} from '../media-change';\n\n/**\n * MediaMonitor configures listeners to mediaQuery changes and publishes an Observable facade to\n * convert mediaQuery change callbacks to subscriber notifications. These notifications will be\n * performed within the ng Zone to trigger change detections and component updates.\n *\n * NOTE: both mediaQuery activations and de-activations are announced in notifications\n */\n@Injectable({providedIn: 'root'})\nexport class MatchMedia implements OnDestroy {\n /** Initialize source with 'all' so all non-responsive APIs trigger style updates */\n readonly source = new BehaviorSubject<MediaChange>(new MediaChange(true));\n registry = new Map<string, MediaQueryList>();\n private readonly pendingRemoveListenerFns: Array<() => void> = [];\n\n constructor(protected _zone: NgZone,\n @Inject(PLATFORM_ID) protected _platformId: Object,\n @Inject(DOCUMENT) protected _document: any) {\n }\n\n /**\n * Publish list of all current activations\n */\n get activations(): string[] {\n const results: string[] = [];\n this.registry.forEach((mql: MediaQueryList, key: string) => {\n if (mql.matches) {\n results.push(key);\n }\n });\n return results;\n }\n\n /**\n * For the specified mediaQuery?\n */\n isActive(mediaQuery: string): boolean {\n const mql = this.registry.get(mediaQuery);\n return mql?.matches ?? this.registerQuery(mediaQuery).some(m => m.matches);\n }\n\n /**\n * External observers can watch for all (or a specific) mql changes.\n *\n * If a mediaQuery is not specified, then ALL mediaQuery activations will\n * be announced.\n */\n observe(): Observable<MediaChange>;\n observe(mediaQueries: string[]): Observable<MediaChange>;\n observe(mediaQueries: string[], filterOthers: boolean): Observable<MediaChange>;\n\n /**\n * External observers can watch for all (or a specific) mql changes.\n * Typically used by the MediaQueryAdaptor; optionally available to components\n * who wish to use the MediaMonitor as mediaMonitor$ observable service.\n *\n * Use deferred registration process to register breakpoints only on subscription\n * This logic also enforces logic to register all mediaQueries BEFORE notify\n * subscribers of notifications.\n */\n observe(mqList?: string[], filterOthers = false): Observable<MediaChange> {\n if (mqList && mqList.length) {\n const matchMedia$: Observable<MediaChange> = this._observable$.pipe(\n filter((change: MediaChange) =>\n !filterOthers ? true : (mqList.indexOf(change.mediaQuery) > -1))\n );\n const registration$: Observable<MediaChange> = new Observable((observer: Observer<MediaChange>) => { // tslint:disable-line:max-line-length\n const matches: Array<MediaChange> = this.registerQuery(mqList);\n if (matches.length) {\n const lastChange = matches.pop()!;\n matches.forEach((e: MediaChange) => {\n observer.next(e);\n });\n this.source.next(lastChange); // last match is cached\n }\n observer.complete();\n });\n return merge(registration$, matchMedia$);\n }\n\n return this._observable$;\n }\n\n /**\n * Based on the BreakPointRegistry provider, register internal listeners for each unique\n * mediaQuery. Each listener emits specific MediaChange data to observers\n */\n registerQuery(mediaQuery: string | string[]) {\n const list = Array.isArray(mediaQuery) ? mediaQuery : [mediaQuery];\n const matches: MediaChange[] = [];\n\n buildQueryCss(list, this._document);\n\n list.forEach((query: string) => {\n const onMQLEvent = (e: MediaQueryListEvent) => {\n this._zone.run(() => this.source.next(new MediaChange(e.matches, query)));\n };\n\n let mql = this.registry.get(query);\n if (!mql) {\n mql = this.buildMQL(query);\n mql.addListener(onMQLEvent);\n this.pendingRemoveListenerFns.push(() => mql!.removeListener(onMQLEvent));\n this.registry.set(query, mql);\n }\n\n if (mql.matches) {\n matches.push(new MediaChange(true, query));\n }\n });\n\n return matches;\n }\n\n ngOnDestroy(): void {\n let fn;\n while (fn = this.pendingRemoveListenerFns.pop()) {\n fn();\n }\n }\n\n /**\n * Call window.matchMedia() to build a MediaQueryList; which\n * supports 0..n listeners for activation/deactivation\n */\n protected buildMQL(query: string): MediaQueryList {\n return constructMql(query, isPlatformBrowser(this._platformId));\n }\n\n protected _observable$ = this.source.asObservable();\n}\n\n/**\n * Private global registry for all dynamically-created, injected style tags\n * @see prepare(query)\n */\nconst ALL_STYLES: { [key: string]: any } = {};\n\n/**\n * For Webkit engines that only trigger the MediaQueryList Listener\n * when there is at least one CSS selector for the respective media query.\n *\n * @param mediaQueries\n * @param _document\n */\nfunction buildQueryCss(mediaQueries: string[], _document: Document) {\n const list = mediaQueries.filter(it => !ALL_STYLES[it]);\n if (list.length > 0) {\n const query = list.join(', ');\n\n try {\n const styleEl = _document.createElement('style');\n\n styleEl.setAttribute('type', 'text/css');\n if (!(styleEl as any).styleSheet) {\n const cssText = `\n/*\n @angular/flex-layout - workaround for possible browser quirk with mediaQuery listeners\n see http://bit.ly/2sd4HMP\n*/\n@media ${query} {.fx-query-test{ }}\n`;\n styleEl.appendChild(_document.createTextNode(cssText));\n }\n\n _document.head!.appendChild(styleEl);\n\n // Store in private global registry\n list.forEach(mq => ALL_STYLES[mq] = styleEl);\n\n } catch (e) {\n console.error(e);\n }\n }\n}\n\nfunction constructMql(query: string, isBrowser: boolean): MediaQueryList {\n const canListen = isBrowser && !!(<Window>window).matchMedia('all').addListener;\n\n return canListen ? (<Window>window).matchMedia(query) : {\n matches: query === 'all' || query === '',\n media: query,\n addListener: () => {\n },\n removeListener: () => {\n },\n onchange: null,\n addEventListener() {\n },\n removeEventListener() {\n },\n dispatchEvent() {\n return false;\n }\n } as MediaQueryList;\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 {BreakPoint} from '../break-point';\n\n/**\n * NOTE: Smaller ranges have HIGHER priority since the match is more specific\n */\nexport const DEFAULT_BREAKPOINTS: BreakPoint[] = [\n {\n alias: 'xs',\n mediaQuery: 'screen and (min-width: 0px) and (max-width: 599.98px)',\n priority: 1000,\n },\n {\n alias: 'sm',\n mediaQuery: 'screen and (min-width: 600px) and (max-width: 959.98px)',\n priority: 900,\n },\n {\n alias: 'md',\n mediaQuery: 'screen and (min-width: 960px) and (max-width: 1279.98px)',\n priority: 800,\n },\n {\n alias: 'lg',\n mediaQuery: 'screen and (min-width: 1280px) and (max-width: 1919.98px)',\n priority: 700,\n },\n {\n alias: 'xl',\n mediaQuery: 'screen and (min-width: 1920px) and (max-width: 4999.98px)',\n priority: 600,\n },\n {\n alias: 'lt-sm',\n overlapping: true,\n mediaQuery: 'screen and (max-width: 599.98px)',\n priority: 950,\n },\n {\n alias: 'lt-md',\n overlapping: true,\n mediaQuery: 'screen and (max-width: 959.98px)',\n priority: 850,\n },\n {\n alias: 'lt-lg',\n overlapping: true,\n mediaQuery: 'screen and (max-width: 1279.98px)',\n priority: 750,\n },\n {\n alias: 'lt-xl',\n overlapping: true,\n priority: 650,\n mediaQuery: 'screen and (max-width: 1919.98px)',\n },\n {\n alias: 'gt-xs',\n overlapping: true,\n mediaQuery: 'screen and (min-width: 600px)',\n priority: -950,\n },\n {\n alias: 'gt-sm',\n overlapping: true,\n mediaQuery: 'screen and (min-width: 960px)',\n priority: -850,\n }, {\n alias: 'gt-md',\n overlapping: true,\n mediaQuery: 'screen and (min-width: 1280px)',\n priority: -750,\n },\n {\n alias: 'gt-lg',\n overlapping: true,\n mediaQuery: 'screen and (min-width: 1920px)',\n priority: -650,\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 {BreakPoint} from '../break-point';\n\n/* tslint:disable */\nconst HANDSET_PORTRAIT = '(orientation: portrait) and (max-width: 599.98px)';\nconst HANDSET_LANDSCAPE = '(orientation: landscape) and (max-width: 959.98px)';\n\nconst TABLET_PORTRAIT = '(orientation: portrait) and (min-width: 600px) and (max-width: 839.98px)';\nconst TABLET_LANDSCAPE = '(orientation: landscape) and (min-width: 960px) and (max-width: 1279.98px)';\n\nconst WEB_PORTRAIT = '(orientation: portrait) and (min-width: 840px)';\nconst WEB_LANDSCAPE = '(orientation: landscape) and (min-width: 1280px)';\n\nexport const ScreenTypes = {\n 'HANDSET' : `${HANDSET_PORTRAIT}, ${HANDSET_LANDSCAPE}`,\n 'TABLET' : `${TABLET_PORTRAIT} , ${TABLET_LANDSCAPE}`,\n 'WEB' : `${WEB_PORTRAIT}, ${WEB_LANDSCAPE} `,\n\n 'HANDSET_PORTRAIT' : `${HANDSET_PORTRAIT}`,\n 'TABLET_PORTRAIT' : `${TABLET_PORTRAIT} `,\n 'WEB_PORTRAIT' : `${WEB_PORTRAIT}`,\n\n 'HANDSET_LANDSCAPE' : `${HANDSET_LANDSCAPE}`,\n 'TABLET_LANDSCAPE' : `${TABLET_LANDSCAPE}`,\n 'WEB_LANDSCAPE' : `${WEB_LANDSCAPE}`\n};\n\n/**\n * Extended Breakpoints for handset/tablets with landscape or portrait orientations\n */\nexport const ORIENTATION_BREAKPOINTS : BreakPoint[] = [\n {'alias': 'handset', priority: 2000, 'mediaQuery': ScreenTypes.HANDSET},\n {'alias': 'handset.landscape', priority: 2000, 'mediaQuery': ScreenTypes.HANDSET_LANDSCAPE},\n {'alias': 'handset.portrait', priority: 2000, 'mediaQuery': ScreenTypes.HANDSET_PORTRAIT},\n\n {'alias': 'tablet', priority: 2100, 'mediaQuery': ScreenTypes.TABLET},\n {'alias': 'tablet.landscape', priority: 2100, 'mediaQuery': ScreenTypes.TABLET_LANDSCAPE},\n {'alias': 'tablet.portrait', priority: 2100, 'mediaQuery': ScreenTypes.TABLET_PORTRAIT},\n\n {'alias': 'web', priority: 2200, 'mediaQuery': ScreenTypes.WEB, overlapping : true },\n {'alias': 'web.landscape', priority: 2200, 'mediaQuery': ScreenTypes.WEB_LANDSCAPE, overlapping : true },\n {'alias': 'web.portrait', priority: 2200, 'mediaQuery': ScreenTypes.WEB_PORTRAIT, overlapping : true }\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 {BreakPoint} from './break-point';\nimport {extendObject} from '@angular/flex-layout/_private-utils';\n\nconst ALIAS_DELIMITERS = /(\\.|-|_)/g;\nfunction firstUpperCase(part: string) {\n let first = part.length > 0 ? part.charAt(0) : '';\n let remainder = (part.length > 1) ? part.slice(1) : '';\n return first.toUpperCase() + remainder;\n}\n\n/**\n * Converts snake-case to SnakeCase.\n * @param name Text to UpperCamelCase\n */\nfunction camelCase(name: string): string {\n return name\n .replace(ALIAS_DELIMITERS, '|')\n .split('|')\n .map(firstUpperCase)\n .join('');\n}\n\n/**\n * For each breakpoint, ensure that a Suffix is defined;\n * fallback to UpperCamelCase the unique Alias value\n */\nexport function validateSuffixes(list: BreakPoint[]): BreakPoint[] {\n list.forEach((bp: BreakPoint) => {\n if (!bp.suffix) {\n bp.suffix = camelCase(bp.alias); // create Suffix value based on alias\n bp.overlapping = !!bp.overlapping; // ensure default value\n }\n });\n return list;\n}\n\n/**\n * Merge a custom breakpoint list with the default list based on unique alias values\n * - Items are added if the alias is not in the default list\n * - Items are merged with the custom override if the alias exists in the default list\n */\nexport function mergeByAlias(defaults: BreakPoint[], custom: BreakPoint[] = []): BreakPoint[] {\n const dict: {[key: string]: BreakPoint} = {};\n defaults.forEach(bp => {\n dict[bp.alias] = bp;\n });\n // Merge custom breakpoints\n custom.forEach((bp: BreakPoint) => {\n if (dict[bp.alias]) {\n extendObject(dict[bp.alias], bp);\n } else {\n dict[bp.alias] = bp;\n }\n });\n\n return validateSuffixes(Object.keys(dict).map(k => dict[k]));\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 {inject, InjectionToken} from '@angular/core';\nimport {BreakPoint} from './break-point';\nimport {BREAKPOINT} from '../tokens/breakpoint-token';\nimport {DEFAULT_BREAKPOINTS} from '../breakpoints/data/break-points';\nimport {ORIENTATION_BREAKPOINTS} from '../breakpoints/data/orientation-break-points';\nimport {mergeByAlias} from '../breakpoints/breakpoint-tools';\nimport {LAYOUT_CONFIG} from '../tokens/library-config';\n\n/**\n * Injection token unique to the flex-layout library.\n * Use this token when build a custom provider (see below).\n */\nexport const BREAKPOINTS =\n new InjectionToken<BreakPoint[]>('Token (@angular/flex-layout) Breakpoints', {\n providedIn: 'root',\n factory: () => {\n const breakpoints: any = inject(BREAKPOINT);\n const layoutConfig = inject(LAYOUT_CONFIG);\n const bpFlattenArray: BreakPoint[] = [].concat.apply([], (breakpoints || [])\n .map((v: BreakPoint | BreakPoint[]) => Array.isArray(v) ? v : [v]));\n const builtIns = (layoutConfig.disableDefaultBps ? [] : DEFAULT_BREAKPOINTS)\n .concat(layoutConfig.addOrientationBps ? ORIENTATION_BREAKPOINTS : []);\n\n return mergeByAlias(builtIns, bpFlattenArray);\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 */\nimport {Injectable, Inject} from '@angular/core';\n\nimport {BreakPoint} from './break-point';\nimport {BREAKPOINTS} from './break-points-token';\nimport {sortAscendingPriority} from '../utils/sort';\n\nexport type OptionalBreakPoint = BreakPoint | null;\n\n/**\n * Registry of 1..n MediaQuery breakpoint ranges\n * This is published as a provider and may be overridden from custom, application-specific ranges\n *\n */\n@Injectable({providedIn: 'root'})\nexport class BreakPointRegistry {\n readonly items: BreakPoint[];\n\n constructor(@Inject(BREAKPOINTS) list: BreakPoint[]) {\n this.items = [...list].sort(sortAscendingPriority);\n }\n\n /**\n * Search breakpoints by alias (e.g. gt-xs)\n */\n findByAlias(alias: string): OptionalBreakPoint {\n return !alias ? null : this.findWithPredicate(alias, (bp) => bp.alias === alias);\n }\n\n findByQuery(query: string): OptionalBreakPoint {\n return this.findWithPredicate(query, (bp) => bp.mediaQuery === query);\n }\n\n /**\n * Get all the breakpoints whose ranges could overlapping `normal` ranges;\n * e.g. gt-sm overlaps md, lg, and xl\n */\n get overlappings(): BreakPoint[] {\n return this.items.filter(it => it.overlapping);\n }\n\n /**\n * Get list of all registered (non-empty) breakpoint aliases\n */\n get aliases(): string[] {\n return this.items.map(it => it.alias);\n }\n\n /**\n * Aliases are mapped to properties using suffixes\n * e.g. 'gt-sm' for property 'layout' uses suffix 'GtSm'\n * for property layoutGtSM.\n */\n get suffixes(): string[] {\n return this.items.map(it => it?.suffix ?? '');\n }\n\n /**\n * Memoized lookup using custom predicate function\n */\n private findWithPredicate(key: string,\n searchFn: (bp: BreakPoint) => boolean): OptionalBreakPoint {\n let response = this.findByMap.get(key);\n if (!response) {\n response = this.items.find(searchFn) ?? null;\n this.findByMap.set(key, response);\n }\n return response ?? null;\n\n }\n\n /**\n * Memoized BreakPoint Lookups\n */\n private readonly findByMap = new Map<String, OptionalBreakPoint>();\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 */\nimport {Inject, Injectable, OnDestroy} from '@angular/core';\n\nimport {mergeAlias} from '../add-alias';\nimport {MediaChange} from '../media-change';\nimport {BreakPoint} from '../breakpoints/break-point';\nimport {LAYOUT_CONFIG, LayoutConfigOptions} from '../tokens/library-config';\nimport {BreakPointRegistry, OptionalBreakPoint} from '../breakpoints/break-point-registry';\nimport {sortDescendingPriority} from '../utils/sort';\nimport {DOCUMENT} from '@angular/common';\n\n/**\n * Interface to apply PrintHook to call anonymous `target.updateStyles()`\n */\nexport interface HookTarget {\n activatedBreakpoints: BreakPoint[];\n updateStyles(): void;\n}\n\nconst PRINT = 'print';\nexport const BREAKPOINT_PRINT = {\n alias: PRINT,\n mediaQuery: PRINT,\n priority: 1000\n};\n\n/**\n * PrintHook - Use to intercept print MediaQuery activations and force\n * layouts to render with the specified print alias/breakpoint\n *\n * Used in MediaMarshaller and MediaObserver\n */\n@Injectable({providedIn: 'root'})\nexport class PrintHook implements OnDestroy {\n constructor(\n protected breakpoints: BreakPointRegistry,\n @Inject(LAYOUT_CONFIG) protected layoutConfig: LayoutConfigOptions,\n @Inject(DOCUMENT) protected _document: any) {\n }\n\n /** Add 'print' mediaQuery: to listen for matchMedia activations */\n withPrintQuery(queries: string[]): string[] {\n return [...queries, PRINT];\n }\n\n /** Is the MediaChange event for any 'print' @media */\n isPrintEvent(e: MediaChange): boolean {\n return e.mediaQuery.startsWith(PRINT);\n }\n\n /** What is the desired mqAlias to use while printing? */\n get printAlias(): string[] {\n return [...(this.layoutConfig.printWithBreakpoints ?? [])];\n }\n\n /** Lookup breakpoints associated with print aliases. */\n get printBreakPoints(): BreakPoint[] {\n return this.printAlias\n .map(alias => this.breakpoints.findByAlias(alias))\n .filter(bp => bp !== null) as BreakPoint[];\n }\n\n /** Lookup breakpoint associated with mediaQuery */\n getEventBreakpoints({mediaQuery}: MediaChange): BreakPoint[] {\n const bp = this.breakpoints.findByQuery(mediaQuery);\n const list = bp ? [...this.printBreakPoints, bp] : this.printBreakPoints;\n\n return list.sort(sortDescendingPriority);\n }\n\n /** Update event with printAlias mediaQuery information */\n updateEvent(event: MediaChange): MediaChange {\n let bp: OptionalBreakPoint = this.breakpoints.findByQuery(event.mediaQuery);\n\n if (this.isPrintEvent(event)) {\n // Reset from 'print' to first (highest priority) print breakpoint\n bp = this.getEventBreakpoints(event)[0];\n event.mediaQuery = bp?.mediaQuery ?? '';\n }\n\n return mergeAlias(event, bp);\n }\n\n\n // registeredBeforeAfterPrintHooks tracks if we registered the `beforeprint`\n // and `afterprint` event listeners.\n private registeredBeforeAfterPrintHooks = false;\n\n // isPrintingBeforeAfterEvent is used to track if we are printing from within\n // a `beforeprint` event handler. This prevents the typical `stopPrinting`\n // form `interceptEvents` so that printing is not stopped while the dialog\n // is still open. This is an extension of the `isPrinting` property on\n // browsers which support `beforeprint` and `afterprint` events.\n private isPrintingBeforeAfterEvent = false;\n\n private beforePrintEventListeners: Function[] = [];\n private afterPrintEventListeners: Function[] = [];\n\n private formerActivations: Array<BreakPoint> | null = null;\n\n // registerBeforeAfterPrintHooks registers a `beforeprint` event hook so we can\n // trigger print styles synchronously and apply proper layout styles.\n // It is a noop if the hooks have already been registered or if the document's\n // `defaultView` is not available.\n registerBeforeAfterPrintHooks(target: HookTarget) {\n // `defaultView` may be null when rendering on the server or in other contexts.\n if (!this._document.defaultView || this.registeredBeforeAfterPrintHooks) {\n return;\n }\n\n this.registeredBeforeAfterPrintHooks = true;\n\n const beforePrintListener = () => {\n // If we aren't already printing, start printing and update the styles as\n // if there was a regular print `MediaChange`(from matchMedia).\n if (!this.isPrinting) {\n this.isPrintingBeforeAfterEvent = true;\n this.startPrinting(target, this.getEventBreakpoints(new MediaChange(true, PRINT)));\n target.updateStyles();\n }\n };\n\n const afterPrintListener = () => {\n // If we aren't already printing, start printing and update the styles as\n // if there was a regular print `MediaChange`(from matchMedia).\n this.isPrintingBeforeAfterEvent = false;\n if (this.isPrinting) {\n this.stopPrinting(target);\n target.updateStyles();\n }\n };\n\n // Could we have teardown logic to remove if there are no print listeners being used?\n this._document.defaultView.addEventListener('beforeprint', beforePrintListener);\n this._document.defaultView.addEventListener('afterprint', afterPrintListener);\n\n this.beforePrintEventListeners.push(beforePrintListener);\n this.afterPrintEventListeners.push(afterPrintListener);\n }\n\n /**\n * Prepare RxJS tap operator with partial application\n * @return pipeable tap predicate\n */\n interceptEvents(target: HookTarget) {\n return (event: MediaChange) => {\n if (this.isPrintEvent(event)) {\n if (event.matches && !this.isPrinting) {\n this.startPrinting(target, this.getEventBreakpoints(event));\n target.updateStyles();\n } else if (!event.matches && this.isPrinting && !this.isPrintingBeforeAfterEvent) {\n this.stopPrinting(target);\n target.updateStyles();\n }\n\n return;\n }\n\n this.collectActivations(target, event);\n };\n }\n\n /** Stop mediaChange event propagation in event streams */\n blockPropagation() {\n return (event: MediaChange): boolean => {\n return !(this.isPrinting || this.isPrintEvent(event));\n };\n }\n\n /**\n * Save current activateBreakpoints (for later restore)\n * and substitute only the printAlias breakpoint\n */\n protected startPrinting(target: HookTarget, bpList: OptionalBreakPoint[]) {\n this.isPrinting = true;\n this.formerActivations = target.activatedBreakpoints;\n target.activatedBreakpoints = this.queue.addPrintBreakpoints(bpList);\n }\n\n /** For any print de-activations, reset the entire print queue */\n protected stopPrinting(target: HookTarget) {\n target.activatedBreakpoints = this.deactivations;\n this.deactivations = [];\n this.formerActivations = null;\n this.queue.clear();\n this.isPrinting = false;\n }\n\n /**\n * To restore pre-Print Activations, we must capture the proper\n * list of breakpoint activations BEFORE print starts. OnBeforePrint()\n * is supported; so 'print' mediaQuery activations are used as a fallback\n * in browsers without `beforeprint` support.\n *\n * > But activated breakpoints are deactivated BEFORE 'print' activation.\n *\n * Let's capture all de-activations using the following logic:\n *\n * When not printing:\n * - clear cache when activating non-print breakpoint\n * - update cache (and sort) when deactivating\n *\n * When printing:\n * - sort and save when starting print\n * - restore as activatedTargets and clear when stop printing\n */\n collectActivations(target: HookTarget, event: MediaChange) {\n if (!this.isPrinting || this.isPrintingBeforeAfterEvent) {\n if (!this.isPrintingBeforeAfterEvent) {\n // Only clear deactivations if we aren't printing from a `beforeprint` event.\n // Otherwise, this will clear before `stopPrinting()` is called to restore\n // the pre-Print Activations.\n this.deactivations = [];\n\n return;\n }\n\n if (!event.matches) {\n const bp = this.breakpoints.findByQuery(event.mediaQuery);\n // Deactivating a breakpoint\n if (bp) {\n const hasFormerBp = this.formerActivations && this.formerActivations.includes(bp);\n const wasActivated = !this.formerActivations && target.activatedBreakpoints.includes(bp);\n const shouldDeactivate = hasFormerBp || wasActivated;\n if (shouldDeactivate) {\n this.deactivations.push(bp);\n this.deactivations.sort(sortDescendingPriority);\n }\n }\n }\n }\n }\n\n /** Teardown logic for the service. */\n ngOnDestroy() {\n if (this._document.defaultView) {\n this.beforePrintEventListeners.forEach(l => this._document.defaultView.removeEventListener('beforeprint', l));\n this.afterPrintEventListeners.forEach(l => this._document.defaultView.removeEventListener('afterprint', l));\n }\n }\n\n // Is this service currently in print mode\n private isPrinting = false;\n private queue = new PrintQueue();\n private deactivations: BreakPoint[] = [];\n}\n\n// ************************************************************************\n// Internal Utility class 'PrintQueue'\n// ************************************************************************\n\n/**\n * Utility class to manage print breakpoints + activatedBreakpoints\n * with correct sorting WHILE printing\n */\nclass PrintQueue {\n /** Sorted queue with prioritized print breakpoints */\n printBreakpoints: BreakPoint[] = [];\n\n addPrintBreakpoints(bpList: OptionalBreakPoint[]): BreakPoint[] {\n bpList.push(BREAKPOINT_PRINT);\n bpList.sort(sortDescendingPriority);\n bpList.forEach(bp => this.addBreakpoint(bp));\n\n return this.printBreakpoints;\n }\n\n /** Add Print breakpoint to queue */\n addBreakpoint(bp: OptionalBreakPoint) {\n if (!!bp) {\n const bpInList = this.printBreakpoints.find(it => it.mediaQuery === bp.mediaQuery);\n\n if (bpInList === undefined) {\n // If this is a `printAlias` breakpoint, then append. If a true 'print' breakpoint,\n // register as highest priority in the queue\n this.printBreakpoints = isPrintBreakPoint(bp) ? [bp, ...this.printBreakpoints]\n : [...this.printBreakpoints, bp];\n }\n }\n }\n\n /** Restore original activated breakpoints and clear internal caches */\n clear() {\n this.printBreakpoints = [];\n }\n}\n\n// ************************************************************************\n// Internal Utility methods\n// ************************************************************************\n\n/** Only support intercept queueing if the Breakpoint is a print @media query */\nfunction isPrintBreakPoint(bp: OptionalBreakPoint): boolean {\n return bp?.mediaQuery.startsWith(PRINT) ?? false;\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 {Injectable} from '@angular/core';\n\nimport {merge, Observable, Subject, Subscription} from 'rxjs';\nimport {filter, tap} from 'rxjs/operators';\n\nimport {BreakPoint} from '../breakpoints/break-point';\nimport {sortDescendingPriority} from '../utils/sort';\nimport {BreakPointRegistry} from '../breakpoints/break-point-registry';\nimport {MatchMedia} from '../match-media/match-media';\nimport {MediaChange} from '../media-change';\n\nimport {PrintHook, HookTarget} from './print-hook';\nimport {mergeAlias} from '../add-alias';\n\ntype ClearCallback = () => void;\ntype UpdateCallback = (val: any) => void;\ntype Builder = UpdateCallback | ClearCallback;\n\ntype ValueMap = Map<string, string>;\ntype BreakpointMap = Map<string, ValueMap>;\ntype ElementMap = Map<HTMLElement, BreakpointMap>;\ntype ElementKeyMap = WeakMap<HTMLElement, Set<string>>;\ntype SubscriptionMap = Map<string, Subscription>;\ntype WatcherMap = WeakMap<HTMLElement, SubscriptionMap>;\ntype BuilderMap = WeakMap<HTMLElement, Map<string, Builder>>;\n\nexport interface ElementMatcher {\n element: HTMLElement;\n key: string;\n value: any;\n}\n\n/**\n * MediaMarshaller - register responsive values from directives and\n * trigger them based on media query events\n */\n@Injectable({providedIn: 'root'})\nexport class MediaMarshaller {\n private _useFallbacks = true;\n private _activatedBreakpoints: BreakPoint[] = [];\n private elementMap: ElementMap = new Map();\n private elementKeyMap: ElementKeyMap = new WeakMap();\n private watcherMap: WatcherMap = new WeakMap(); // special triggers to update elements\n private updateMap: BuilderMap = new WeakMap(); // callback functions to update styles\n private clearMap: BuilderMap = new WeakMap(); // callback functions to clear styles\n\n private subject: Subject<ElementMatcher> = new Subject();\n\n get activatedAlias(): string {\n return this.activatedBreakpoints[0]?.alias ?? '';\n }\n\n set activatedBreakpoints(bps: BreakPoint[]) {\n this._activatedBreakpoints = [...bps];\n }\n\n get activatedBreakpoints(): BreakPoint[] {\n return [...this._activatedBreakpoints];\n }\n\n set useFallbacks(value: boolean) {\n this._useFallbacks = value;\n }\n\n constructor(protected matchMedia: MatchMedia,\n protected breakpoints: BreakPointRegistry,\n protected hook: PrintHook) {\n this.observeActivations();\n }\n\n /**\n * Update styles on breakpoint activates or deactivates\n * @param mc\n */\n onMediaChange(mc: MediaChange) {\n const bp: BreakPoint | null = this.findByQuery(mc.mediaQuery);\n\n if (bp) {\n mc = mergeAlias(mc, bp);\n\n const bpIndex = this.activatedBreakpoints.indexOf(bp);\n\n if (mc.matches && bpIndex === -1) {\n this._activatedBreakpoints.push(bp);\n this._activatedBreakpoints.sort(sortDescendingPriority);\n\n this.updateStyles();\n } else if (!mc.matches && bpIndex !== -1) {\n // Remove the breakpoint when it's deactivated\n this._activatedBreakpoints.splice(bpIndex, 1);\n this._activatedBreakpoints.sort(sortDescendingPriority);\n\n this.updateStyles();\n }\n }\n }\n\n /**\n * initialize the marshaller with necessary elements for delegation on an element\n * @param element\n * @param key\n * @param updateFn optional callback so that custom bp directives don't have to re-provide this\n * @param clearFn optional callback so that custom bp directives don't have to re-provide this\n * @param extraTriggers other triggers to force style updates (e.g. layout, directionality, etc)\n */\n init(element: HTMLElement,\n key: string,\n updateFn?: UpdateCallback,\n clearFn?: ClearCallback,\n extraTriggers: Observable<any>[] = []): void {\n\n initBuilderMap(this.updateMap, element, key, updateFn);\n initBuilderMap(this.clearMap, element, key, clearFn);\n\n this.buildElementKeyMap(element, key);\n this.watchExtraTriggers(element, key, extraTriggers);\n }\n\n /**\n * get the value for an element and key and optionally a given breakpoint\n * @param element\n * @param key\n * @param bp\n */\n getValue(element: HTMLElement, key: string, bp?: string): any {\n const bpMap = this.elementMap.get(element);\n if (bpMap) {\n const values = bp !== undefined ? bpMap.get(bp) : this.getActivatedValues(bpMap, key);\n if (values) {\n return values.get(key);\n }\n }\n return undefined;\n }\n\n /**\n * whether the element has values for a given key\n * @param element\n * @param key\n */\n hasValue(element: HTMLElement, key: string): boolean {\n const bpMap = this.elementMap.get(element);\n if (bpMap) {\n const values = this.getActivatedValues(bpMap, key);\n if (values) {\n return values.get(key) !== undefined || false;\n }\n }\n return false;\n }\n\n /**\n * Set the value for an input on a directive\n * @param element the element in question\n * @param key the type of the directive (e.g. flex, layout-gap, etc)\n * @param bp the breakpoint suffix (empty string = default)\n * @param val the value for the breakpoint\n */\n setValue(element: HTMLElement, key: string, val: any, bp: string): void {\n let bpMap: BreakpointMap | undefined = this.elementMap.get(element);\n if (!bpMap) {\n bpMap = new Map().set(bp, new Map().set(key, val));\n this.elementMap.set(element, bpMap);\n } else {\n const values = (bpMap.get(bp) ?? new Map()).set(key, val);\n bpMap.set(bp, values);\n this.elementMap.set(element, bpMap);\n }\n const value = this.getValue(element, key);\n if (value !== undefined) {\n this.updateElement(element, key, value);\n }\n }\n\n /** Track element value changes for a specific key */\n trackValue(element: HTMLElement, key: string): Observable<ElementMatcher> {\n return this.subject\n .asObservable()\n .pipe(filter(v => v.element === element && v.key === key));\n }\n\n /** update all styles for all elements on the current breakpoint */\n updateStyles(): void {\n this.elementMap.forEach((bpMap, el) => {\n const keyMap = new Set(this.elementKeyMap.get(el)!);\n let valueMap = this.getActivatedValues(bpMap);\n\n if (valueMap) {\n valueMap.forEach((v, k) => {\n this.updateElement(el, k, v);\n keyMap.delete(k);\n });\n }\n\n keyMap.forEach(k => {\n valueMap = this.getActivatedValues(bpMap, k);\n if (valueMap) {\n const value = valueMap.get(k);\n this.updateElement(el, k, value);\n } else {\n this.clearElement(el, k);\n }\n });\n });\n }\n\n /**\n * clear the styles for a given element\n * @param element\n * @param key\n */\n clearElement(element: HTMLElement, key: string): void {\n const builders = this.clearMap.get(element);\n\n if (builders) {\n const clearFn: ClearCallback = builders.get(key) as ClearCallback;\n if (!!clearFn) {\n clearFn();\n this.subject.next({element, key, value: ''});\n }\n }\n }\n\n /**\n * update a given element with the activated values for a given key\n * @param element\n * @param key\n * @param value\n */\n updateElement(element: HTMLElement, key: string, value: any): void {\n const builders = this.updateMap.get(element);\n if (builders) {\n const updateFn: UpdateCallback = builders.get(key) as UpdateCallback;\n if (!!updateFn) {\n updateFn(value);\n this.subject.next({element, key, value});\n }\n }\n }\n\n /**\n * release all references to a given element\n * @param element\n */\n releaseElement(element: HTMLElement): void {\n const watcherMap = this.watcherMap.get(element);\n if (watcherMap) {\n watcherMap.forEach(s => s.unsubscribe());\n this.watcherMap.delete(element);\n }\n const elementMap = this.elementMap.get(element);\n if (elementMap) {\n elementMap.forEach((_, s) => elementMap.delete(s));\n this.elementMap.delete(element);\n }\n }\n\n /**\n * trigger an update for a given element and key (e.g. layout)\n * @param element\n * @param key\n */\n triggerUpdate(element: HTMLElement, key?: string): void {\n const bpMap = this.elementMap.get(element);\n if (bpMap) {\n const valueMap = this.getActivatedValues(bpMap, key);\n if (valueMap) {\n if (key) {\n this.updateElement(element, key, valueMap.get(key));\n } else {\n valueMap.forEach((v, k) => this.updateElement(element, k, v));\n }\n }\n }\n }\n\n /** Cross-reference for HTMLElement with directive key */\n private buildElementKeyMap(element: HTMLElement, key: string) {\n let keyMap = this.elementKeyMap.get(element);\n if (!keyMap) {\n keyMap = new Set();\n this.elementKeyMap.set(element, keyMap);\n }\n keyMap.add(key);\n }\n\n /**\n * Other triggers that should force style updates:\n * - directionality\n * - layout changes\n * - mutationobserver updates\n */\n private watchExtraTriggers(element: HTMLElement,\n key: string,\n triggers: Observable<any>[]) {\n if (triggers && triggers.length) {\n let watchers = this.watcherMap.get(element);\n if (!watchers) {\n watchers = new Map();\n this.watcherMap.set(element, watchers);\n }\n const subscription = watchers.get(key);\n if (!subscription) {\n const newSubscription = merge(...triggers).subscribe(() => {\n const currentValue = this.getValue(element, key);\n this.updateElement(element, key, currentValue);\n });\n watchers.set(key, newSubscription);\n }\n }\n }\n\n /** Breakpoint locator by mediaQuery */\n private findByQuery(query: string) {\n return this.breakpoints.findByQuery(query);\n }\n\n /**\n * get the fallback breakpoint for a given element, starting with the current breakpoint\n * @param bpMap\n * @param key\n */\n private getActivatedValues(bpMap: BreakpointMap, key?: string): ValueMap | undefined {\n for (let i = 0; i < this.activatedBreakpoints.length; i++) {\n const activatedBp = this.activatedBreakpoints[i];\n const valueMap = bpMap.get(activatedBp.alias);\n\n if (valueMap) {\n if (key === undefined || (valueMap.has(key) && valueMap.get(key) != null)) {\n return valueMap;\n }\n }\n }\n\n // On the server, we explicitly have an \"all\" section filled in to begin with.\n // So we don't need to aggressively find a fallback if no explicit value exists.\n if (!this._useFallbacks) {\n return undefined;\n }\n\n const lastHope = bpMap.get('');\n return (key === undefined || lastHope && lastHope.has(key)) ? lastHope : undefined;\n }\n\n /**\n * Watch for mediaQuery breakpoint activations\n */\n private observeActivations() {\n const queries = this.breakpoints.items.map(bp => bp.mediaQuery);\n\n this.hook.registerBeforeAfterPrintHooks(this);\n this.matchMedia\n .observe(this.hook.withPrintQuery(queries))\n .pipe(\n tap(this.hook.interceptEvents(this)),\n filter(this.hook.blockPropagation())\n )\n .subscribe(this.onMediaChange.bind(this));\n }\n\n}\n\nfunction initBuilderMap(map: BuilderMap,\n element: HTMLElement,\n key: string,\n input?: Builder): void {\n if (input !== undefined) {\n const oldMap = map.get(element) ?? new Map();\n oldMap.set(key, input);\n map.set(element, oldMap);\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 */\nimport {Directive, ElementRef, OnChanges, OnDestroy, SimpleChanges} from '@angular/core';\nimport {Observable, Subject} from 'rxjs';\n\nimport {StyleDefinition, StyleUtils} from '../style-utils/style-utils';\nimport {StyleBuilder} from '../style-builder/style-builder';\nimport {MediaMarshaller} from '../media-marshaller/media-marshaller';\nimport {buildLayoutCSS} from '@angular/flex-layout/_private-utils';\n\n@Directive()\nexport abstract class BaseDirective2 implements OnChanges, OnDestroy {\n\n protected DIRECTIVE_KEY = '';\n protected inputs: string[] = [];\n /** The most recently used styles for the builder */\n protected mru: StyleDefinition = {};\n protected destroySubject: Subject<void> = new Subject();\n protected currentValue: any;\n\n /** Access to host element's parent DOM node */\n protected get parentElement(): HTMLElement | null {\n return this.elementRef.nativeElement.parentElement;\n }\n\n /** Access to the HTMLElement for the directive */\n protected get nativeElement(): HTMLElement {\n return this.elementRef.nativeElement;\n }\n\n /** Access to the activated value for the directive */\n get activatedValue(): string {\n return this.marshal.getValue(this.nativeElement, this.DIRECTIVE_KEY);\n }\n set activatedValue(value: string) {\n this.marshal.setValue(this.nativeElement, this.DIRECTIVE_KEY, value,\n this.marshal.activatedAlias);\n }\n\n /** Cache map for style computation */\n protected styleCache: Map<string, StyleDefinition> = new Map();\n\n protected constructor(protected elementRef: ElementRef,\n protected styleBuilder: StyleBuilder,\n protected styler: StyleUtils,\n protected marshal: MediaMarshaller) {\n }\n\n /** For @Input changes */\n ngOnChanges(changes: SimpleChanges) {\n Object.keys(changes).forEach(key => {\n if (this.inputs.indexOf(key) !== -1) {\n const bp = key.split('.').slice(1).join('.');\n const val = changes[key].currentValue;\n this.setValue(val, bp);\n }\n });\n }\n\n ngOnDestroy(): void {\n this.destroySubject.next();\n this.destroySubject.complete();\n this.marshal.releaseElement(this.nativeElement);\n }\n\n /** Register with central marshaller service */\n protected init(extraTriggers: Observable<any>[] = []): void {\n this.marshal.init(\n this.elementRef.nativeElement,\n this.DIRECTIVE_KEY,\n this.updateWithValue.bind(this),\n this.clearStyles.bind(this),\n extraTriggers\n );\n }\n\n /** Add styles to the element using predefined style builder */\n protected addStyles(input: string, parent?: Object) {\n const builder = this.styleBuilder;\n const useCache = builder.shouldCache;\n\n let genStyles: StyleDefinition | undefined = this.styleCache.get(input);\n\n if (!genStyles || !useCache) {\n genStyles = builder.buildStyles(input, parent);\n if (useCache) {\n this.styleCache.set(input, genStyles);\n }\n }\n\n this.mru = {...genStyles};\n this.applyStyleToElement(genStyles);\n builder.sideEffect(input, genStyles, parent);\n }\n\n /** Remove generated styles from an element using predefined style builder */\n protected clearStyles() {\n Object.keys(this.mru).forEach(k => {\n this.mru[k] = '';\n });\n this.applyStyleToElement(this.mru);\n this.mru = {};\n this.currentValue = undefined;\n }\n\n /** Force trigger style updates on DOM element */\n protected triggerUpdate() {\n this.marshal.triggerUpdate(this.nativeElement, this.DIRECTIVE_KEY);\n }\n\n /**\n * Determine the DOM element's Flexbox flow (flex-direction).\n *\n * Check inline style first then check computed (stylesheet) style.\n * And optionally add the flow value to element's inline style.\n */\n protected getFlexFlowDirection(target: HTMLElement, addIfMissing = false): string {\n if (target) {\n const [value, hasInlineValue] = this.styler.getFlowDirection(target);\n\n if (!hasInlineValue && addIfMissing) {\n const style = buildLayoutCSS(value);\n const elements = [target];\n this.styler.applyStyleToElements(style, elements);\n }\n\n return value.trim();\n }\n\n return 'row';\n }\n\n protected hasWrap(target: HTMLElement): boolean {\n return this.styler.hasWrap(target);\n }\n\n /** Applies styles given via string pair or object map to the directive element */\n protected applyStyleToElement(style: StyleDefinition,\n value?: string | number,\n element: HTMLElement = this.nativeElement) {\n this.styler.applyStyleToElement(element, style, value);\n }\n\n protected setValue(val: any, bp: string): void {\n this.marshal.setValue(this.nativeElement, this.DIRECTIVE_KEY, val, bp);\n }\n\n protected updateWithValue(input: string) {\n if (this.currentValue !== input) {\n this.addStyles(input);\n this.currentValue = input;\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\nexport * from './base2';\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 './data/break-points';\nexport * from './data/orientation-break-points';\n\nexport * from './break-point';\nexport * from './break-point-registry';\nexport * from './break-points-token';\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 {Inject, Injectable, NgZone, PLATFORM_ID} from '@angular/core';\nimport {DOCUMENT} from '@angular/common';\n\nimport {MatchMedia} from '../match-media';\nimport {BreakPointRegistry} from '../../breakpoints/break-point-registry';\n\n/**\n * MockMatchMedia mocks calls to the Window API matchMedia with a build of a simulated\n * MockMediaQueryListener. Methods are available to simulate an activation of a mediaQuery\n * range and to clearAll mediaQuery listeners.\n */\n@Injectable()\nexport class MockMatchMedia extends MatchMedia {\n\n\n autoRegisterQueries = true; // Used for testing BreakPoint registrations\n useOverlaps = false; // Allow fallback to overlapping mediaQueries\n\n constructor(_zone: NgZone,\n @Inject(PLATFORM_ID) _platformId: Object,\n @Inject(DOCUMENT) _document: any,\n private _breakpoints: BreakPointRegistry) {\n super(_zone, _platformId, _document);\n }\n\n /** Easy method to clear all listeners for all mediaQueries */\n clearAll() {\n this.registry.forEach((mql: MediaQueryList) => {\n (mql as MockMediaQueryList).destroy();\n });\n this.registry.clear();\n this.useOverlaps = false;\n }\n\n /** Feature to support manual, simulated activation of a mediaQuery. */\n activate(mediaQuery: string, useOverlaps = this.useOverlaps): boolean {\n mediaQuery = this._validateQuery(mediaQuery);\n\n if (useOverlaps || !this.isActive(mediaQuery)) {\n this._deactivateAll();\n\n this._registerMediaQuery(mediaQuery);\n this._activateWithOverlaps(mediaQuery, useOverlaps);\n }\n\n return this.hasActivated;\n }\n\n /** Converts an optional mediaQuery alias to a specific, valid mediaQuery */\n _validateQuery(queryOrAlias: string): string {\n const bp = this._breakpoints.findByAlias(queryOrAlias);\n return bp?.mediaQuery ?? queryOrAlias;\n }\n\n /**\n * Manually onMediaChange any overlapping mediaQueries to simulate\n * similar functionality in the window.matchMedia()\n */\n private _activateWithOverlaps(mediaQuery: string, useOverlaps: boolean): boolean {\n if (useOverlaps) {\n const bp = this._breakpoints.findByQuery(mediaQuery);\n const alias = bp?.alias ?? 'unknown';\n\n // Simulate activation of overlapping lt-<XXX> ranges\n switch (alias) {\n case 'lg':\n this._activateByAlias(['lt-xl']);\n break;\n case 'md':\n this._activateByAlias(['lt-xl', 'lt-lg']);\n break;\n case 'sm':\n this._activateByAlias(['lt-xl', 'lt-lg', 'lt-md']);\n break;\n case 'xs':\n this._activateByAlias(['lt-xl', 'lt-lg', 'lt-md', 'lt-sm']);\n break;\n }\n\n // Simulate activation of overlapping gt-<xxxx> mediaQuery ranges\n switch (alias) {\n case 'xl':\n this._activateByAlias(['gt-lg', 'gt-md', 'gt-sm', 'gt-xs']);\n break;\n case 'lg':\n this._activateByAlias(['gt-md', 'gt-sm', 'gt-xs']);\n break;\n case 'md':\n this._activateByAlias(['gt-sm', 'gt-xs']);\n break;\n case 'sm':\n this._activateByAlias(['gt-xs']);\n break;\n }\n }\n\n // Activate last since the responsiveActivation is watching *this* mediaQuery\n return this._activateByQuery(mediaQuery);\n }\n\n /**\n *\n */\n private _activateByAlias(aliases: string[]) {\n const activate = (alias: string) => {\n const bp = this._breakpoints.findByAlias(alias);\n this._activateByQuery(bp?.mediaQuery ?? alias);\n };\n aliases.forEach(activate);\n }\n\n /**\n *\n */\n private _activateByQuery(mediaQuery: string) {\n if (!this.registry.has(mediaQuery) && this.autoRegisterQueries) {\n this._registerMediaQuery(mediaQuery);\n }\n const mql: MockMediaQueryList = this.registry.get(mediaQuery) as MockMediaQueryList;\n\n if (mql && !this.isActive(mediaQuery)) {\n this.registry.set(mediaQuery, mql.activate());\n }\n return this.hasActivated;\n }\n\n /** Deactivate all current MQLs and reset the buffer */\n private _deactivateAll() {\n this.registry.forEach((it: MediaQueryList) => {\n (it as MockMediaQueryList).deactivate();\n });\n return this;\n }\n\n /** Insure the mediaQuery is registered with MatchMedia */\n private _registerMediaQuery(mediaQuery: string) {\n if (!this.registry.has(mediaQuery) && this.autoRegisterQueries) {\n this.registerQuery(mediaQuery);\n }\n }\n\n /**\n * Call window.matchMedia() to build a MediaQueryList; which\n * supports 0..n listeners for activation/deactivation\n */\n protected buildMQL(query: string): MediaQueryList {\n return new MockMediaQueryList(query);\n }\n\n protected get hasActivated() {\n return this.activations.length > 0;\n }\n\n}\n\n/**\n * Special internal class to simulate a MediaQueryList and\n * - supports manual activation to simulate mediaQuery matching\n * - manages listeners\n */\nexport class MockMediaQueryList implements MediaQueryList {\n private _isActive = false;\n private _listeners: MediaQueryListListener[] = [];\n\n get matches(): boolean {\n return this._isActive;\n }\n\n get media(): string {\n return this._mediaQuery;\n }\n\n constructor(private _mediaQuery: string) {\n }\n\n /**\n * Destroy the current list by deactivating the\n * listeners and clearing the internal list\n */\n destroy() {\n this.deactivate();\n this._listeners = [];\n }\n\n /** Notify all listeners that 'matches === TRUE' */\n activate(): MockMediaQueryList {\n if (!this._isActive) {\n this._isActive = true;\n this._listeners.forEach((callback) => {\n const cb: ((this: MediaQueryList, ev: MediaQueryListEvent) => any) = callback!;\n cb.call(this, {matches: this.matches, media: this.media} as MediaQueryListEvent);\n });\n }\n return this;\n }\n\n /** Notify all listeners that 'matches === false' */\n deactivate(): MockMediaQueryList {\n if (this._isActive) {\n this._isActive = false;\n this._listeners.forEach((callback) => {\n const cb: ((this: MediaQueryList, ev: MediaQueryListEvent) => any) = callback!;\n cb.call(this, {matches: this.matches, media: this.media} as MediaQueryListEvent);\n });\n }\n return this;\n }\n\n /** Add a listener to our internal list to activate later */\n addListener(listener: MediaQueryListListener) {\n if (this._listeners.indexOf(listener) === -1) {\n this._listeners.push(listener);\n }\n if (this._isActive) {\n const cb: ((this: MediaQueryList, ev: MediaQueryListEvent) => any) = listener!;\n cb.call(this, {matches: this.matches, media: this.media} as MediaQueryListEvent);\n }\n }\n\n /** Don't need to remove listeners in the testing environment */\n removeListener(_: MediaQueryListListener | null) {\n }\n\n addEventListener<K extends keyof MediaQueryListEventMap>(\n _: K,\n __: (this: MediaQueryList,\n ev: MediaQueryListEventMap[K]) => any,\n ___?: boolean | AddEventListenerOptions): void;\n\n addEventListener(\n _: string,\n __: EventListenerOrEventListenerObject,\n ___?: boolean | AddEventListenerOptions) {\n }\n\n removeEventListener<K extends keyof MediaQueryListEventMap>(\n _: K,\n __: (this: MediaQueryList,\n ev: MediaQueryListEventMap[K]) => any,\n ___?: boolean | EventListenerOptions): void;\n\n removeEventListener(\n _: string,\n __: EventListenerOrEventListenerObject,\n ___?: boolean | EventListenerOptions) {\n }\n\n dispatchEvent(_: Event): boolean {\n return false;\n }\n\n onchange: MediaQueryListListener = null;\n}\n\n/**\n * Pre-configured provider for MockMatchMedia\n */\nexport const MockMatchMediaProvider = { // tslint:disable-line:variable-name\n provide: MatchMedia,\n useClass: MockMatchMedia\n};\n\ntype MediaQueryListListener = ((this: MediaQueryList, ev: MediaQueryListEvent) => any) | null;\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 './match-media';\nexport * from './mock/mock-match-media';\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/** Wraps the provided value in an array, unless the provided value is an array. */\nexport function coerceArray<T>(value: T | T[]): T[] {\n return Array.isArray(value) ? value : [value];\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 {Injectable, OnDestroy} from '@angular/core';\nimport {Subject, asapScheduler, Observable, of} from 'rxjs';\nimport {\n debounceTime,\n distinctUntilChanged,\n filter,\n map,\n switchMap,\n takeUntil,\n} from 'rxjs/operators';\n\nimport {mergeAlias} from '../add-alias';\nimport {MediaChange} from '../media-change';\nimport {MatchMedia} from '../match-media/match-media';\nimport {PrintHook} from '../media-marshaller/print-hook';\nimport {BreakPointRegistry, OptionalBreakPoint} from '../breakpoints/break-point-registry';\n\nimport {sortDescendingPriority} from '../utils/sort';\nimport {coerceArray} from '../utils/array';\n\n\n/**\n * MediaObserver enables applications to listen for 1..n mediaQuery activations and to determine\n * if a mediaQuery is currently activated.\n *\n * Since a breakpoint change will first deactivate 1...n mediaQueries and then possibly activate\n * 1..n mediaQueries, the MediaObserver will debounce notifications and report ALL *activations*\n * in 1 event notification. The reported activations will be sorted in descending priority order.\n *\n * This class uses the BreakPoint Registry to inject alias information into the raw MediaChange\n * notification. For custom mediaQuery notifications, alias information will not be injected and\n * those fields will be ''.\n *\n * Note: Developers should note that only mediaChange activations (not de-activations)\n * are announced by the MediaObserver.\n *\n * @usage\n *\n * // RxJS\n * import { filter } from 'rxjs/operators';\n * import { MediaObserver } from '@angular/flex-layout';\n *\n * @Component({ ... })\n * export class AppComponent {\n * status: string = '';\n *\n * constructor(mediaObserver: MediaObserver) {\n * const media$ = mediaObserver.asObservable().pipe(\n * filter((changes: MediaChange[]) => true) // silly noop filter\n * );\n *\n * media$.subscribe((changes: MediaChange[]) => {\n * let status = '';\n * changes.forEach( change => {\n * status += `'${change.mqAlias}' = (${change.mediaQuery}) <br/>` ;\n * });\n * this.status = status;\n * });\n *\n * }\n * }\n */\n@Injectable({providedIn: 'root'})\nexport class MediaObserver implements OnDestroy {\n\n /**\n * @deprecated Use `asObservable()` instead.\n * @breaking-change 8.0.0-beta.25\n * @deletion-target 10.0.0\n */\n readonly media$: Observable<MediaChange>;\n\n /** Filter MediaChange notifications for overlapping breakpoints */\n filterOverlaps = false;\n\n constructor(protected breakpoints: BreakPointRegistry,\n protected matchMedia: MatchMedia,\n protected hook: PrintHook) {\n this._media$ = this.watchActivations();\n this.media$ = this._media$.pipe(\n filter((changes: MediaChange[]) => changes.length > 0),\n map((changes: MediaChange[]) => changes[0])\n );\n }\n\n /**\n * Completes the active subject, signalling to all complete for all\n * MediaObserver subscribers\n */\n ngOnDestroy(): void {\n this.destroyed$.next();\n this.destroyed$.complete();\n }\n\n // ************************************************\n // Public Methods\n // ************************************************\n\n /**\n * Observe changes to current activation 'list'\n */\n asObservable(): Observable<MediaChange[]> {\n return this._media$;\n }\n\n /**\n * Allow programmatic query to determine if one or more media query/alias match\n * the current viewport size.\n * @param value One or more media queries (or aliases) to check.\n * @returns Whether any of the media queries match.\n */\n isActive(value: string | string[]): boolean {\n const aliases = splitQueries(coerceArray(value));\n return aliases.some(alias => {\n const query = toMediaQuery(alias, this.breakpoints);\n return query !== null && this.matchMedia.isActive(query);\n });\n }\n\n // ************************************************\n // Internal Methods\n // ************************************************\n\n /**\n * Register all the mediaQueries registered in the BreakPointRegistry\n * This is needed so subscribers can be auto-notified of all standard, registered\n * mediaQuery activations\n */\n private watchActivations() {\n const queries = this.breakpoints.items.map(bp => bp.mediaQuery);\n return this.buildObservable(queries);\n }\n\n /**\n * Only pass/announce activations (not de-activations)\n *\n * Since multiple-mediaQueries can be activation in a cycle,\n * gather all current activations into a single list of changes to observers\n *\n * Inject associated (if any) alias information into the MediaChange event\n * - Exclude mediaQuery activations for overlapping mQs. List bounded mQ ranges only\n * - Exclude print activations that do not have an associated mediaQuery\n *\n * NOTE: the raw MediaChange events [from MatchMedia] do not\n * contain important alias information; as such this info\n * must be injected into the MediaChange\n */\n private buildObservable(mqList: string[]): Observable<MediaChange[]> {\n const hasChanges = (changes: MediaChange[]) => {\n const isValidQuery = (change: MediaChange) => (change.mediaQuery.length > 0);\n return (changes.filter(isValidQuery).length > 0);\n };\n const excludeOverlaps = (changes: MediaChange[]) => {\n return !this.filterOverlaps ? changes : changes.filter(change => {\n const bp = this.breakpoints.findByQuery(change.mediaQuery);\n return bp?.overlapping ?? true;\n });\n };\n const ignoreDuplicates = (previous: MediaChange[], current: MediaChange[]): boolean => {\n if (previous.length !== current.length) {\n return false;\n }\n\n const previousMqs = previous.map(mc => mc.mediaQuery);\n const currentMqs = new Set(current.map(mc => mc.mediaQuery));\n const difference = new Set(previousMqs.filter(mq => !currentMqs.has(mq)));\n\n return difference.size === 0;\n };\n\n /**\n */\n return this.matchMedia\n .observe(this.hook.withPrintQuery(mqList))\n .pipe(\n filter((change: MediaChange) => change.matches),\n debounceTime(0, asapScheduler),\n switchMap(_ => of(this.findAllActivations())),\n map(excludeOverlaps),\n filter(hasChanges),\n distinctUntilChanged(ignoreDuplicates),\n takeUntil(this.destroyed$)\n );\n }\n\n /**\n * Find all current activations and prepare single list of activations\n * sorted by descending priority.\n */\n private findAllActivations(): MediaChange[] {\n const mergeMQAlias = (change: MediaChange) => {\n const bp: OptionalBreakPoint = this.breakpoints.findByQuery(change.mediaQuery);\n return mergeAlias(change, bp);\n };\n const replaceWithPrintAlias = (change: MediaChange) => {\n return this.hook.isPrintEvent(change) ? this.hook.updateEvent(change) : change;\n };\n\n return this.matchMedia\n .activations\n .map(query => new MediaChange(true, query))\n .map(replaceWithPrintAlias)\n .map(mergeMQAlias)\n .sort(sortDescendingPriority);\n }\n\n private readonly _media$: Observable<MediaChange[]>;\n private readonly destroyed$ = new Subject<void>();\n}\n\n/**\n * Find associated breakpoint (if any)\n */\nfunction toMediaQuery(query: string, locator: BreakPointRegistry): string | null {\n const bp = locator.findByAlias(query) ?? locator.findByQuery(query);\n return bp?.mediaQuery ?? null;\n}\n\n/**\n * Split each query string into separate query strings if two queries are provided as comma\n * separated.\n */\nfunction splitQueries(queries: string[]): string[] {\n return queries.map((query: string) => query.split(','))\n .reduce((a1: string[], a2: string[]) => a1.concat(a2))\n .map(query => query.trim());\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './media-observer';\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 {Inject, Injectable, PLATFORM_ID} from '@angular/core';\nimport {DOCUMENT, isPlatformBrowser} from '@angular/common';\n\nimport {fromEvent, Subscription} from 'rxjs';\nimport {take} from 'rxjs/operators';\n\nimport {mergeAlias} from '../add-alias';\nimport {MediaChange} from '../media-change';\nimport {MatchMedia} from '../match-media/match-media';\nimport {BreakPointRegistry, OptionalBreakPoint} from '../breakpoints/break-point-registry';\nimport {sortDescendingPriority} from '../utils/sort';\nimport {LAYOUT_CONFIG, LayoutConfigOptions} from '../tokens/library-config';\n\n/**\n * Class\n */\n@Injectable({providedIn: 'root'})\nexport class MediaTrigger {\n\n constructor(\n protected breakpoints: BreakPointRegistry,\n protected matchMedia: MatchMedia,\n @Inject(LAYOUT_CONFIG) protected layoutConfig: LayoutConfigOptions,\n @Inject(PLATFORM_ID) protected _platformId: Object,\n @Inject(DOCUMENT) protected _document: any) {\n }\n\n /**\n * Manually activate range of breakpoints\n * @param list array of mediaQuery or alias strings\n */\n activate(list: string[]) {\n list = list.map(it => it.trim()); // trim queries\n\n this.saveActivations();\n this.deactivateAll();\n this.setActivations(list);\n\n this.prepareAutoRestore();\n }\n\n /**\n * Restore original, 'real' breakpoints and emit events\n * to trigger stream notification\n */\n restore() {\n if (this.hasCachedRegistryMatches) {\n const extractQuery = (change: MediaChange) => change.mediaQuery;\n const list = this.originalActivations.map(extractQuery);\n try {\n this.deactivateAll();\n this.restoreRegistryMatches();\n this.setActivations(list);\n } finally {\n this.originalActivations = [];\n if (this.resizeSubscription) {\n this.resizeSubscription.unsubscribe();\n }\n }\n }\n }\n\n // ************************************************\n // Internal Methods\n // ************************************************\n\n /**\n * Whenever window resizes, immediately auto-restore original\n * activations (if we are simulating activations)\n */\n private prepareAutoRestore() {\n const isBrowser = isPlatformBrowser(this._platformId) && this._document;\n const enableAutoRestore = isBrowser && this.layoutConfig.mediaTriggerAutoRestore;\n\n if (enableAutoRestore) {\n const resize$ = fromEvent(window, 'resize').pipe(take(1));\n this.resizeSubscription = resize$.subscribe(this.restore.bind(this));\n }\n }\n\n /**\n * Notify all matchMedia subscribers of de-activations\n *\n * Note: we must force 'matches' updates for\n * future matchMedia::activation lookups\n */\n private deactivateAll() {\n const list = this.currentActivations;\n\n this.forceRegistryMatches(list, false);\n this.simulateMediaChanges(list, false);\n }\n\n /**\n * Cache current activations as sorted, prioritized list of MediaChanges\n */\n private saveActivations() {\n if (!this.hasCachedRegistryMatches) {\n const toMediaChange = (query: string) => new MediaChange(true, query);\n const mergeMQAlias = (change: MediaChange) => {\n const bp: OptionalBreakPoint = this.breakpoints.findByQuery(change.mediaQuery);\n return mergeAlias(change, bp);\n };\n\n this.originalActivations = this.currentActivations\n .map(toMediaChange)\n .map(mergeMQAlias)\n .sort(sortDescendingPriority);\n\n this.cacheRegistryMatches();\n }\n }\n\n /**\n * Force set manual activations for specified mediaQuery list\n */\n private setActivations(list: string[]) {\n if (!!this.originalRegistry) {\n this.forceRegistryMatches(list, true);\n }\n this.simulateMediaChanges(list);\n }\n\n /**\n * For specified mediaQuery list manually simulate activations or deactivations\n */\n private simulateMediaChanges(queries: string[], matches = true) {\n const toMediaQuery = (query: string) => {\n const locator = this.breakpoints;\n const bp = locator.findByAlias(query) || locator.findByQuery(query);\n return bp ? bp.mediaQuery : query;\n };\n const emitChangeEvent = (query: string) => this.emitChangeEvent(matches, query);\n\n queries.map(toMediaQuery).forEach(emitChangeEvent);\n }\n\n /**\n * Replace current registry with simulated registry...\n * Note: this is required since MediaQueryList::matches is 'readOnly'\n */\n private forceRegistryMatches(queries: string[], matches: boolean) {\n const registry = new Map<string, MediaQueryList>();\n queries.forEach(query => {\n registry.set(query, {matches} as MediaQueryList);\n });\n\n this.matchMedia.registry = registry;\n }\n\n /**\n * Save current MatchMedia::registry items.\n */\n private cacheRegistryMatches() {\n const target = this.originalRegistry;\n\n target.clear();\n this.matchMedia.registry.forEach((value: MediaQueryList, key: string) => {\n target.set(key, value);\n });\n this.hasCachedRegistryMatches = true;\n }\n\n /**\n * Restore original, 'true' registry\n */\n private restoreRegistryMatches() {\n const target = this.matchMedia.registry;\n\n target.clear();\n this.originalRegistry.forEach((value: MediaQueryList, key: string) => {\n target.set(key, value);\n });\n\n this.originalRegistry.clear();\n this.hasCachedRegistryMatches = false;\n }\n\n /**\n * Manually emit a MediaChange event via the MatchMedia to MediaMarshaller and MediaObserver\n */\n private emitChangeEvent(matches: boolean, query: string) {\n this.matchMedia.source.next(new MediaChange(matches, query));\n }\n\n private get currentActivations(): string[] {\n return this.matchMedia.activations;\n }\n\n private hasCachedRegistryMatches = false;\n private originalActivations: MediaChange[] = [];\n private originalRegistry: Map<string, MediaQueryList> = new Map<string, MediaQueryList>();\n\n private resizeSubscription!: Subscription;\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 './media-trigger';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nexport * from './sort';\nexport * from './array';\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 /**\n * The flex API permits 3 or 1 parts of the value:\n * - `flex-grow flex-shrink flex-basis`, or\n * - `flex-basis`\n */\nexport function validateBasis(basis: string, grow = '1', shrink = '1'): string[] {\n let parts = [grow, shrink, basis];\n\n let j = basis.indexOf('calc');\n if (j > 0) {\n parts[2] = _validateCalcValue(basis.substring(j).trim());\n let matches = basis.substr(0, j).trim().split(' ');\n if (matches.length == 2) {\n parts[0] = matches[0];\n parts[1] = matches[1];\n }\n } else if (j == 0) {\n parts[2] = _validateCalcValue(basis.trim());\n } else {\n let matches = basis.split(' ');\n parts = (matches.length === 3) ? matches : [\n grow, shrink, basis\n ];\n }\n\n return parts;\n}\n\n\n/**\n * Calc expressions require whitespace before & after any expression operators\n * This is a simple, crude whitespace padding solution.\n * - '3 3 calc(15em + 20px)'\n * - calc(100% / 7 * 2)\n * - 'calc(15em + 20px)'\n * - 'calc(15em+20px)'\n * - '37px'\n * = '43%'\n */\nfunction _validateCalcValue(calc: string): string {\n return calc.replace(/[\\s]/g, '').replace(/[\\/\\*\\+\\-]/g, ' $& ');\n}\n","export interface Multiplier {\n readonly unit: string;\n readonly value: number;\n}\n\nconst MULTIPLIER_SUFFIX = 'x';\n\nexport function multiply(value: string, multiplier?: Multiplier): string {\n if (multiplier === undefined) {\n return value;\n }\n\n const transformValue = (possibleValue: string) => {\n const numberValue = +(possibleValue.slice(0, -MULTIPLIER_SUFFIX.length));\n\n if (value.endsWith(MULTIPLIER_SUFFIX) && !isNaN(numberValue)) {\n return `${numberValue * multiplier.value}${multiplier.unit}`;\n }\n\n return value;\n };\n\n return value.includes(' ') ?\n value.split(' ').map(transformValue).join(' ') : transformValue(value);\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 './module';\nexport * from './browser-provider';\nexport * from './media-change';\nexport * from './stylesheet-map/index';\nexport * from './tokens/index';\nexport * from './add-alias';\n\nexport * from './base/index';\nexport * from './breakpoints/index';\nexport {\n MatchMedia as ɵMatchMedia,\n MockMatchMedia as ɵMockMatchMedia,\n MockMatchMediaProvider as ɵMockMatchMediaProvider,\n} from './match-media/index';\nexport * from './media-observer/index';\nexport * from './media-trigger/index';\nexport * from './utils/index';\n\nexport * from './style-utils/style-utils';\nexport * from './style-builder/style-builder';\nexport * from './basis-validator/basis-validator';\nexport * from './media-marshaller/media-marshaller';\nexport * from './media-marshaller/print-hook';\nexport {Multiplier, multiply as ɵmultiply} from './multiply/multiplier';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;;;AAUA;;;;;SAKgB,YAAY,CAAC,SAAmB,EAAE,UAAkB;IAClE,OAAO;QACL,IAAI,iBAAiB,CAAC,UAAU,CAAC,EAAE;YACjC,MAAM,QAAQ,GAAG,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,gBAAgB,CAAC,WAAW,UAAU,GAAG,CAAC,CAAC,CAAC;;;;;YAMlF,MAAM,UAAU,GAAG,sBAAsB,CAAC;YAC1C,QAAQ,CAAC,OAAO,CAAC,EAAE;gBACjB,EAAE,CAAC,SAAS,CAAC,QAAQ,CAAC,GAAG,UAAU,KAAK,CAAC,IAAI,EAAE,CAAC,UAAU;oBACxD,EAAE,CAAC,UAAU,CAAC,WAAW,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC;aACxE,CAAC,CAAC;SACJ;KACF,CAAC;AACJ,CAAC;AAED;;;MAGa,gBAAgB,GAAG;IAC9B,OAAO,EAAkC,sBAAsB;IAC/D,UAAU,EAAE,YAAY;IACxB,IAAI,EAAE,CAAC,QAAQ,EAAE,WAAW,CAAC;IAC7B,KAAK,EAAE,IAAI;EACX;MAEW,UAAU,GAAG;;AC3C1B;;;;;;;AAYA;;;;;MAQa,UAAU;;uGAAV,UAAU;wGAAV,UAAU;wGAAV,UAAU,aAFV,CAAC,gBAAgB,CAAC;2FAElB,UAAU;kBAHtB,Q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